delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2003/09/06/15:25:18

X-Authentication-Warning: delorie.com: mail set sender to djgpp-workers-bounces using -f
Date: Sat, 06 Sep 2003 22:23:33 +0200
From: "Eli Zaretskii" <eliz AT elta DOT co DOT il>
Sender: halo1 AT zahav DOT net DOT il
To: Richard Dawe <rich AT phekda DOT freeserve DOT co DOT uk>
Message-Id: <7263-Sat06Sep2003222333+0300-eliz@elta.co.il>
X-Mailer: emacs 21.3.50 (via feedmail 8 I) and Blat ver 1.8.9
CC: djgpp-workers AT delorie DOT com
In-reply-to: <3F58FF62.5B9696B7@phekda.freeserve.co.uk> (message from Richard
Dawe on Fri, 05 Sep 2003 22:25:54 +0100)
Subject: Re: RESEND: Re: /dev/c - c: or c:/ ?
References: <002a01c370ca$b51801e0$2202a8c0 AT dualzastai> <3F550293 DOT 76E873F8 AT phekda DOT freeserve DOT co DOT uk> <u4qzu5knp DOT fsf AT elta DOT co DOT il> <3F58FF62 DOT 5B9696B7 AT phekda DOT freeserve DOT co DOT uk>
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

> Date: Fri, 05 Sep 2003 22:25:54 +0100
> From: Richard Dawe <rich AT phekda DOT freeserve DOT co DOT uk>
> > >
> > > POSIX mandates that.
> > 
> > Well, DOS isn't a Posix system ;-)  The fact that "c:" and "c:/" are
> > two different things is one of the frequent gotchas in ported
> > programs.  So the Posix compatibility is already broken here, and it
> > ain't our fault.
> 
> /dev/c is something we've introduced. I don't see why /dev/c shouldn't be
> POSIX-compliant, just because c: and c:/ are different things.

I thought I explained that: because the OS we are running on isn't
Posix.

> > "c:" isn't a relative path, it's 99% absolute path, as far as Posix
> > semantics is concerned.
> 
> How about c:foo?
> 
> Actually I think of c: being a relative path - something ../../dev/c/foo/bar.

It is closer to an absolute file name in the sense that you don't
need to prepend the current directory to it.

> Part of my objection is because of me maintaining fileutils. Wearing my
> fileutils hat I look at a path and think "is that relative". So far we have:
> 
> 1a. Starts with a slash -> absolute.
> 1b. Oops, unless it's just /dev/<letter> -> relative.
> 1c. But /dev/<letter>/something-else -> absolute.
> 2a. Starts with a drive-letter, then a slash -> absolute.
> 2b. Starts with a drive-letter, then no slash. Absolute? Relative? Really we
> need to expand it, to make it absolute. Or convert it to a ../../../dev/c/...
> path to make it relative. Aargh.

If you accept my point of view, then---puff---all those problems go
away.  All the cases you mention above are absolute file names,
period.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019