The following passage in the HyperSpec (on make-pathname) ...

  After the components supplied explicitly by host, device, directory,
  name, type, and version are filled in, the merging rules used by
  merge-pathnames are used to fill in any unsupplied components from
  the defaults supplied by defaults.

... led me to believe that these two expressions should be equivalent,
yet in CMUCL they are not:

(merge-pathnames #P"foo/new" #P"/fee/fie/foe/name.type")
==> #p"/fee/fie/foe/foo/new.type"

(make-pathname :defaults #P"/fee/fie/foe/name.type"
               :directory '(:relative "foo")
               :name "new")
==> #p"foo/new.type"

Maybe I focussed too hard on the phrase "merging rules used by
merge-pathnames" where I should have noticed the phrase "unsupplied
components" instead?  Anyway, OpenMCL agrees with my interpretation,
producing the first result for both forms.  So who is in error, CMUCL
or OpenMCL (and I)?

- Harald

Reply via email to