From ea3d67f4debb01f8904c6f303e6867caa33c0888 Mon Sep 17 00:00:00 2001 From: mmatera Date: Tue, 25 Jul 2023 12:50:44 -0300 Subject: [PATCH] revert using sympy.sign --- mathics/builtin/makeboxes.py | 2 +- mathics/eval/arithmetic.py | 7 ------- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/mathics/builtin/makeboxes.py b/mathics/builtin/makeboxes.py index 2c25b84db..5dad2042f 100644 --- a/mathics/builtin/makeboxes.py +++ b/mathics/builtin/makeboxes.py @@ -400,7 +400,7 @@ def eval_general(self, expr, f, evaluation): result.append(to_boxes(String(right), evaluation)) return RowBox(*result) - def eval_outerprecedenceform(self, expr, precedence, form, evaluation): + def no_eval_outerprecedenceform(self, expr, precedence, form, evaluation): """MakeBoxes[PrecedenceForm[expr_, precedence_], form:StandardForm|TraditionalForm|OutputForm|InputForm]""" diff --git a/mathics/eval/arithmetic.py b/mathics/eval/arithmetic.py index 9caba6006..38606483a 100644 --- a/mathics/eval/arithmetic.py +++ b/mathics/eval/arithmetic.py @@ -256,13 +256,6 @@ def eval_Sign(expr: BaseElement) -> Optional[BaseElement]: """ if expr is a number, return its sign. """ - sympy_expr = expr.to_sympy() - if sympy_expr is not None: - print(" sympy_expr", sympy_expr) - result = from_sympy(sympy.sign(sympy_expr)) - if result is not None: - return result - return None def eval_complex_sign(n: BaseElement) -> Optional[BaseElement]: if isinstance(n, Complex):