Path: csiph.com!usenet.pasdenom.info!news.etla.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed4.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.014 X-Spam-Evidence: '*H*': 0.97; '*S*': 0.00; 'level,': 0.07; 'assumed': 0.09; 'spaces': 0.09; 'width': 0.09; 'python': 0.11; 'posted': 0.15; '"def"': 0.16; '"for"': 0.16; 'choice,': 0.16; 'columns': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'indent': 0.16; 'multiples': 0.16; 'sane': 0.16; 'tab': 0.16; 'tabs': 0.16; 'sat,': 0.16; 'size,': 0.16; 'all.': 0.16; 'wrote:': 0.18; 'certain': 0.27; 'header:In-Reply-To:1': 0.27; 'correct': 0.29; 'am,': 0.29; 'character': 0.29; 'characters': 0.30; 'message-id:@mail.gmail.com': 0.30; 'code': 0.31; 'too.': 0.31; 'forces': 0.31; 'indentation': 0.31; 'subject:all': 0.32; 'option': 0.32; 'level.': 0.33; 'not.': 0.33; 'actual': 0.34; 'problem': 0.35; 'received:209.85': 0.35; 'problem.': 0.35; 'received:209.85.220': 0.35; 'editor': 0.35; 'received:google.com': 0.35; 'should': 0.36; 'received:209': 0.37; 'problems': 0.38; 'whatever': 0.38; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39; 'ian': 0.60; 'hardware': 0.61; 'introduced': 0.61; "you're": 0.61; 'positions': 0.67; 'believe': 0.68; 'default': 0.69; 'eight': 0.74; 'ambiguous': 0.84; 'twelve': 0.84; 'subject:you': 0.87; '2013': 0.98 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:content-type; bh=SJz3Iyuig8r2asf4KqeSM92saOCR/zc9zo7WW/zXeJM=; b=P0Rw33ySpbVPwv1Ew+lLgC7wx8G+XSuDQAD/6AQHNe9lxe1OAEt3W/NQdjsWRE3e5K cstACfX+j+pErK/IDKtTJb2u0XXFERwAVlaIEHBh87dYgynCMBxsz/3x7Vv4nc57ng43 AraViqLUSWegcI4DJ1nnI1ih8ogZYQg+ze0OZsC5vppymPWXF04lJCk4QT9mFbnQu07s WOFvE1RIufBdN69QPNf6c1ZNn2Cu2PvKTq74V29BT8O5dKyRxVSBIkEijfD8GTn9f913 IujxR101+kjn/1bG5FmOdfBAaqa04CvBk+By6Ncg8v6yqrj1P0DxAg4/6VnkrNQ+uKkf pc5A== MIME-Version: 1.0 X-Received: by 10.52.37.109 with SMTP id x13mr8567281vdj.10.1365208504493; Fri, 05 Apr 2013 17:35:04 -0700 (PDT) In-Reply-To: <95b2bc1c-57a2-48c9-85ea-cf1004c9e26c@googlegroups.com> References: <64d4fb7c-6a75-4b5f-b5c8-06a4b2b5d0cb@googlegroups.com> <906d8c05-99dc-4209-854c-7988ca7c78e3@googlegroups.com> <95b2bc1c-57a2-48c9-85ea-cf1004c9e26c@googlegroups.com> Date: Sat, 6 Apr 2013 11:35:04 +1100 Subject: Re: I hate you all From: Chris Angelico To: python-list@python.org Content-Type: text/plain; charset=ISO-8859-1 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: 26 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1365208512 news.xs4all.nl 6915 [2001:888:2000:d::a6]:53498 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:42870 On Sat, Apr 6, 2013 at 11:22 AM, wrote: > On Saturday, April 6, 2013 1:42:15 AM UTC+3, Ian wrote: > [...] >> The "def" line has four spaces. The "for" line then has a hard tab. >> This is ambiguous. If the hard tab is assumed to have a width of four >> spaces, then they are at the same indentation level. If it is assumed >> to have a width of eight spaces, then they are not. > [...] > > The correct tab stop positions have always been at 8 character columns apart. > The "ambiguity" was introduced by editors that do not follow the default value set in hardware like printers or used by consoles and terminal emulators. > > And now python forces me out of using any tab characters at all. I believe I should still have a choice, python should at lest give an option to set tab size, if the default of 8 is ambiguous now. If you're indenting four spaces per level, then indent four spaces per level. The code you posted would work perfectly if the indentation is four spaces, then eight spaces, then twelve spaces. The problem is that you have a stupid editor that's enforcing tabs instead of certain multiples of spaces - get one that'll keep them all as spaces and you won't have a problem. Or use actual tabs, and set the displayed tab width to whatever you feel like. That works, too. Neither option causes any problems with any sane tools. ChrisA