This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: grammar for "class" inheritance production slightly wrong
Type: Stage:
Components: Documentation Versions:
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: jimjjewett, loewis
Priority: normal Keywords:

Created on 2004-05-25 22:20 by jimjjewett, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (2)
msg20888 - (view) Author: Jim Jewett (jimjjewett) Date: 2004-05-25 22:20
http://www.python.org/dev/doc/devel/ref/class.html lists 
the grammar for a class statement, including an optional 
inheritance production of  "(" [expression_list] ")".

expression_list is *not* optional.  If the inheritance 
production (the parentheses) is present, then the 
expression list must be present (non-empty) as well.

"""
>>> class C():

SyntaxError: invalid syntax
"""
msg20889 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2004-06-02 13:01
Logged In: YES 
user_id=21627

Thanks for the report. Fixed in ref7.tex 1.38 and  1.35.16.2.
History
Date User Action Args
2022-04-11 14:56:04adminsetgithub: 40290
2004-05-25 22:20:53jimjjewettcreate