[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #58008] textscan: literals are managed differe

From: Philip Nienhuis
Subject: [Octave-bug-tracker] [bug #58008] textscan: literals are managed differently depending on delimiters
Date: Wed, 18 Mar 2020 16:27:12 -0400 (EDT)
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:49.0) Gecko/20100101 Firefox/49.0 SeaMonkey/2.46

Follow-up Comment #2, bug #58008 (project octave):

BTW, In Matlab r2014a your example doesn't work either:

>> nm = textscan (txt, 'literal%s literal%s', 'Delimiter', ' ')
nm = 
    {2x1 cell}    {2x1 cell}
>> nm{1}
ans = 
>> nm{2}
ans = 

(empty lines removed)

Adding "\n" to delimiters or to 'endofline' makes no difference. '\r\n' as EOL
won't work either.

Matlab has known issues with "cuddling" literals (literals immediately
bordering fields). At the time (long ago) I was working on strread.m I've put
a lot of effort in properly processing of cuddling literals (because I needed
it myself). Unfortunately Octave's textscan, when turned into a (much faster)
compiled function, couldn't follow.


Reply to this item at:


  Message sent via Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]