[Ecls-list] truename: no file name supplied

Marco Antoniotti marcoxa at cs.nyu.edu
Mon Aug 18 12:12:02 UTC 2003


On Monday, Aug 18, 2003, at 14:45 America/New_York, Pascal Bourguignon 
wrote:

>
> Marco Antoniotti writes:
>> You could always do
>>
>> 	(load (make-pathname :name ".common" :type "lisp" :defaults
>> (parse-namestring "/home/pascal/")))
>>
>> Unfortunately, PARSE-NAMESTRING cannot be relied upon to parse names
>> starting with a dot under UNIX.
>
> Ok, this works. But isn't it a little contrieved?

Yes and no.

The problem is that the implementors never agreed on the workings of 
PARSE-NAMESTRING under Unix-like OSes.  It is pretty useless to have 
PARSE-NAMESTRING of ".cshrc" return a pathname with name ".cshrc" under 
ECL if LW does not do the same (which it does not).

We need to push all the implementors on agreeing to remove this and 
other "implementation dependent" things...

Cheers


>
>
>
> I note that giving load a physical pathname does not work better:
>
>> (load #P"/home/pascal/.common.lisp")
> ;;; Loading "/home/pascal/.common.lisp"
> truename: no file name supplied
> Broken at LOAD.
>>> :b
> Backtrace: LOAD > eval
>>>
>
>
>
> All  the other  implementations of  Common-Lisp I  know  (CLisp, SBCL,
> CMU-CL) are able to handle _dots_ in the name of a unix file. Note the
> plural: there can  be several dots in a file name,  in addition to the
> one or two last dots used  to separate the version number and the file
> type:
>
>       filename                '.' filetype   [ '.' '~' version-number 
> '~' ]
>     | filename-without-dots [ '.' filetype ] [ '.' '~' version-number 
> '~' ]
>
> For example:  this.is.a.file.name.type.~10~
>               NNNNNNNNNNNNNNNNNNN TTTT VVVV
>
> For example:  .this.is.a.dot.file.name.type.~10~
>               NNNNNNNNNNNNNNNNNNNNNNNN TTTT VVVV
>
>
>
> In anycase,  if we want to  embed Common-Lisp into  unix programs, the
> least is to be able to work with unix paths...
>
>
> -- 
> __Pascal_Bourguignon__                   http://www.informatimago.com/
> ----------------------------------------------------------------------
> Do not adjust your mind, there is a fault in reality.
>
--
Marco Antoniotti
NYU Courant Bioinformatics Group		tel. +1 - 212 - 998 3488
715 Broadway 10th FL				fax. +1 - 212 - 998 3484
New York, NY, 10003, U.S.A.





More information about the ecl-devel mailing list