Boost logo

Boost :

From: Beman Dawes (bdawes_at_[hidden])
Date: 2002-09-14 13:48:28


At 12:00 PM 9/14/2002, John Levon wrote:

>"Canonical form
>
>Adjacent name, parent-directory elements in m_name have been recursively
>removed. "
>
>This implies that "foo/bar/../../" is not canonicalized when in this
>form. Is this correct ? Is this desired ?

"foo/bar/../../" is invalid, because of the trailing "/".

"foo/bar/../.." is valid, and would be reduced to "".

There was already a test case in path_test.cpp that was essentially
similar, but I've added a test using exactly "foo/bar/../.." and it does
pass for five Win32 compilers.

I wouldn't mind a clearer formulation of the wording you quoted above, but
couldn't come up with anything better offhand.

--Beman


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk