[Ecls-list] Problem with pathnames

Pascal J. Bourguignon pjb at informatimago.com
Thu Jan 13 16:09:32 UTC 2011


Juan Jose Garcia-Ripoll
<juanjose.garciaripoll at googlemail.com> writes:

> [I CC just in case the ECL mailing list provides me a better answer]
>
> In polishing the upcoming ECL release I discovered that there are two problems when trying to compile cl-unicode.
> One is due to a bug in ECL, the other one is due to what I believe an error in CL-UNICODE. More precisely, in build
> /dump.lisp I find
>
>   (with-output-to-source-file (out (make-pathname :name "derived-properties"
>                                                   :type :unspecific
>                                                   :directory '(:relative :up "test"))
>                                    :no-header-p t)
>
> As far as I know, :UNSPECIFIC is reserved for values that do not make sense for a filesystem, but in this
> particular case what happens is that the file does not have a file extension, not that extensions (types) do not
> exist at all.
>
> The consequence is that this lisp form creates an unprintable pathname (one which cannot be written "readably"),
> both in ECL and CLISP, and ECL righteously complains that this file can not be opened.
>
> I believe the appropriate line should be ":type nil", which works on SBCL, CLISP and ECL, AFAIK.
>
> Am I wrong?


19.2.2.2.3 says that :unspecific means that the component is ''absent''
OR ''have no meaning''.

Also, the allowance of :unspecific is implementation defined.

So while a conforming program should avoid using it (you're right they
should use NIL), an implementation can still accept it (and map it to
NIL on plateforms having no type).

19.2.2.2.3.1 is even more specific, specifying that both :unspecific and
nil should be converted to namestrings without the component.  

>From this, I would expect an implementation on unix to accept
:unspecific and cause no problem with unix pathnames.

-- 
__Pascal Bourguignon__                     http://www.informatimago.com/
A bad day in () is better than a good day in {}.





More information about the ecl-devel mailing list