appending to a file

Jon jbondy at sover.net
Sun Aug 28 10:02:18 EDT 2005


During the last week, someone asserted that no matter how one coded an 
append to a file in Rev, it required loading the entire file into memory.

This may be true in Rev, but it is not true in Windows (and, I would 
guess, in all other OS's).  In Windows, one can open a file, seek to the 
end, and write.  The OS may have to bring a little of the start of the 
file into memory (at the open) and a little of the end of the file into 
memory (at the seek), but for a large file, this may be much faster than 
reading the whole thing into memory, appending in memory, and writing 
the whole thing out again.

It may well be that the way that the Rev engine is coded takes advantage 
of this approach: I am not sure about that.

:)

Jon



More information about the use-livecode mailing list