Path: csiph.com!usenet.pasdenom.info!dedibox.gegeweb.org!gegeweb.eu!nntpfeed.proxad.net!proxad.net!feeder1-2.proxad.net!usenet-fr.net!nerim.net!novso.com!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'interpreter': 0.05; 'paths': 0.07; 'removes': 0.07; 'string': 0.09; 'apis': 0.09; 'prefix': 0.09; 'received:internal': 0.09; 'subject:How': 0.10; 'anyway': 0.14; 'windows': 0.15; 'backslash': 0.16; 'backward': 0.16; 'magic': 0.16; 'message-id:@webmail.messagingengine.com': 0.16; 'pathname': 0.16; 'received:10.202': 0.16; 'received:10.202.2': 0.16; 'received:10.202.2.44': 0.16; 'received:66.111': 0.16; 'received:66.111.4': 0.16; 'received:66.111.4.27': 0.16; 'received:compute4.internal': 0.16; 'received:messagingengine.com': 0.16; 'received:out3-smtp.messagingengine.com': 0.16; 'slash': 0.16; 'subject:mirror': 0.16; 'wrote:': 0.18; 'thu,': 0.19; 'meant': 0.20; 'command': 0.22; 'certain': 0.27; 'header:In-Reply-To:1': 0.27; 'tim': 0.29; 'sep': 0.31; 'open': 0.33; 'device': 0.34; 'received:66': 0.35; 'subject:with': 0.35; 'there': 0.35; 'received:10': 0.37; 'handle': 0.38; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39; 'from:no real name:2**0': 0.61; 'free': 0.61; 'strictly': 0.61; 'header:Message-Id:1': 0.63; 'forward': 0.65; 'worth': 0.66; 'surrounding': 0.68; 'limit': 0.70; 'subjectcharset:utf-8': 0.72; '2013,': 0.91; 'relating': 0.93 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=fastmail.us; h= message-id:from:to:mime-version:content-transfer-encoding :content-type:in-reply-to:references:subject:date; s=mesmtp; bh= 8nhtYwhDynqZkdU0Kt/bwaSgBtw=; b=IweNlZTu3qWQxZ9+PpXonrogT7tUAtod fl/ZuY5Pvx683/lKrE44qhNva1ba02+j1THHyvhf1dTfxQrjum/xRdVk0alXgbwb 7BCeV4RN+f2GKgLmPjfIAUTzXG3hIsnG1Pe6vhj6jb9I18ahWbWqBYHkeL4VeozP 6PNzQNzpMDI= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=message-id:from:to:mime-version :content-transfer-encoding:content-type:in-reply-to:references :subject:date; s=smtpout; bh=8nhtYwhDynqZkdU0Kt/bwaSgBtw=; b=Sle zqktRYcesL7CcsgpaRB9dkb/Qb39tOPNdb68bz+pghsVpqzW942rex2ZOXZHgbUO qvEsXoMfZCBChMDvQYAXpJ2f4UeYKweeZQqOyAEiYm8qIsb0PPjoPMaytEtWhr68 4icSNI5CGQ0/AZlIgnnzgx+3iI187idfdQraGQVk= X-Sasl-Enc: u+V5cDIJMFvGh7wljzLYJhDAMVZlShD7XpsFRijqSq32 1378474140 From: random832@fastmail.us To: python-list@python.org MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain X-Mailer: MessagingEngine.com Webmail Interface - ajax-22680048 In-Reply-To: <84ji2914grkpljfom0kihfpfvlo33bssbo@4ax.com> References: <5225443e$0$6599$c3e8da3$5496439d@news.astraweb.com> <20130903053159.5221f886@bigbox.christie.dr> <84ji2914grkpljfom0kihfpfvlo33bssbo@4ax.com> Subject: =?UTF-8?Q?Re=3A=20How=20to=20split=20w?= =?UTF-8?Q?ith=20=22\=22=20character=2C?= =?UTF-8?Q?=20and=20licence=20copyl?= =?UTF-8?Q?eft=20mirror=20of=20=C2=A9?= Date: Fri, 06 Sep 2013 09:29:00 -0400 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 21 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1378474142 news.xs4all.nl 15922 [2001:888:2000:d::a6]:50294 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:53785 On Thu, Sep 5, 2013, at 23:33, Tim Roberts wrote: > random832@fastmail.us wrote: > > > >Of course, in 99% of situations where you can use a windows pathname in > >Python, you are free to use it with a forward slash instead of a > >backslash. > > This is actually worth repeating, because it's not well known. > > ALL Windows APIs handle forward and backward slashes interchangably. It > is only the command interpreter that requires the backslash. Technically, that's not strictly true. There are certain strings you can open that will only work with backslashes, relating to device paths and/or the magic \\?\ prefix that removes the PATH_MAX limit (CreateFileW only). That was what I meant by 99%. And many situations in the command interpreter that require a backslash can be used with forward slash by surrounding the string in quotes, which you need to do anyway when you have an arbitrary string that may contain spaces.