jed-users mailing list

[2003 Date Index] [2003 Thread Index] [Other years]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]

Re: Re: __FILE__ and path_rel


On Thu, 23 Jan 2003 00:22:57 +0100 wrote Klaus Schmid <klaus.schmid@xxxxxx>:

> Guenter Milde wrote on Wednesday, January 22, 2003 3:13 PM
> 
> > If I see it right, path_rel(b, r) does a subset of
> > expand_filename(path_concat(b, r))
> 
> Did you tried this on different systems? 

This is what I missed :-(
 
> Therefore I would not recommend to use your construction instead of path_rel.
> Of course it fails for me in a very simple case: r= "..".

For me it worked, but I see the point: in the help text for expand_filename
it reads

   The `expand_filename' function expands a file to a canonical form.
   For example, under Unix, if `file' has the value `"/a/b/../c/d"', it
   returns `"/a/c/d"'.  Similarly, if `file' has the value
   `"/a/b/c//d/e"', `"/d/e"' is returned.

i.e. it works the desired way only under Unix
 
> The intention for path_rel is to handle a system-independant relative file
> specification
> (e.g. "a/b/c") of any arbitrary length in a painless way.

I.e. to translate a "Unix-convention" filename to the underlying
systems one? 

Günter

--
Milde at ife.et.tu-dresden.de


--------------------------
To unsubscribe send email to <jed-users-request@xxxxxxxxxxx> with
the word "unsubscribe" in the message body.
Need help? Email <jed-users-owner@xxxxxxxxxxx>.


[2003 date index] [2003 thread index]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]