Skip to content

Commit 2ec492a

Browse files
author
Release Manager
committed
gh-36812: made changes to the documentaiton of developer in python3 print removed the old python2 print statment information from the developer documentation Fixes #36807 removed the "Python3 print: Python3 syntax for print must be used in Sage code and doctests. If you use an old-style print in doctests, it will raise a SyntaxError:" and changed it with "In SageMath code and doctests, adhere to Python 3 syntax for the print function. Use parentheses as follows:" URL: #36812 Reported by: Aman Moon Reviewer(s): Aman Moon, Dima Pasechnik, Martin Rubey
2 parents 27a07da + 5468550 commit 2ec492a

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

src/doc/en/developer/coding_basics.rst

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1039,17 +1039,6 @@ written.
10391039
The :ref:`doctest fixer <section-fixdoctests-optional-needs>` uses
10401040
tab stops at columns 48, 56, 64, ... for these tags.
10411041

1042-
- **Python3 print:** Python3 syntax for print must be used in Sage
1043-
code and doctests. If you use an old-style print in doctests, it
1044-
will raise a SyntaxError::
1045-
1046-
sage: print "not like that"
1047-
Traceback (most recent call last):
1048-
...
1049-
SyntaxError: ...
1050-
sage: print("but like this")
1051-
but like this
1052-
10531042
- **Split long lines:** You may want to split long lines of code with a
10541043
backslash. Note: this syntax is non-standard and may be removed in the
10551044
future::

0 commit comments

Comments
 (0)