26 Apr
2004
26 Apr
'04
5:08 a.m.
Russell Whitaker wrote:
this program:
program writebug; var b1, b2: string (80); f: Text; begin Assign (f, 'ref.txt'); Reset (f); readln (f, b2); while not eof(f) do begin ReadLn (f, b1); if b1 [ 1 ] = '=' then
If b1 is empty, b1[1] is undefined (or contains the value from a previous input). Try (b1 <> '') and (b1[1] = '=') or IsPrefix ('=', b1) the former(!) is faster. Frank -- Frank Heckenbach, frank@g-n-u.de, http://fjf.gnu.de/, 7977168E GPC To-Do list, latest features, fixed bugs: http://www.gnu-pascal.de/todo.html GPC download signing key: 51FF C1F0 1A77 C6C2 4482 4DDC 117A 9773 7F88 1707