From e2f8d64c53c0e02055e30dbaf42b25d0fff8e210 Mon Sep 17 00:00:00 2001 From: Bruce Lucas Date: Mon, 15 Dec 2025 12:44:07 -0500 Subject: [PATCH 1/2] Add Module test --- test/core/convert/test_lambdify_compile.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/test/core/convert/test_lambdify_compile.py b/test/core/convert/test_lambdify_compile.py index a8bd8285e..3e5cb1694 100644 --- a/test/core/convert/test_lambdify_compile.py +++ b/test/core/convert/test_lambdify_compile.py @@ -255,6 +255,13 @@ dict(name="Which", args=[False, 1, True, 2]), dict(name="Which", args=[False, 1, True, 2, False, 3]), # + # Certain procedure constructs can be handled provided the initial + # evaluation in lambdify_compile is able to expand them to a + # non-procedural expression + # + dict(name="Module[{sum=0, i}, For[i=1, i<=3, i++, sum += Sin[i #]]; sum]&", args=[1]), + # + # # Following have no sympy_name and no mpmath_name, # but do have "number" or "numeric" in their path. # Some may be possible candidates for building out compilation @@ -447,7 +454,7 @@ def failure(name, msg): elif fail: raise Exception(f"unexpected success: result {result}, expected {expected}") else: - # print(f"{name} succeeds: expected {expected.value}, got {result}") + #print(f"{name} succeeds: expected {expected}, got {result}") pass From 0acbad081f52af3ac33bf15d94c0c781abbb9490 Mon Sep 17 00:00:00 2001 From: Bruce Lucas Date: Mon, 15 Dec 2025 12:48:30 -0500 Subject: [PATCH 2/2] Formatting --- test/core/convert/test_lambdify_compile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/core/convert/test_lambdify_compile.py b/test/core/convert/test_lambdify_compile.py index 3e5cb1694..8e7cf35c9 100644 --- a/test/core/convert/test_lambdify_compile.py +++ b/test/core/convert/test_lambdify_compile.py @@ -454,7 +454,7 @@ def failure(name, msg): elif fail: raise Exception(f"unexpected success: result {result}, expected {expected}") else: - #print(f"{name} succeeds: expected {expected}, got {result}") + # print(f"{name} succeeds: expected {expected}, got {result}") pass