Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #11479

Re: \? is missing in "3.1.2.4 ANSI-C Quoting" in Bash Reference Manual

Path csiph.com!au2pb.net!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!news.ripco.com!news.glorb.com!usenet.stanford.edu!not-for-mail
From Chet Ramey <chet.ramey@case.edu>
Newsgroups gnu.bash.bug
Subject Re: \? is missing in "3.1.2.4 ANSI-C Quoting" in Bash Reference Manual
Date Thu, 3 Sep 2015 15:07:05 -0400
Lines 30
Approved bug-bash@gnu.org
Message-ID <mailman.471.1441307237.19560.bug-bash@gnu.org> (permalink)
References <5A6BF229-3DFC-4D2E-977A-086612B9D740@qq.com> <55E716A3.1070701@case.edu> <5C938A0B-E5C0-4C8A-AA48-2C65E77DCAAA@qq.com>
Reply-To chet.ramey@case.edu
NNTP-Posting-Host lists.gnu.org
Mime-Version 1.0
Content-Type text/plain; charset=utf-8
Content-Transfer-Encoding 8bit
X-Trace usenet.stanford.edu 1441307238 26274 208.118.235.17 (3 Sep 2015 19:07:18 GMT)
X-Complaints-To action@cs.stanford.edu
Cc bug-bash@gnu.org, chet.ramey@case.edu
To ziyunfei <446240525@qq.com>
Envelope-to bug-bash@gnu.org
X-Enigmail-Draft-Status N1110
User-Agent Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:38.0) Gecko/20100101 Thunderbird/38.2.0
In-Reply-To <5C938A0B-E5C0-4C8A-AA48-2C65E77DCAAA@qq.com>
X-Junkmail-Status score=10/60, host=mpv6.cwru.edu
X-Junkmail-Whitelist YES (by domain whitelist at mpv1.tis.cwru.edu)
X-detected-operating-system by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
X-Received-From 129.22.105.36
X-BeenThere bug-bash@gnu.org
X-Mailman-Version 2.1.14
Precedence list
List-Id Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe <https://lists.gnu.org/mailman/options/bug-bash>, <mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive <http://lists.gnu.org/archive/html/bug-bash>
List-Post <mailto:bug-bash@gnu.org>
List-Help <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe <https://lists.gnu.org/mailman/listinfo/bug-bash>, <mailto:bug-bash-request@gnu.org?subject=subscribe>
Xref csiph.com gnu.bash.bug:11479

Show key headers only | View raw


On 9/2/15 11:46 PM, ziyunfei wrote:
> Sorry, I didn't understand your reply. What I'm saying is this: \? is shown
> in printf section:
> 
> "Causes printf to expand backslash escape sequences in the corresponding
> argument, except that ‘\c’ terminates output, backslashes in ‘\'’, ‘\"’,
> and ‘\?’ are not removed, and octal escapes beginning with ‘\0’ may contain
> up to four digits.”
> 
> but it isn't documented
> in https://www.gnu.org/software/bash/manual/html_node/ANSI_002dC-Quoting.html correspondingly
> after \’  and \”.

I guess I see what you're saying: that bash removes the backslash quoting
the `?' when processing $'...' but leaves backslashes escaping other
characters not listed in the description of $'...' unchanged.  I can add
that to the documentation.

If that's not what you mean, I guess I don't understand.  `printf %b'
expands one set of backslash escapes, and $'...' expands a slightly
different set, since they're trying to serve slightly different purposes
and have different origins.  They're separate constructs and are documented
separately.

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/

Back to gnu.bash.bug | Previous | Next | Find similar


Thread

Re: \? is missing in "3.1.2.4 ANSI-C Quoting" in Bash Reference Manual Chet Ramey <chet.ramey@case.edu> - 2015-09-03 15:07 -0400

csiph-web