autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: document AS_BASENAME


From: Stepan Kasal
Subject: Re: document AS_BASENAME
Date: Sat, 1 Apr 2006 17:35:38 +0200
User-agent: Mutt/1.4.1i

Hello,

> Thanks for spotting that bug, but there's a simpler patch, [...]

depends of the definition of simplicity.  Eric's point probably was
that "expr ." is simpler than "expr . : '\(.\)'"

>       * lib/m4sugar/m4sh.m4 (AS_BASENAME_EXPR): Handle ///, ////, etc.
>       correctly.  Problem reported by Eric Blake.

I believe the real problem behind this is that we have two implementations 
of basename: as an ``expr'' expression and as a Sed program, and each of
them tries to handle all the corner cases.

I think it would be simpler to handle the corner cases once, by a shell
``case,'' and use expr||sed only for the non-trivial one.

(And likewise for AS_DIRNAME.)

Would you accept the attached patch?

Have a nice day,
        Stepan

Attachment: autoconf-20060401-as-basename.patch
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]