[Info-vax] bug with DIRECTORY and search lists
Phillip Helbig---undress to reply
helbig at astro.multiCLOTHESvax.de
Fri Nov 6 13:44:09 EST 2009
This has been around for a while, I think. I think there are no plans
to fix it. Anyone whose code RELIES on this buggy behaviour deserves to
have it break. Presumably, correcting the bug would have side effects
which would break reasonable code.
Can anyone comment on WHY this "works" as it does?
---------8<-------------------------------------------------------------------
$ CREATE/DIRECTORY [.A]
$ CREATE/DIRECTORY [.B]
$ CREATE/DIRECTORY [.C]
$ CREATE/DIRECTORY [.D]
$ CREATE/DIRECTORY [.Z]
$ CREATE [.A]A.A
$ CREATE [.B]B.B
$ CREATE [.C]C.C
$ CREATE [.D]D.D
$ DIRECTORY/NOHEADER/EXCLUDE=*.DIR [...]
$ DEFINE/NOLOG AAA [.A],[.Z]
$ DEFINE/NOLOG BBB [.B],[.Z]
$ DEFINE/NOLOG CCC [.C],[.Z]
$ DEFINE/NOLOG DDD [.D],[.Z]
$ DIRECTORY/NOHEADER AAA
$ DIRECTORY/NOHEADER BBB
$ DIRECTORY/NOHEADER CCC
$ DIRECTORY/NOHEADER DDD
$ TYPE SYS$INPUT
So far, so good!
If the DIRECTORY command specifies a list of logical names, each of
which is a search list, then if N is the position in the list, the
contents are listed 2**(N-1) times!
$ SET VERIFY
$ DIRECTORY/NOHEADER AAA,BBB,CCC,DDD
$ DIRECTORY/NOHEADER BBB,AAA
$ EXIT $STATUS + 0*'F$VERIFY(0)'
---------8<-------------------------------------------------------------------
If some of the logical names are search lists and some are not, then the
behaviour is much more complicated. This is left as an exercise to the
reader.
It doesn't seem to matter if the search list specifies just two
directories or more than two directories.
(Note that no files are contained in more than one search list.)
The /VERSION qualifier can be used to reduce the number of lines of
output, but it acts on lines of output, not on file version numbers.
More information about the Info-vax
mailing list