[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-patch-tracker] [patch #8783] C++ implementation of textscan
From: |
Lachlan Andrew |
Subject: |
[Octave-patch-tracker] [patch #8783] C++ implementation of textscan |
Date: |
Sat, 13 Feb 2016 03:55:09 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:43.0) Gecko/20100101 Firefox/43.0 |
Follow-up Comment #46, patch #8783 (project octave):
Philip, I've been looking at the uneven-lines issue.
Under Linux at least, the current textscan seems to output uneven lines even
if the last character in the file is an end-of-line. However, it outputs even
lines if the last *two* characters are bot end-of-line. My guess is that the
last EOL gets swallowed by the process that reads in the line. My guess is
also that most applications don't care whether or not the output is padded
when the last scan is incomplete; garbage-in-garbage-out... Still, I'll keep
trying to get it to work, for completeness.
octave:1> f = fopen ("partial.txt")
f = 3
octave:2> a = textscan (f, "%d %d %d")
a =
{
[1,1] =
1
4
[1,2] = 2
[1,3] = 3
}
$ od -h --format x1 partial.txt
0000000 2031 2032 0a33 0a34
31 20 32 20 33 0a 34 0a
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/patch/?8783>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, (continued)
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/03
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/04
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/10
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Philip Nienhuis, 2016/02/10
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/11
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Philip Nienhuis, 2016/02/11
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, John W. Eaton, 2016/02/11
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/12
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Philip Nienhuis, 2016/02/12
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/12
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan,
Lachlan Andrew <=
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/12
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Philip Nienhuis, 2016/02/13
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/13
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/13
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Philip Nienhuis, 2016/02/14
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/14
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Philip Nienhuis, 2016/02/14
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/19
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Philip Nienhuis, 2016/02/21
- [Octave-patch-tracker] [patch #8783] C++ implementation of textscan, Lachlan Andrew, 2016/02/21