mirror of
https://github.com/python/cpython.git
synced 2025-08-30 13:38:43 +00:00
Flush out support for `class B(): pass
` syntax by adding support to the
'parser' module and 'compiler' package. Closes patch #1176012. Thanks logistix.
This commit is contained in:
parent
4ebc7e3bd0
commit
f4189916e3
5 changed files with 27 additions and 8 deletions
|
@ -127,6 +127,9 @@ class RoundtripLegalSyntaxTestCase(unittest.TestCase):
|
|||
self.check_suite("@funcattrs()\n"
|
||||
"def f(): pass")
|
||||
|
||||
def test_class_defs(self):
|
||||
self.check_suite("class foo():pass")
|
||||
|
||||
def test_import_from_statement(self):
|
||||
self.check_suite("from sys.path import *")
|
||||
self.check_suite("from sys.path import dirname")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue