On Wednesday 30 March 2005 14:20, Raymond Toy wrote: > Gareth> - So I think #p"foo.lisp" should be a logical pathname > object. But Gareth> (see above) it's actually an object of type > PATHNAME instead. > > But the CLHS says > > * If host is nil and thing is a syntactically valid logical > pathname namestring containing an explicit host, then it is > parsed as a logical pathname namestring. > > and "foo.lisp" doesn't have an explicit host, so it's not parsed as a > logical pathname.
Er, that doesn't follow (only that *that* clause doesn't make it be parsed as a logical pathname) ... but in fact I'm an idiot, as I expected, and the problem is that I'd missed a key part of the *next* paragraph, which is the bit that says that if host is nil and thing is a syntactically valid logical pathname namestring without an explicit host AND *DEFAULT-PATHNAME-DEFAULTS* IS A LOGICAL PATHNAME (the condition that I, being an idiot, missed) then you get a logical pathname. > Also, default-pathname isn't specified so it gets the default value of > *default-pathname-defaults* which is usually a pathname. If you > change *default-pathname-defaults* to a logical pathname you should > get a logical pathname as the result. I don't know how well that > would work in practice, but it would probably expose mistakes in > CMUCL's pathname code. Right. Which I'd have understood before if I'd actually been able to read :-). -- g
