[rfc-i] tabs [was: sourcecode indentation]
brian.e.carpenter at gmail.com (Brian E Carpenter) Mon, 15 February 2016 01:12 UTC
From: brian.e.carpenter at gmail.com (Brian E Carpenter)
Date: Mon, 15 Feb 2016 14:12:32 +1300
Subject: [rfc-i] tabs [was: sourcecode indentation]
In-Reply-To: <6220756C-1AF7-420C-8A5B-A3189EE999C3@att.com>
References: <666F9FC6-BF2D-4827-B24A-20A8CCCC9F00@att.com>
<F0D416DA-2C0F-4E11-B62C-7B9788796102@vpnc.org> <56BFA2E7.8070400@gmail.com>
<56BFA781.10709@alum.mit.edu> <B8813042-3C6C-4653-9A3A-AAA3B2A68936@att.com>
<56C0FA8C.40305@gmail.com> <6220756C-1AF7-420C-8A5B-A3189EE999C3@att.com>
Message-ID: <56C12600.70801@gmail.com>
On 15/02/2016 11:34, HANSEN, TONY L wrote: > On 2/14/16, 5:07 PM, "Brian E Carpenter" <brian.e.carpenter at gmail.com> wrote: > > >> On 15/02/2016 08:53, HANSEN, TONY L wrote: >>> On 2/13/16, 5:00 PM, "rfc-interest on behalf of Paul Kyzivat" <rfc-interest-bounces at rfc-editor.org on behalf of pkyzivat at alum.mit.edu> wrote: >> >> ... >>>> But what does negative indent do if there are tabs at the beginning of >>>> the text? >>> >>> >>> This question is broader than indent and outdent, as we don't currently allow tabs anywhere in the XML source. >> >> Which seems to me to be the only safe choice, since what a tab means other >> than some unspecified amount of whitespace is unknowable. > > I actually mis-spoke earlier. Tabs are not allowed anywhere within figures and source code. Elsewhere within the XML, tabs have always been considered fine (unless a change got slipped in that I missed). Fair enough - because elsewhere in XML, all whitespace is equivalent anyway. > If there were demand for tab to be allowed within figures and source code, the obvious choice is to let the user specify what that amount of whitespace was. > > I note that python allows tabs (and assumes it's equal to 8 spaces when used), but a number of Python style guides recommend only allowing spaces. The Python rule is "Note that each line within a basic block must be indented by the same amount." The style guide recommends 4 spaces and doesn't like tabs. https://www.python.org/dev/peps/pep-0008/#tabs-or-spaces Brian > > Makefiles insist on tab characters. > > The XML files I send to xml2rfc today often have a mixture of tabs and spaces, because that's what my editor generates on indenting and re-indenting. It's only within figures and now source code blocks that tabs become troublesome. > > Tony Hansen > _______________________________________________ > rfc-interest mailing list > rfc-interest at rfc-editor.org > https://www.rfc-editor.org/mailman/listinfo/rfc-interest >
- [rfc-i] sourcecode indentation Joe Hildebrand jhildebr
- [rfc-i] sourcecode indentation HANSEN, TONY L
- [rfc-i] sourcecode indentation Julian Reschke
- [rfc-i] sourcecode indentation Paul Kyzivat
- [rfc-i] sourcecode indentation Paul Hoffman
- [rfc-i] sourcecode indentation Brian E Carpenter
- [rfc-i] sourcecode indentation Paul Kyzivat
- [rfc-i] sourcecode indentation Carsten Bormann
- [rfc-i] sourcecode indentation Phillip Hallam-Baker
- [rfc-i] sourcecode indentation Paul Kyzivat
- [rfc-i] sourcecode indentation Paul Kyzivat
- [rfc-i] sourcecode indentation HANSEN, TONY L
- [rfc-i] sourcecode indentation Brian E Carpenter
- [rfc-i] tabs [was: sourcecode indentation] Brian E Carpenter
- [rfc-i] sourcecode indentation Carsten Bormann
- [rfc-i] tabs [was: sourcecode indentation] HANSEN, TONY L
- [rfc-i] tabs [was: sourcecode indentation] Brian E Carpenter
- [rfc-i] sourcecode indentation Joe Hildebrand jhildebr
- [rfc-i] sourcecode indentation Joe Hildebrand jhildebr