merge-pathnames bug with :back component

Blake McBride blake at mcbride.name
Wed Jun 15 02:08:53 UTC 2016


I was going to add this as an error report for CCL, but I see you've
already done that.  Thanks!

Blake



On Mon, Jun 13, 2016 at 10:00 PM, Vibhu Mohindra <vibhu.mohindra at gmail.com>
wrote:

> CLHS for merge-pathnames specifies that,
>   "This removal of redundant :back keywords is repeated as many times as
>    possible."
>
> abcl-1.3.2
> The first expression below evaluates correctly, but the second produces
> an error.
>
> FCFS(34): (merge-pathnames
>             (make-pathname :directory '(:relative "a" "b" :back))
>             (make-pathname :directory '(:absolute "root")))
>
> #P"/root/a/"
> FCFS(35): (merge-pathnames
>             (make-pathname :directory '(:relative "a" "b" :back :back))
>             (make-pathname :directory '(:absolute "root")))
>
> #<THREAD "interpreter" {43B4AF3C}>: Debugger invoked on condition of
> type FILE-ERROR
>   Unsupported directory component BACK.
> Restarts:
>   0: TOP-LEVEL Return to top level.
>
> For what it's worth, CCL also produces an error. CLISP, ECL, SBCL
> correctly produce:
> #P"/root/"
>
> (That said, I'm far from a pathname expert and could be completely wrong.)
>
> Vibhu
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/armedbear-devel/attachments/20160614/ca08881e/attachment.html>


More information about the armedbear-devel mailing list