[docs] Minor tweak to compile() documentation...
mikmeyer at cisco.com
Thu Sep 15 18:03:33 CEST 2011
It might be worth pointing out that the builtin "compile" function will fail
with a syntax error if you feed it text with DOS line endings.
This is almost certainly a very rare problem, but when it does bite you,
it's a pita to figure out. You can run the file just fine. You can import it
and invoke callable's from it just fine. But if you try and read()/compile()
it, it won't work unless you open'ed it in text mode - even on Unix. And the
error location is liable to just add to the confusion.
Improving the error message might be a better solution (I only checked on
3.1), but I suspect this is rare enough that a note in the documentation
More information about the docs