Unify execution state into a single struct (#3877)

* Add ExecState that combines ProgramMemory and DynamicState

* Remove unneeded clones

* Add exec_state parameter to all KCL stdlib functions

* Move pipe value into ExecState

* Add test for pipe substitution not leaking into function calls

* KCL: Better message on assertEqual function

Also add a new no-visual test for performance testing.

* Fix new array module to use ExecState

---------

Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
This commit is contained in:
Jonathan Tran
2024-09-16 15:10:33 -04:00
committed by GitHub
parent c4ff1c2ef1
commit 0ff820d4da
44 changed files with 765 additions and 709 deletions

View File

@ -85,5 +85,9 @@ gen_test_fail!(
object_prop_not_found,
"undefined value: Property 'age' not found in object"
);
gen_test_fail!(
pipe_substitution_inside_function_called_from_pipeline,
"semantic: cannot use % outside a pipe expression"
);
gen_test!(sketch_group_in_object);
gen_test!(add_lots);