Boost logo

Boost :

From: Victor A. Wagner, Jr. (vawjr_at_[hidden])
Date: 2003-11-25 19:19:27

If you get offended easily you might want to skip my comments

You know, most people simply want to be able to say.... "When I use this
'name', in this directory, I want it to behave like it's really "some name
in some (other) place". They don't give a <insert favorite expletive here>
how it's done, whether it's a hard-link, soft-link, symbolic-link, they
"just want it done". That is, they want a synonym for something else.

I really think a HUGE problem that we in the C (to start) and now the C++
community has is that there are too many people who think first, foremost,
and always of "how is this implemented" when they look at some syntax.
We have nonsense in the language (the first example that pops to mind, I
could go on for hours on this topic) that prohibits using "switch
(somearbitrarystring)..." because _some_ people seem to insist that "a
switch implies using a jump table". Which is patently <insert 2nd favorite
expletive here> since all the compilers I've worked on create the
equivalent of if()... else if() ... else if()... if the jump table would be
very sparse.

I believe we have exactly the same situation here. We're worried about the
exact semantics of how *nix does things (about which _I_ couldn't give a
flying <insert 3rd favorite expletive here>). I really don't. I want the
ability to say to the filesystem: "in the future when someone says
"blahblah" you should instead refer to "halbhalb" ". And it shouldn't
matter whether I'm talking files or directories or volumes or whatever.
I don't care if we use hardlinks, softlinks, reparsepoints, or what. It
would be NICE (very nice) if after we do this, the OS believed the alias as
well, and that other programs attempting to use files and directories would
accept our fictions as reality also.
At Tuesday 2003-11-25 12:32, you wrote:
>"Bronek Kozicki" <brok_at_[hidden]> writes:
> > Victor A. Wagner, Jr. <vawjr_at_[hidden]> wrote:
> >> There _is_ a mechanism for creating hard links to directories on
> >> NTFS. I don't know what the relevant runtime calls are, but I have a
> >> utility that creates them. When you do a dir on a directory which
> > the same mechanism can be used to create hard links to files on NTFS.
> > This mechanism is called "reparse points". You can create hard links
> > with DeviceIoControl (Win32 Storage API) function called with control
> > be used to query for hard links. It's documented here:
> >
> >
> >
> > Simple utility for managing junctions (directory hard links) is
> > available here, with source:
> >
>AFAIK, junctions are not like POSIX hard links because they do not
>involve a reference count, and can refer to directories on other
>filesystems. Thus, they are like (absolute-path) symbolic links. The
>real question, I suppose, is whether NTFS supports these "junctions" or
>symbolic links to files in addition to directories. I am guessing the
>answer in no, and in any case the filesystem library could simply throw
>an exception if the user attempted to create a file symbolic link on
>(Note that the hard links created by CreateHardLink and BackupWrite
>_are_ like POSIX hard links, but these can only be used on files, not
>Jeremy Maitin-Shepard
>Unsubscribe & other changes:

Victor A. Wagner Jr.
The five most dangerous words in the English language:
               "There oughta be a law"

Boost list run by bdawes at, gregod at, cpdaniel at, john at