From 29dcf3f9feee1f8332e9203f8bd77d43fe948b14 Mon Sep 17 00:00:00 2001 From: user202729 <25191436+user202729@users.noreply.github.com> Date: Sat, 4 Jan 2025 20:38:34 +0700 Subject: [PATCH] Use __ to avoid overwrite shell magic variables --- src/sage/structure/coerce.pyx | 2 +- src/sage/symbolic/function.pyx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/sage/structure/coerce.pyx b/src/sage/structure/coerce.pyx index f481536f8aa..35c76cebc67 100644 --- a/src/sage/structure/coerce.pyx +++ b/src/sage/structure/coerce.pyx @@ -521,7 +521,7 @@ cdef class CoercionModel: sage: import numpy # needs numpy sage: if int(numpy.version.short_version[0]) > 1: # needs numpy - ....: _ = numpy.set_printoptions(legacy="1.25") # needs numpy + ....: __ = numpy.set_printoptions(legacy="1.25") # needs numpy sage: # needs sage.rings.real_mpfr sage: x = polygen(RR) diff --git a/src/sage/symbolic/function.pyx b/src/sage/symbolic/function.pyx index 6b087c78609..132bed222a9 100644 --- a/src/sage/symbolic/function.pyx +++ b/src/sage/symbolic/function.pyx @@ -962,7 +962,7 @@ cdef class BuiltinFunction(Function): sage: import numpy # needs numpy sage: if int(numpy.version.short_version[0]) > 1: # needs numpy - ....: _ = numpy.set_printoptions(legacy="1.25") # needs numpy + ....: __ = numpy.set_printoptions(legacy="1.25") # needs numpy sage: sin(numpy.int32(0)) # needs numpy 0.0