mirror of
https://github.com/python/cpython.git
synced 2025-10-21 06:02:21 +00:00
bpo-29463: Add docstring field to some AST nodes. (#46)
* bpo-29463: Add docstring field to some AST nodes. ClassDef, ModuleDef, FunctionDef, and AsyncFunctionDef has docstring field for now. It was first statement of there body. * fix document. thanks travis! * doc fixes
This commit is contained in:
parent
1bc156430b
commit
cb41b2766d
15 changed files with 3153 additions and 3048 deletions
|
@ -27,7 +27,7 @@ class OpcodeTest(unittest.TestCase):
|
|||
with open(ann_module.__file__) as f:
|
||||
txt = f.read()
|
||||
co = compile(txt, ann_module.__file__, 'exec')
|
||||
self.assertEqual(co.co_firstlineno, 6)
|
||||
self.assertEqual(co.co_firstlineno, 8)
|
||||
except OSError:
|
||||
pass
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue