Where can I find a lexical spec of python?

程劭非 csf178 at 163.com
Wed Sep 21 11:44:52 CEST 2011


Hi, everyone, 
I've found there was several tokens used in python's grammar(http://docs.python.org/reference/grammar.html) but I didn't see their definition anywhere.  The tokens listed here: 
NEWLINE
ENDMARKER
NAME
INDENT
DEDENT
NUMBER
STRING


I've got some infomations from the source code(http://svn.python.org/projects/python/trunk/Parser/tokenizer.c) but I'm not sure which feature is only for this specified implementaion.  (I saw tabstop could be modified with comments using "tab-width:", ":tabstop=", ":ts=" or "set tabsize=", is this feature really in spec?)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20110921/106eb0af/attachment.html>


More information about the Python-list mailing list