From 00f068fb903ca968c37912f749fddc688614a454 Mon Sep 17 00:00:00 2001 From: "yu.dongliang" <18588496441@163.com> Date: Thu, 25 Sep 2025 21:47:39 +0800 Subject: [PATCH] js: support variable args of js function() with 'arguments[]' array --- examples/js.html | 9 +- examples/js2.html | 22 ++ html/Makefile | 4 + html/abc_html.c | 65 +++-- js/abc_libjs.c | 16 ++ js/abc_libjs.so | Bin 14440 -> 55000 bytes js/core/scf_3ac.c | 2 +- js/core/scf_basic_block.c | 8 +- js/core/scf_function.c | 5 + js/core/scf_function.h | 1 + js/core/scf_node.h | 4 + js/core/scf_operator_handler_3ac.c | 6 +- js/core/scf_optimizer.c | 11 +- js/core/scf_optimizer_auto_gc_find.c | 10 +- js/core/scf_optimizer_js_array.c | 126 ++++++++++ js/core/scf_optimizer_js_call.c | 146 ++++++++++++ js/core/scf_variable.h | 1 + js/doc.c | 156 ++++++++++-- js/parse/scf_dfa_call.c | 175 +++++++++++++- js/parse/scf_dfa_class.c | 4 +- js/parse/scf_dfa_enum.c | 4 +- js/parse/scf_dfa_expr.c | 104 +++++--- js/parse/scf_dfa_function.c | 11 +- js/parse/scf_dfa_function_js.c | 110 +++++++-- js/parse/scf_dfa_init_data.c | 26 +- js/parse/scf_dfa_switch.c | 20 +- js/parse/scf_operator_handler_semantic.c | 291 +++++++++++++++++------ js/parse/scf_parse.h | 3 +- ui/Makefile | 2 + 29 files changed, 1116 insertions(+), 226 deletions(-) create mode 100644 examples/js2.html create mode 100644 js/core/scf_optimizer_js_array.c create mode 100644 js/core/scf_optimizer_js_call.c diff --git a/examples/js.html b/examples/js.html index 146d3e4..e6b57d1 100644 --- a/examples/js.html +++ b/examples/js.html @@ -7,12 +7,13 @@
嫿jsç页é¢
+ +嫿jsç页é¢
+ + + + +