Hi,

At Mon, 23 May 2005 23:06:58 +0900,
Berger, Daniel wrote in [ruby-core:05075]:
> assert_equal('../../d',
> Pathname.new('a/b/../../../../c/../d').cleanpath.to_s)
> 
> The current definition of cleanpath says, "Returns clean pathname of
> +self+ with consecutive slashes and useless dots removed.".  For the
> above test I would have expected "d" as the result.  In my
> implementation, that is what is returned.

It differs from the former two.  I can't see your reason.

  $ echo foo > d
  $ md -p x/y/a/b c
  $ cd x/y
  $ ruby -e "p IO.read('a/b/../../../../c/../d')"
  "foo\n"
  $ ruby -e "p IO.read('../../d')"
  "foo\n"
  $ ruby -e "p IO.read('d')"
  -e:1:in `read': No such file or directory - d (Errno::ENOENT)
  	from -e:1

-- 
Nobu Nakada