autoconf-commit
[Top][All Lists]
Advanced

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

[SCM] GNU Autoconf source repository branch, master, updated. v2.65-101-


From: Eric Blake
Subject: [SCM] GNU Autoconf source repository branch, master, updated. v2.65-101-g0fc8e49
Date: Wed, 23 Jun 2010 03:34:13 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Autoconf source repository".

http://git.sv.gnu.org/gitweb/?p=autoconf.git;a=commitdiff;h=0fc8e49cd5b3a1894a3ca0d9ffc32b364ae87dc5

The branch, master has been updated
       via  0fc8e49cd5b3a1894a3ca0d9ffc32b364ae87dc5 (commit)
      from  60e32aa3fc8a7c9c312aa6aed3187e4e943b559e (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 0fc8e49cd5b3a1894a3ca0d9ffc32b364ae87dc5
Author: Ralf Wildenhues <address@hidden>
Date:   Tue Jun 22 07:29:35 2010 +0200

    Further clarification on sed -e portability.
    
    See also http://austingroupbugs.net/view.php?id=262 and
    http://austingroupbugs.net/view.php?id=264.
    
    * doc/autoconf.texi (Limitations of Usual Tools) <sed>: Clarify
    more about sed -e and Posix limitations.
    
    Signed-off-by: Eric Blake <address@hidden>

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog         |    7 +++++++
 doc/autoconf.texi |   31 ++++++++++++++++++++++---------
 2 files changed, 29 insertions(+), 9 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 024a835..c589cce 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2010-06-22  Ralf Wildenhues  <address@hidden>
+       and Eric Blake  <address@hidden>
+
+       Further clarification on sed -e portability.
+       * doc/autoconf.texi (Limitations of Usual Tools) <sed>: Clarify
+       more about sed -e and Posix limitations.
+
 2010-06-22  Bruno Haible  <address@hidden>
 
        Document how to use literal newlines in makefile rules.
diff --git a/doc/autoconf.texi b/doc/autoconf.texi
index 1060955..35c40c8 100644
--- a/doc/autoconf.texi
+++ b/doc/autoconf.texi
@@ -18253,13 +18253,14 @@ but Posix says that this use of a semicolon has 
undefined effect if
 should use semicolon only with simple scripts that do not use these
 verbs.
 
-The argument of the @option{-e} option must be a syntactically complete
-script.  GNU @command{sed} allows to pass multiple script fragments,
-each as argument of a separate @option{-e} option, that are then combined,
-with newlines between the fragments.  A future Posix revision may allow
-this as well.  But in Posix:2008, this is not allowed, and the
address@hidden programs on Solaris 10, HP-UX 11, and AIX don't allow it
-either:
+Posix up to the 2008 revision requires the argument of the @option{-e}
+option to be a syntactically complete script.  GNU @command{sed} allows
+to pass multiple script fragments, each as argument of a separate
address@hidden option, that are then combined, with newlines between the
+fragments, and a future Posix revision may allow this as well.  This
+approach is not portable with script fragments ending in backslash; for
+example, the @command{sed} programs on Solaris 10, HP-UX 11, and AIX
+don't allow splitting in this case:
 
 @example
 $ @kbd{echo a | sed -n -e 'i\}
@@ -18269,11 +18270,23 @@ $ @kbd{echo a | sed -n -e 'i\' -e 0}
 Unrecognized command: 0
 @end example
 
-Commands inside @{ @} brackets are further restricted.  Posix says that
address@hidden
+In practice, however, this technique of joining fragments
+through @option{-e} works for multiple @command{sed} functions within
address@hidden@{} and @address@hidden, even if that is not specified by Posix:
+
address@hidden
address@hidden The quote around the closing brace silences interactive zsh.
+$ @kbd{echo a | sed -n -e '/a/@{' -e s/a/b/ -e p -e '@}'}
+b
address@hidden example
+
+Commands inside @{ @} brackets are further restricted.  Posix 2008 says that
 they cannot be preceded by addresses, @samp{!}, or @samp{;}, and that
 each command must be followed immediately by a newline, without any
 intervening blanks or semicolons.  The closing bracket must be alone on
-a line, other than white space preceding or following it.
+a line, other than white space preceding or following it.  However, a
+future version of Posix may standardize the use of addresses within brackets.
 
 Contrary to yet another urban legend, you may portably use @samp{&} in
 the replacement part of the @code{s} command to mean ``what was


hooks/post-receive
-- 
GNU Autoconf source repository



reply via email to

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