[issue9780] fill character cannot be '{'

2010-09-06 Thread Eric Smith
Eric Smith added the comment: Sorry to respond late. The reason for this is that the parsing of the string (as delimited by "{" and "}") happens before the results are then interpreted as format specifiers. There's no way around it, short of the parser understanding every object's formatting

[issue9780] fill character cannot be '{'

2010-09-05 Thread Georg Brandl
Georg Brandl added the comment: Fixed docs in r84553. (That builtin format() supports this is no surprise, and has no influence on the validity in format strings.) -- nosy: +georg.brandl resolution: -> fixed status: open -> closed ___ Python track

[issue9780] fill character cannot be '{'

2010-09-05 Thread Éric Araujo
Éric Araujo added the comment: Thanks for clarifying. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:/

[issue9780] fill character cannot be '{'

2010-09-05 Thread Florent Xicluna
Florent Xicluna added the comment: The PEP 3101 does not prohibit any character for the 'fill' argument. Another example which just works: >>> '{:{fill}^6}'.format(42, fill='{') '{{42{{' >>> '{:{fill}^6}'.format(42, fill='}') '}}42}}' I don't care if '{' and '}' are prohibited when using si

[issue9780] fill character cannot be '{'

2010-09-05 Thread Éric Araujo
Éric Araujo added the comment: Looks more like a behavior bug than a doc bug to me. Does the doc comply with the PEP? -- nosy: +eric.araujo, eric.smith ___ Python tracker ___ __

[issue9780] fill character cannot be '{'

2010-09-05 Thread Florent Xicluna
New submission from Florent Xicluna : According to the documentation: "The fill character can be any character other than ‘}’ (which signifies the end of the field)." http://docs.python.org/dev/library/string.html#format-specification-mini-language However the format() builtin accepts both '{'