Re: Re: file reading
jon klein <[email protected]>
| Newsgroups | gmane.comp.breve |
|---|---|
| Message-ID | <[email protected]> |
On Feb 24, 2004, at 2:39 PM, Raphael Crawford-Marks wrote:
> After some more investigation it looks like there is a bug.
>
> 1) open-for-reading returns TRUE regardless of whether or not the file
> existed.
> 2) If the file does *not* exist, calling read-line will cause the
> simulation to
> stop because the File object is uninitialized
> 3) However, testing to see if the File object is initialized will
> return true,
> even if the file does not exist.
Thanks for the bug report.
I'll get this sorted out for the next version, but if you need an
immediate
workaround, you can modify the class file "File.tz". In the
open-for-reading
method, you'll want to add the following test after the filePointer is
initialized:
if !filePointer: return 0.
- jon klein
_______________________________________________
breve mailing list
[email protected]
http://www.spiderland.org/mailman/listinfo/breve