While running ASDF 3.1.5.14's test suite, a logical pathname test fails, because of an interaction between logical pathnames and the case of alphabetical characters in the pathname name.
You may reproduce with:
make t l=clisp t=test-logical-pathname.script
I have no time to investigate right now, but if and when a CLISP maintainer is interested in fixing the issue, I will be happy to dig further.
please supply a reproducible test case.
thanks
I carefully wrote a response, and sourceforge looks like it ate it. Sigh.
1- logical pathnames are not parsed correctly. If you (setf (logical-pathname-translations "ASDF") ...) clisp won't parse #p"ASDF:foo" correctly. translate-pathname works on strings but not on (already incorrectly parsed) pathnames.
2- even when synthesizing logical pathnames using make-pathname-logical, things go weird. The test case above in test-logical-pathname has compile-file go all confused between case-preservation and downcasing of logical pathnames. I'll try harder to isolate the issue if you want.
3- Another issue I don't quite remember the details of was causing segfaults with clisp. Filed separately as #678.
Regarding point 1-, I of course meant translate-logical-pathname, not translate-pathname (that seems to work fine AFAICT).
Wow, in my scripts
#p"ASDF:test;"is parsed correctly, but not at the SLIME command-line. WTF?Last edit: François-René Rideau 2016-08-29
Regarding #2, here are
So, apparently, the fact the source pathname is logical somehow leaks into the output-file and leads to downcasing it, even though the explicitly provided
:output-fileis physical. Indeed it looks like the pathname name and type of:output-filesare merged into the source file, but the pathname directory is dropped. This is unlike what happens when the source is a physical pathname, and the pathname directory is kept.I can see a workaround: don't trust clisp to fully heed the
:output-fileargument, and instead look at the output-truename result from compile-file, and also deduce the .lib path from that. I'll push that workaround to ASDF 3.1.7.8. It's still a clisp bug.Last edit: François-René Rideau 2016-08-29
Regarding 1- I found out why my script could parse logical pathnames but not my SLIME REPL: I was not using the -ansi flag of clisp when invoking SLIME, but a shell alias was adding it at the shell REPL.
regarding 1 - see it might be related to
*PARSE-NAMESTRING-ANSI*.regarding 2 - I did not examing the report in details, but I think the issue might be that input and output are actually merged and thus may result in a logical pathname.
as usual, the most useful bug report should contain a reproducible test case
thanks
Regarding 2, the merging seems to go wrong:
Last edit: François-René Rideau 2016-08-29
again, where is the test case?
compile-file-pathnamethanks
For the record, this is the call that returns fishy results:
Final note: it is probably a bad thing to call logical pathnames "portable pathnames". In my experience, logical pathnames are the least portable feature of Common Lisp.
"portable pathnames" refers to object portability across platforms, not functionality portability across implementations
Thanks a lot for the fix! I looked at it, it works, but it's slightly subtle and might deserve being documented.