Skip to content

Commit 9a264ac

Browse files
committed
Don't use the sympy pretty printer for ints or floats
The sympy pretty printer does line breaking for ints which makes them harder to copy-paste.
1 parent cd6ccfa commit 9a264ac

2 files changed

Lines changed: 1 addition & 2 deletions

File tree

TODO.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,6 @@
124124
- Case sensitive tab completion when prefix contains capital characters
125125
- Multiline paste fails when one line has ?
126126
- Issue pasting after a single quote
127-
- SymPy pretty printer used for ints when sympy is imported
128127

129128
## 2.0 TODOs
130129

mypython/printing.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def can_print_sympy(o):
7575
elif isinstance(o, (Basic, MatrixBase, Vector, Dyadic, NDimArray)):
7676
return True
7777
elif isinstance(o, (int, float)):
78-
return True
78+
return False
7979
return False
8080
except RecursionError:
8181
return False

0 commit comments

Comments
 (0)