Skip to content

Commit 24d79ee

Browse files
authored
Merge pull request mattharrison#12 from MareinK/patch-2
Fix: argument to `exit` is optional
2 parents c731e05 + c50f34d commit 24d79ee

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

python.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -779,7 +779,7 @@ In the default namespace you have access to various callables:
779779
``enumerate(seq, [start])`` Return iterator of index, item tuple pairs. Index begins at ``start`` or ``0`` (default)
780780
``eval(source, globals=None, locals=None)`` Run ``source`` (expression string or result of ``compile``) with globals and locals
781781
``exec(source, globals=None, locals=None)`` Run ``source`` (statement string or result of ``compile``) with globals and locals
782-
``exit(code)`` Exit Python interpreter and return code
782+
``exit([code])`` Exit Python interpreter and return code (default 0)
783783
``filter([function], seq)`` Return iterator of items where ``function(item)`` is truthy (or ``item`` is truthy if ``function`` is missing)
784784
``float(x)`` Convert string or number to float (call ``x.__float__()``)
785785
``format(obj, fmt)`` Format protocol (call ``obj.__format__(fmt)``)

0 commit comments

Comments
 (0)