Closed Kodiologist closed 6 years ago
Related to #82 and #85, ast.Nums containing non-finite complex numbers will be dumped as their reprs instead of legal Python expressions that evaluate to the right floating-point constructs.
ast.Num
import ast, astor x = (1e1000 - 1e1000) - 1e1000j print(x) print(astor.code_gen.to_source(ast.Module([ast.Expr(ast.Num(x))])))
Both lines print as (nan-infj).
(nan-infj)
Related to #82 and #85,
ast.Num
s containing non-finite complex numbers will be dumped as their reprs instead of legal Python expressions that evaluate to the right floating-point constructs.Both lines print as
(nan-infj)
.