[Python-Dev] Compile() and Windows/Mac newlines

2010-12-29 Thread Terry Reedy
In python-list thread Does Python 3.1 accept \r\n in compile()? jmfauth notes that compile('print(999)\r\n', 'in', 'exec') works in 2.7 but not 3.1 (and 3.2 not checked) because 3.1 sees '\r' as SyntaxError. I started to respond that this is part of Py3 cleanup with newlines converted on input

Re: [Python-Dev] Compile() and Windows/Mac newlines

2010-12-29 Thread Benjamin Peterson
2010/12/29 Terry Reedy tjre...@udel.edu: In python-list thread Does Python 3.1 accept \r\n in compile()? jmfauth notes that compile('print(999)\r\n', 'in', 'exec') works in 2.7 but not 3.1 (and 3.2 not checked) because 3.1 sees '\r' as SyntaxError. I started to respond that this is part of

Re: [Python-Dev] Compile() and Windows/Mac newlines

2010-12-29 Thread Terry Reedy
On 12/29/2010 2:31 PM, Terry Reedy wrote: In python-list thread Does Python 3.1 accept \r\n in compile()? jmfauth notes that compile('print(999)\r\n', 'in', 'exec') works in 2.7 but not 3.1 (and 3.2 not checked) because 3.1 sees '\r' as SyntaxError. I started to respond that this is part of Py3

Re: [Python-Dev] Compile() and Windows/Mac newlines

2010-12-29 Thread Terry Reedy
On 12/29/2010 2:53 PM, Benjamin Peterson wrote: Type help, copyright, credits or license for more information. compile(print(999)\r\n, blah, exec) code objectmodule at 0xb353e8, file blah, line 1 I made a mistake in testing. Issue closed. Sorry for the noise. -- Terry Jan Reedy