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

OPEN for :OUTPUT with version :NEWEST



The following should be made clear by explicit mention somewhere in the manual:

Question: If you call OPEN, and the direction is :OUTPUT or :IO, and the
version of the file is :NEWEST, what version number is used?

Answer:  If the :IF-EXISTS is :NEW-VERSION or unsupplied, then :NEWEST
in the pathname means "a version number one higher than the highest
version extant."  In all other cases :NEWEST in the pathname means "the
highest extant version."

So if versions 1, 2, and 3 of a file exist, and you open the :NEWEST
version for :OUTPUT, then you get version 4 if the :IF-EXISTS is
:NEW-VERSION or unsupplied, but you get version 3 if the :IF-EXISTS is
anything else (e.g. :SUPERSEDE, :APPEND, :OVERWRITE, :RENAME, et al).