Due to the new quickjs release on 2025-04-26, there's a minor patch needed to fix things up.
67 lines
2.5 KiB
Diff
67 lines
2.5 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Philip Taron <philip.taron@gmail.com>
|
|
Date: Thu, 29 May 2025 17:16:43 -0700
|
|
Subject: [PATCH] Update for QuickJS 2025-04-26 release
|
|
|
|
Signed-off-by: Philip Taron <philip.taron@gmail.com>
|
|
---
|
|
setup.py | 6 +++---
|
|
test_quickjs.py | 6 +++---
|
|
2 files changed, 6 insertions(+), 6 deletions(-)
|
|
|
|
diff --git a/setup.py b/setup.py
|
|
index 9d17af357dcadc40478789ef9c82ac82632967d3..d0b4ff2bd7f3450f6f055ee9e2eda6b591d70689 100644
|
|
--- a/setup.py
|
|
+++ b/setup.py
|
|
@@ -16,7 +16,7 @@ if sys.platform == "win32":
|
|
# system PATH when compiling.
|
|
# 3. The code below will moneky-patch distutils to work.
|
|
import distutils.cygwinccompiler
|
|
- distutils.cygwinccompiler.get_msvcr = lambda: []
|
|
+ distutils.cygwinccompiler.get_msvcr = lambda: []
|
|
# Make sure that pthreads is linked statically, otherwise we run into problems
|
|
# on computers where it is not installed.
|
|
extra_link_args = ["-static"]
|
|
@@ -26,7 +26,7 @@ def get_c_sources(include_headers=False):
|
|
sources = [
|
|
"module.c",
|
|
"upstream-quickjs/cutils.c",
|
|
- "upstream-quickjs/libbf.c",
|
|
+ "upstream-quickjs/dtoa.c",
|
|
"upstream-quickjs/libregexp.c",
|
|
"upstream-quickjs/libunicode.c",
|
|
"upstream-quickjs/quickjs.c",
|
|
@@ -34,7 +34,7 @@ def get_c_sources(include_headers=False):
|
|
if include_headers:
|
|
sources += [
|
|
"upstream-quickjs/cutils.h",
|
|
- "upstream-quickjs/libbf.h",
|
|
+ "upstream-quickjs/dtoa.h",
|
|
"upstream-quickjs/libregexp-opcode.h",
|
|
"upstream-quickjs/libregexp.h",
|
|
"upstream-quickjs/libunicode-table.h",
|
|
diff --git a/test_quickjs.py b/test_quickjs.py
|
|
index 1f6dec7ccd15092e98e80a9139ae2acff359b010..9444234655fba9d932ce92c82b9d8da8fe83ad5b 100644
|
|
--- a/test_quickjs.py
|
|
+++ b/test_quickjs.py
|
|
@@ -105,8 +105,8 @@ class Context(unittest.TestCase):
|
|
else:
|
|
self.fail("Expected exception.")
|
|
|
|
- self.assertIn("at funcA (<input>:3)\n", msg)
|
|
- self.assertIn("at funcB (<input>:6)\n", msg)
|
|
+ self.assertIn("at funcA (<input>:3:24)\n", msg)
|
|
+ self.assertIn("at funcB (<input>:6:26)\n", msg)
|
|
|
|
def test_memory_limit(self):
|
|
code = """
|
|
@@ -508,7 +508,7 @@ class FunctionTest(unittest.TestCase):
|
|
""")
|
|
|
|
self.assertEqual(f(100), 100)
|
|
- limit = 500
|
|
+ limit = 1500
|
|
with self.assertRaises(quickjs.StackOverflow):
|
|
f(limit)
|
|
f.set_max_stack_size(2000 * limit)
|