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


Groups > comp.lang.python > #38263

Re: Best Practice Question

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!goblin2!goblin.stu.neva.ru!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <prvs=742f7d006=jeanmichel@sequans.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.006
X-Spam-Evidence '*H*': 0.99; '*S*': 0.00; '(even': 0.05; '(python': 0.05; 'escape': 0.07; 'string;': 0.07; 'subject:Question': 0.07; 'python': 0.09; 'backslash': 0.09; 'literal': 0.09; 'cc:addr :python-list': 0.10; 'backslash,': 0.16; 'character).': 0.16; 'characters:': 0.16; 'syntaxerror:': 0.16; 'string': 0.17; 'odd': 0.17; 'string,': 0.17; 'cc:2**0': 0.23; 'cc:no real name:2**0': 0.24; 'cc:addr:python.org': 0.25; 'header:In-Reply-To:1': 0.25; 'raw': 0.27; '(since': 0.29; 'consisting': 0.29; 'escaped': 0.29; 'pointer.': 0.29; 'remains': 0.29; 'url:mailman': 0.29; "i'm": 0.29; 'knows': 0.30; 'url:python': 0.32; '-----': 0.32; 'url:listinfo': 0.32; 'docs': 0.33; 'quotes': 0.33; 'anyone': 0.33; 'thanks': 0.34; 'but': 0.36; 'url:org': 0.36; 'thank': 0.36; 'two': 0.37; 'subject:: ': 0.38; 'store': 0.38; 'sure': 0.38; 'notice': 0.39; 'end': 0.40; 'url:mail': 0.40; 'you.': 0.61; 'received:194': 0.61; 'ever': 0.63; 'information': 0.63; 'person,': 0.65; 'disclose': 0.69; 'notice:': 0.71; 'privileged.': 0.72; 'medium.': 0.91; 'subject:Best': 0.91
X-IronPort-AV E=Sophos;i="4.84,614,1355094000"; d="scan'208";a="1154229"
X-Virus-Scanned amavisd-new at zimbra.sequans.com
Date Wed, 6 Feb 2013 11:10:42 +0100 (CET)
From Jean-Michel Pichavant <jeanmichel@sequans.com>
To Albert Hopkins <marduk@letterboxes.org>
In-Reply-To <1360075805.24397.140661187104925.0C8E7CF5@webmail.messagingengine.com>
Subject Re: Best Practice Question
MIME-Version 1.0
X-Mailer Zimbra 7.2.0_GA_2669 (ZimbraWebClient - GC7 (Linux)/7.2.0_GA_2669)
Content-Type text/plain; charset="utf-8"
Content-Transfer-Encoding base64
Cc python-list@python.org
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.1406.1360145450.2939.python-list@python.org> (permalink)
Lines 22
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1360145450 news.xs4all.nl 6867 [2001:888:2000:d::a6]:47356
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:38263

Show key headers only | View raw


----- Original Message -----
> 
> [...]
> > By the way, did someone ever notice that r'\' fails ? I'm sure
> > there's a
> > reason for that... (python 2.5) Anyone knows ?
> > 
> > r'\'
> > SyntaxError: EOL while scanning single-quoted string
> > 
> >
> "Even in a raw string, string quotes can be escaped with a backslash,
> but the backslash remains in the string; for example, r"\"" is a
> valid
> string literal consisting of two characters: a backslash and a double
> quote; r"\" is not a valid string literal (even a raw string cannot
> end
> in an odd number of backslashes). Specifically, a raw string cannot
> end
> in a single backslash (since the backslash would escape the following
> quote character). " -- python docs
> --
> http://mail.python.org/mailman/listinfo/python-list
> 

Thanks for the pointer.

JM


-- IMPORTANT NOTICE: 

The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Best Practice Question Jean-Michel Pichavant <jeanmichel@sequans.com> - 2013-02-06 11:10 +0100

csiph-web