Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
changed the doc for literal_eval in eval
  • Loading branch information
ramvikrams committed Dec 17, 2022
commit 45e57be76cae99e53aea70ce57cd5c3d275dee93
6 changes: 4 additions & 2 deletions Doc/library/functions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -554,8 +554,10 @@ are always available. They are listed here in alphabetical order.
If the given source is a string, then leading and trailing spaces and tabs
are stripped.

See :func:`ast.literal_eval` for a function that can safely evaluate strings
with expressions containing only literals.
.. versionchanged:: 3.11
:func:`ast.literal_eval` is no longer marked as safe for evaluating strings
with expressions containing only literals. For further information, please
check the documentation for :func:`ast.literal_eval`

.. audit-event:: exec code_object eval

Expand Down