Skip to content

Commit 5ab2512

Browse files
committed
Update documentation to describe None in ast.Interpolation
1 parent e62ae02 commit 5ab2512

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Doc/library/ast.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -363,6 +363,8 @@ Literals
363363
function call).
364364
This has the same meaning as ``FormattedValue.value``.
365365
* ``str`` is a constant containing the text of the interpolation expression.
366+
367+
If ``str`` is set to ``None``, then ``value`` is used to generate code when calling :func:`ast.unparse`. This no longer guarantees that the generated code is identical to the original and is intended for code generation.
366368
* ``conversion`` is an integer:
367369

368370
* -1: no conversion

0 commit comments

Comments
 (0)