[Python-Dev] FunctionDef.returns - explicit 'None' return type hint
Valentin Iovene
valentin at too.gy
Thu Jan 19 13:59:42 EST 2017
More information about the Python-Dev mailing list
Thu Jan 19 13:59:42 EST 2017
- Previous message (by thread): [Python-Dev] Have problem when building python3.5.1 rpm with default SPEC file
- Next message (by thread): [Python-Dev] FunctionDef.returns - explicit 'None' return type hint
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
With a ast.FunctionDef ast.AST node, is it possible to make the
difference between this function
def hello_world():
print('hello world')
and this one
def hello_world() -> None:
print('hello world')
?
In both cases, the FunctionDef node has its 'returns' (return type
hint) attribute set to None.
--
Valentin
- Previous message (by thread): [Python-Dev] Have problem when building python3.5.1 rpm with default SPEC file
- Next message (by thread): [Python-Dev] FunctionDef.returns - explicit 'None' return type hint
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-Dev mailing list