Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #48943
| From | Ned Deily <nad@acm.org> |
|---|---|
| Subject | Re: n00b question on spacing |
| Date | 2013-06-22 12:34 -0700 |
| References | <CAJ=2b07ETuSuo2+3Xu6vMOJA+q1JwUFTezO3LaYLG8wXd+FLBQ@mail.gmail.com> <24094189.2779.1371851333304.JavaMail.rgacote@ip-225.appropriatesolutions.com> <CAMjeLr9iQ2Yg_YF0cSD2a9fK5upSgK42wZeNN9R8Ee2-rWKzGA@mail.gmail.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.3705.1371929669.3114.python-list@python.org> (permalink) |
In article
<CAMjeLr9iQ2Yg_YF0cSD2a9fK5upSgK42wZeNN9R8Ee2-rWKzGA@mail.gmail.com>,
Mark Janssen <dreamingforward@gmail.com> wrote:
> > Also remember when entering long lines of text that strings concatenate
> > within parenthesis.
> > So,
> > ("a, b, c"
> > "d, e, f"
> > "g, h, i")
> >
> > Is the same as ("a, b, cd, e, fg, h, i")
> There was a recent discussion about this (under "implicit string
> concatenation"). It seems this is a part of the python language
> specification that was simply undefined. (A rule probably should be
> added to the lexer to make this explicit.)
This behavior is explicitly defined in the Python Language Reference:
http://docs.python.org/3/reference/lexical_analysis.html#string-literal-c
oncatenation
--
Ned Deily,
nad@acm.org
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Re: n00b question on spacing Ned Deily <nad@acm.org> - 2013-06-22 12:34 -0700
csiph-web