From c52cca6f02482b3a8b402521ccfe5138cba2151a Mon Sep 17 00:00:00 2001 From: Chris Rybicki Date: Wed, 3 Jan 2024 15:36:17 -0500 Subject: [PATCH] feat: nodeof built-in function (#5411) Closes #2027 This PR adds a `nodeof()` function, a handy built-in for reflecting on the application tree (aka construct tree) in preflight. ## Checklist - [x] Title matches [Winglang's style guide](https://www.winglang.io/contributing/start-here/pull_requests#how-are-pull-request-titles-formatted) - [x] Description explains motivation and solution - [x] Tests added (always) - [ ] Docs updated (only required for features) - [ ] Added `pr/e2e-full` label if this feature requires end-to-end testing *By submitting this pull request, I confirm that my contribution is made under the terms of the [Wing Cloud Contribution License](https://github.com/winglang/wing/blob/main/CONTRIBUTION_LICENSE.md)*. --- docs/docs/03-language-reference.md | 1 + docs/docs/07-examples/80-singletons.md | 6 +- examples/tests/invalid/global_symbols.test.w | 17 ++++ examples/tests/sdk_tests/std/node.test.w | 6 +- examples/tests/valid/construct-base.test.w | 2 +- libs/wingc/src/ast.rs | 3 + libs/wingc/src/closure_transform.rs | 14 +-- libs/wingc/src/jsify.rs | 2 +- ...methods_and_properties_on_collections.snap | 2 +- .../access_property_on_primitive.snap | 2 +- ...rty_on_value_returned_from_collection.snap | 2 +- libs/wingc/src/jsify/snapshots/builtins.snap | 2 +- .../calls_methods_on_preflight_object.snap | 2 +- ...pture_from_inside_an_inflight_closure.snap | 2 +- ...entifier_closure_from_preflight_scope.snap | 4 +- ...pture_identifier_from_preflight_scope.snap | 2 +- ...from_preflight_scope_with_method_call.snap | 2 +- ...om_preflight_scope_with_nested_object.snap | 2 +- ...er_from_preflight_scope_with_property.snap | 2 +- .../snapshots/capture_in_keyword_args.snap | 2 +- .../capture_object_with_this_in_name.snap | 2 +- .../src/jsify/snapshots/capture_token.snap | 2 +- ...type_inflight_class_sibling_from_init.snap | 2 +- ...pe_inflight_class_sibling_from_method.snap | 2 +- ...e_new_inflight_class_inner_no_capture.snap | 2 +- ...capture_type_new_inflight_class_outer.snap | 2 +- .../snapshots/capture_type_static_method.snap | 2 +- ...ure_type_static_method_inflight_class.snap | 2 +- .../capture_var_from_method_inflight.snap | 2 +- ...ht_class_extends_outer_inflight_class.snap | 2 +- .../src/jsify/snapshots/closure_field.snap | 4 +- .../wingc/src/jsify/snapshots/enum_value.snap | 4 +- .../free_inflight_obj_from_inflight.snap | 2 +- .../jsify/snapshots/func_returns_func.snap | 2 +- .../src/jsify/snapshots/indirect_capture.snap | 2 +- ..._extends_both_inside_inflight_closure.snap | 2 +- .../snapshots/inline_inflight_class.snap | 2 +- .../src/jsify/snapshots/json_object.snap | 2 +- ...ary_preflight_and_inflight_expression.snap | 2 +- .../lift_binary_preflight_expression.snap | 2 +- ...ft_element_from_collection_of_objects.snap | 2 +- .../snapshots/lift_inflight_closure.snap | 4 +- .../lift_inside_preflight_method.snap | 2 +- .../src/jsify/snapshots/lift_string.snap | 2 +- libs/wingc/src/jsify/snapshots/lift_this.snap | 2 +- .../jsify/snapshots/lift_var_with_this.snap | 2 +- .../src/jsify/snapshots/lift_via_closure.snap | 4 +- .../lift_via_closure_class_explicit.snap | 2 +- .../namespaced_static_from_inflight.snap | 2 +- ...ed_inflight_after_preflight_operation.snap | 2 +- .../snapshots/nested_preflight_operation.snap | 2 +- .../jsify/snapshots/new_inflight_object.snap | 2 +- .../snapshots/no_capture_inside_methods.snap | 2 +- ...apture_of_identifier_from_inner_scope.snap | 2 +- ...capture_of_identifier_from_same_scope.snap | 2 +- ...no_capture_shadow_inside_inner_scopes.snap | 2 +- .../no_lift_shadow_inside_inner_scopes.snap | 2 +- .../jsify/snapshots/preflight_collection.snap | 2 +- ...light_collection_of_preflight_objects.snap | 2 +- ...eflight_nested_object_with_operations.snap | 2 +- .../src/jsify/snapshots/preflight_object.snap | 2 +- .../preflight_object_through_property.snap | 2 +- .../preflight_object_with_operations.snap | 2 +- .../snapshots/preflight_value_field.snap | 2 +- .../jsify/snapshots/read_primitive_value.snap | 2 +- .../snapshots/reassign_captured_variable.snap | 2 +- .../src/jsify/snapshots/ref_std_macro.snap | 2 +- .../snapshots/reference_inflight_class.snap | 2 +- .../reference_inflight_from_inflight.snap | 2 +- .../reference_lift_of_collection.snap | 2 +- .../snapshots/reference_static_inflight.snap | 2 +- ...ght_which_references_preflight_object.snap | 2 +- .../static_external_inflight_class.snap | 2 +- .../static_external_preflight_class.snap | 2 +- .../snapshots/static_inflight_operation.snap | 2 +- .../static_local_inflight_class.snap | 2 +- .../jsify/snapshots/static_on_std_type.snap | 2 +- .../jsify/snapshots/transitive_reference.snap | 2 +- ...ansitive_reference_via_inflight_class.snap | 2 +- .../transitive_reference_via_static.snap | 2 +- .../jsify/snapshots/two_identical_lifts.snap | 2 +- .../jsify/snapshots/use_util_functions.snap | 2 +- libs/wingc/src/jsify/snapshots/wait_util.snap | 2 +- libs/wingc/src/lib.rs | 80 +-------------- .../completions/call_struct_expansion.snap | 12 +++ .../call_struct_expansion_partial.snap | 12 +++ .../src/lsp/snapshots/completions/empty.snap | 12 +++ .../hide_parent_symbols_defined_later.snap | 12 +++ .../only_show_symbols_in_scope.snap | 12 +++ .../completions/struct_literal_value.snap | 12 +++ .../completions/struct_show_values.snap | 12 +++ libs/wingc/src/type_check.rs | 98 ++++++++++++++++++- libs/wingsdk/src/helpers.ts | 19 +++- libs/wingsdk/src/std/node.ts | 2 +- tools/hangar/__snapshots__/invalid.ts.snap | 92 +++++++++++++++++ .../valid/api.test.w_compile_tf-aws.md | 6 +- .../api_cors_custom.test.w_compile_tf-aws.md | 8 +- .../api_cors_default.test.w_compile_tf-aws.md | 6 +- .../api_valid_path.test.w_compile_tf-aws.md | 2 +- .../valid/assert.test.w_compile_tf-aws.md | 14 +-- ...wait_in_functions.test.w_compile_tf-aws.md | 4 +- .../valid/bring_jsii.test.w_compile_tf-aws.md | 2 +- .../bring_local.test.w_compile_tf-aws.md | 6 +- .../bring_projen.test.w_compile_tf-aws.md | 2 +- ...ring_wing_library.test.w_compile_tf-aws.md | 2 +- .../bucket_keys.test.w_compile_tf-aws.md | 2 +- ..._static_of_myself.test.w_compile_tf-aws.md | 2 +- ...inflight_variants.test.w_compile_tf-aws.md | 4 +- ...apture_containers.test.w_compile_tf-aws.md | 2 +- ...capture_in_binary.test.w_compile_tf-aws.md | 2 +- .../capture_mutables.test.w_compile_tf-aws.md | 4 +- ...apture_primitives.test.w_compile_tf-aws.md | 2 +- ...gable_class_field.test.w_compile_tf-aws.md | 6 +- ...ture_reassignable.test.w_compile_tf-aws.md | 4 +- ...resource_and_data.test.w_compile_tf-aws.md | 2 +- ..._with_no_inflight.test.w_compile_tf-aws.md | 2 +- .../capture_tokens.test.w_compile_tf-aws.md | 4 +- .../valid/captures.test.w_compile_tf-aws.md | 6 +- .../valid/class.test.w_compile_tf-aws.md | 8 +- .../closure_class.test.w_compile_tf-aws.md | 2 +- .../construct-base.test.w_compile_tf-aws.md | 2 +- .../valid/debug_env.test.w_test_sim.md | 2 +- .../deep_equality.test.w_compile_tf-aws.md | 48 ++++----- .../double_reference.test.w_compile_tf-aws.md | 2 +- .../valid/doubler.test.w_compile_tf-aws.md | 8 +- .../valid/enums.test.w_compile_tf-aws.md | 2 +- ...ing_interpolation.test.w_compile_tf-aws.md | 6 +- ...rn_implementation.test.w_compile_tf-aws.md | 4 +- .../file_counter.test.w_compile_tf-aws.md | 2 +- .../valid/for_loop.test.w_compile_tf-aws.md | 2 +- ..._returns_function.test.w_compile_tf-aws.md | 2 +- .../function_type.test.w_compile_tf-aws.md | 6 +- .../valid/hello.test.w_compile_tf-aws.md | 2 +- ...entical_inflights.test.w_compile_tf-aws.md | 4 +- .../impl_interface.test.w_compile_tf-aws.md | 4 +- .../valid/inference.test.w_compile_tf-aws.md | 2 +- ...light-subscribers.test.w_compile_tf-aws.md | 4 +- ...ht_capture_static.test.w_compile_tf-aws.md | 8 +- ...as_struct_members.test.w_compile_tf-aws.md | 4 +- ...ass_capture_const.test.w_compile_tf-aws.md | 2 +- ...class_definitions.test.w_compile_tf-aws.md | 6 +- ...r_capture_mutable.test.w_compile_tf-aws.md | 2 +- ..._inflight_closure.test.w_compile_tf-aws.md | 6 +- ..._inflight_closure.test.w_compile_tf-aws.md | 2 +- ..._interace_handler.test.w_compile_tf-aws.md | 2 +- ...lass_without_init.test.w_compile_tf-aws.md | 2 +- ...preflight_closure.test.w_compile_tf-aws.md | 2 +- .../inflight_init.test.w_compile_tf-aws.md | 8 +- ...calling_inflights.test.w_compile_tf-aws.md | 10 +- ...erit_stdlib_class.test.w_compile_tf-aws.md | 4 +- ...ce_class_inflight.test.w_compile_tf-aws.md | 2 +- .../valid/issue_2889.test.w_compile_tf-aws.md | 4 +- .../json_bucket.test.w_compile_tf-aws.md | 4 +- .../json_static.test.w_compile_tf-aws.md | 4 +- ...ft_expr_with_this.test.w_compile_tf-aws.md | 2 +- ...lift_redefinition.test.w_compile_tf-aws.md | 2 +- .../valid/lift_this.test.w_compile_tf-aws.md | 2 +- .../lift_via_closure.test.w_compile_tf-aws.md | 6 +- ..._closure_explicit.test.w_compile_tf-aws.md | 2 +- ...ft_with_phase_ind.test.w_compile_tf-aws.md | 2 +- .../new_in_static.test.w_compile_tf-aws.md | 2 +- .../valid/nil.test.w_compile_tf-aws.md | 6 +- .../valid/optionals.test.w_compile_tf-aws.md | 4 +- .../valid/print.test.w_compile_tf-aws.md | 4 +- .../valid/redis.test.w_compile_tf-aws.md | 6 +- .../valid/resource.test.w_compile_tf-aws.md | 10 +- ..._inflight_literal.test.w_compile_tf-aws.md | 2 +- ...ource_call_static.test.w_compile_tf-aws.md | 2 +- ...resource_captures.test.w_compile_tf-aws.md | 2 +- ..._captures_globals.test.w_compile_tf-aws.md | 4 +- .../valid/shadowing.test.w_compile_tf-aws.md | 4 +- .../statements_if.test.w_compile_tf-aws.md | 2 +- .../static_members.test.w_compile_tf-aws.md | 2 +- .../valid/std_string.test.w_compile_tf-aws.md | 2 +- .../valid/store.w_compile_tf-aws.md | 2 +- .../struct_from_json.test.w_compile_tf-aws.md | 10 +- .../valid/structs.test.w_compile_tf-aws.md | 2 +- .../valid/super_call.test.w_compile_tf-aws.md | 4 +- .../symbol_shadow.test.w_compile_tf-aws.md | 8 +- .../test_bucket.test.w_compile_tf-aws.md | 4 +- ...est_without_bring.test.w_compile_tf-aws.md | 2 +- ...side_init_closure.test.w_compile_tf-aws.md | 2 +- .../website_with_api.test.w_compile_tf-aws.md | 8 +- .../while_loop_await.test.w_compile_tf-aws.md | 2 +- 184 files changed, 605 insertions(+), 371 deletions(-) create mode 100644 examples/tests/invalid/global_symbols.test.w diff --git a/docs/docs/03-language-reference.md b/docs/docs/03-language-reference.md index 05bad02d8f0..f8f85517895 100644 --- a/docs/docs/03-language-reference.md +++ b/docs/docs/03-language-reference.md @@ -552,6 +552,7 @@ log("UTC: {t1.utc.toIso())}"); // output: 2023-02-09T06:21:03.000Z | `log` | logs str | | `assert` | checks a condition and _throws_ if evaluated to false | | `unsafeCast` | cast a value into a different type | +| `nodeof` | obtain the [tree node](./02-concepts/02-application-tree.md) of a preflight object | > ```TS > log("Hello {name}"); diff --git a/docs/docs/07-examples/80-singletons.md b/docs/docs/07-examples/80-singletons.md index e64938d4716..200f6525cba 100644 --- a/docs/docs/07-examples/80-singletons.md +++ b/docs/docs/07-examples/80-singletons.md @@ -16,8 +16,8 @@ bring cloud; class SingletonBucket { pub static of(scope: std.IResource): cloud.Bucket { let uid = "SingletonBucket"; - let root = std.Node.of(scope).root; - let rootNode = std.Node.of(root); + let root = nodeof(scope).root; + let rootNode = nodeof(root); return unsafeCast(rootNode.tryFindChild(uid)) ?? new cloud.Bucket() as uid in root; } } @@ -35,4 +35,4 @@ Now, in order to access our bucket from anywhere within the app, I can just use: let bucket = SingletonBucket.of(this); ``` -And we will always get the same bucket. \ No newline at end of file +And we will always get the same bucket. diff --git a/examples/tests/invalid/global_symbols.test.w b/examples/tests/invalid/global_symbols.test.w new file mode 100644 index 00000000000..877b6b545c0 --- /dev/null +++ b/examples/tests/invalid/global_symbols.test.w @@ -0,0 +1,17 @@ +let log = "hi"; +// ^Error: Symbol "log" already defined in this scope +let assert = "there"; +// ^Error: Symbol "assert" already defined in this scope +let unsafeCast = "wingnuts"; +// ^Error: Symbol "unsafeCast" already defined in this scope +let nodeof = "!"; +// ^Error: Symbol "nodeof" already defined in this scope + +log = "hi"; +// ^Error: Variable is not reassignable +assert = "there"; +// ^Error: Variable is not reassignable +unsafeCast = "wingnuts"; +// ^Error: Variable is not reassignable +nodeof = "!"; +// ^Error: Variable is not reassignable diff --git a/examples/tests/sdk_tests/std/node.test.w b/examples/tests/sdk_tests/std/node.test.w index b56ce2930c2..913f6ffb936 100644 --- a/examples/tests/sdk_tests/std/node.test.w +++ b/examples/tests/sdk_tests/std/node.test.w @@ -2,7 +2,7 @@ bring cloud; bring expect; let bucket = new cloud.Bucket(); -let app = std.Node.of(bucket).app; +let app = nodeof(bucket).app; assert(app.workdir.endsWith(".wing")); assert(app.entrypointDir.endsWith("/sdk_tests/std") || app.entrypointDir.endsWith("\\sdk_tests\\std")); app.isTestEnvironment; // don't care if it's true or false, just that it compiles @@ -10,8 +10,8 @@ app.isTestEnvironment; // don't care if it's true or false, just that it compile class SingletonBucket { pub static of(scope: std.IResource): cloud.Bucket { let uid = "SingletonBucket"; - let root = std.Node.of(scope).root; - let root_node = std.Node.of(root); + let root = nodeof(scope).root; + let root_node = nodeof(root); return unsafeCast(root_node.tryFindChild(uid)) ?? new cloud.Bucket() as uid in root; } } diff --git a/examples/tests/valid/construct-base.test.w b/examples/tests/valid/construct-base.test.w index 10faa1e1620..02d26b3f6de 100644 --- a/examples/tests/valid/construct-base.test.w +++ b/examples/tests/valid/construct-base.test.w @@ -14,7 +14,7 @@ let getPath = (c: cx.Construct): str => { }; let getDisplayName = (r: std.Resource): str? => { - return std.Node.of(r).title; + return nodeof(r).title; }; let q = new aws.sqsQueue.SqsQueue(); diff --git a/libs/wingc/src/ast.rs b/libs/wingc/src/ast.rs index 56f152ab872..9ad40c06414 100644 --- a/libs/wingc/src/ast.rs +++ b/libs/wingc/src/ast.rs @@ -309,6 +309,7 @@ pub enum UtilityFunctions { Log, Assert, UnsafeCast, + Nodeof, } impl UtilityFunctions { @@ -318,6 +319,7 @@ impl UtilityFunctions { UtilityFunctions::Log, UtilityFunctions::Assert, UtilityFunctions::UnsafeCast, + UtilityFunctions::Nodeof, ] } } @@ -328,6 +330,7 @@ impl Display for UtilityFunctions { UtilityFunctions::Log => write!(f, "log"), UtilityFunctions::Assert => write!(f, "assert"), UtilityFunctions::UnsafeCast => write!(f, "unsafeCast"), + UtilityFunctions::Nodeof => write!(f, "nodeof"), } } } diff --git a/libs/wingc/src/closure_transform.rs b/libs/wingc/src/closure_transform.rs index f27635ce64a..dc9b089f653 100644 --- a/libs/wingc/src/closure_transform.rs +++ b/libs/wingc/src/closure_transform.rs @@ -185,19 +185,15 @@ impl Fold for ClosureTransformer { // class_init_body := // ``` - // std.Node.of(this).hidden = true; + // nodeof(this).hidden = true; // ``` let std_display_of_this = Expr::new( ExprKind::Call { callee: CalleeKind::Expr(Box::new(Expr::new( - ExprKind::Reference(Reference::TypeMember { - type_name: UserDefinedType { - root: Symbol::new("std", WingSpan::for_file(file_id)), - fields: vec![Symbol::new("Node", WingSpan::for_file(file_id))], - span: WingSpan::for_file(file_id), - }, - property: Symbol::new("of", WingSpan::for_file(file_id)), - }), + ExprKind::Reference(Reference::Identifier(Symbol::new( + "nodeof", + WingSpan::for_file(file_id), + ))), WingSpan::for_file(file_id), ))), arg_list: ArgList { diff --git a/libs/wingc/src/jsify.rs b/libs/wingc/src/jsify.rs index 0e3f278c84c..e002036d2df 100644 --- a/libs/wingc/src/jsify.rs +++ b/libs/wingc/src/jsify.rs @@ -720,7 +720,7 @@ impl<'a> JSifier<'a> { BinaryOperator::Less => "<", BinaryOperator::LessOrEqual => "<=", BinaryOperator::Equal => return new_code!(expr_span, "$helpers.eq(", js_left, ", ", js_right, ")"), - BinaryOperator::NotEqual => return new_code!(expr_span, "!$helpers.eq(", js_left, ", ", js_right, ")"), + BinaryOperator::NotEqual => return new_code!(expr_span, "$helpers.neq(", js_left, ", ", js_right, ")"), BinaryOperator::LogicalAnd => "&&", BinaryOperator::LogicalOr => "||", BinaryOperator::UnwrapOr => { diff --git a/libs/wingc/src/jsify/snapshots/access_methods_and_properties_on_collections.snap b/libs/wingc/src/jsify/snapshots/access_methods_and_properties_on_collections.snap index c84fdc02332..41ce2e3bffb 100644 --- a/libs/wingc/src/jsify/snapshots/access_methods_and_properties_on_collections.snap +++ b/libs/wingc/src/jsify/snapshots/access_methods_and_properties_on_collections.snap @@ -54,7 +54,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/access_property_on_primitive.snap b/libs/wingc/src/jsify/snapshots/access_property_on_primitive.snap index dc945d885a5..3aa2ec01512 100644 --- a/libs/wingc/src/jsify/snapshots/access_property_on_primitive.snap +++ b/libs/wingc/src/jsify/snapshots/access_property_on_primitive.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/access_property_on_value_returned_from_collection.snap b/libs/wingc/src/jsify/snapshots/access_property_on_value_returned_from_collection.snap index ac650f110e3..8fd5607440b 100644 --- a/libs/wingc/src/jsify/snapshots/access_property_on_value_returned_from_collection.snap +++ b/libs/wingc/src/jsify/snapshots/access_property_on_value_returned_from_collection.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/builtins.snap b/libs/wingc/src/jsify/snapshots/builtins.snap index 07ec146266c..1b23f98635f 100644 --- a/libs/wingc/src/jsify/snapshots/builtins.snap +++ b/libs/wingc/src/jsify/snapshots/builtins.snap @@ -49,7 +49,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/calls_methods_on_preflight_object.snap b/libs/wingc/src/jsify/snapshots/calls_methods_on_preflight_object.snap index 5baf8ad2b5b..7028cf7d46c 100644 --- a/libs/wingc/src/jsify/snapshots/calls_methods_on_preflight_object.snap +++ b/libs/wingc/src/jsify/snapshots/calls_methods_on_preflight_object.snap @@ -55,7 +55,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_from_inside_an_inflight_closure.snap b/libs/wingc/src/jsify/snapshots/capture_from_inside_an_inflight_closure.snap index 77e59c01119..ebe914d42c3 100644 --- a/libs/wingc/src/jsify/snapshots/capture_from_inside_an_inflight_closure.snap +++ b/libs/wingc/src/jsify/snapshots/capture_from_inside_an_inflight_closure.snap @@ -55,7 +55,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_identifier_closure_from_preflight_scope.snap b/libs/wingc/src/jsify/snapshots/capture_identifier_closure_from_preflight_scope.snap index 30f0792a04a..6afcd76880a 100644 --- a/libs/wingc/src/jsify/snapshots/capture_identifier_closure_from_preflight_scope.snap +++ b/libs/wingc/src/jsify/snapshots/capture_identifier_closure_from_preflight_scope.snap @@ -70,7 +70,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -97,7 +97,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope.snap b/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope.snap index 91d898b1b8c..43f6536b6ff 100644 --- a/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope.snap +++ b/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope.snap @@ -50,7 +50,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_method_call.snap b/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_method_call.snap index 782233237f9..c38fa4e4bc1 100644 --- a/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_method_call.snap +++ b/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_method_call.snap @@ -96,7 +96,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_nested_object.snap b/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_nested_object.snap index ec13170bbce..0452412145e 100644 --- a/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_nested_object.snap +++ b/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_nested_object.snap @@ -101,7 +101,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_property.snap b/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_property.snap index 62f4bf6d2a4..0ef301a974c 100644 --- a/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_property.snap +++ b/libs/wingc/src/jsify/snapshots/capture_identifier_from_preflight_scope_with_property.snap @@ -50,7 +50,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_in_keyword_args.snap b/libs/wingc/src/jsify/snapshots/capture_in_keyword_args.snap index 55ed7c2791b..25a2adf2830 100644 --- a/libs/wingc/src/jsify/snapshots/capture_in_keyword_args.snap +++ b/libs/wingc/src/jsify/snapshots/capture_in_keyword_args.snap @@ -56,7 +56,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_object_with_this_in_name.snap b/libs/wingc/src/jsify/snapshots/capture_object_with_this_in_name.snap index 667bbd06312..4eb375af7e2 100644 --- a/libs/wingc/src/jsify/snapshots/capture_object_with_this_in_name.snap +++ b/libs/wingc/src/jsify/snapshots/capture_object_with_this_in_name.snap @@ -52,7 +52,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_token.snap b/libs/wingc/src/jsify/snapshots/capture_token.snap index f8a9ce2ad81..45cd60aeeec 100644 --- a/libs/wingc/src/jsify/snapshots/capture_token.snap +++ b/libs/wingc/src/jsify/snapshots/capture_token.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_type_inflight_class_sibling_from_init.snap b/libs/wingc/src/jsify/snapshots/capture_type_inflight_class_sibling_from_init.snap index 54cc08f9ea7..7079c2f2694 100644 --- a/libs/wingc/src/jsify/snapshots/capture_type_inflight_class_sibling_from_init.snap +++ b/libs/wingc/src/jsify/snapshots/capture_type_inflight_class_sibling_from_init.snap @@ -74,7 +74,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_type_inflight_class_sibling_from_method.snap b/libs/wingc/src/jsify/snapshots/capture_type_inflight_class_sibling_from_method.snap index 1ac1862b6da..8d4294db633 100644 --- a/libs/wingc/src/jsify/snapshots/capture_type_inflight_class_sibling_from_method.snap +++ b/libs/wingc/src/jsify/snapshots/capture_type_inflight_class_sibling_from_method.snap @@ -60,7 +60,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_type_new_inflight_class_inner_no_capture.snap b/libs/wingc/src/jsify/snapshots/capture_type_new_inflight_class_inner_no_capture.snap index 8c0e0491b44..bbf074e3386 100644 --- a/libs/wingc/src/jsify/snapshots/capture_type_new_inflight_class_inner_no_capture.snap +++ b/libs/wingc/src/jsify/snapshots/capture_type_new_inflight_class_inner_no_capture.snap @@ -52,7 +52,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_type_new_inflight_class_outer.snap b/libs/wingc/src/jsify/snapshots/capture_type_new_inflight_class_outer.snap index a5b6e57d323..eb60934c778 100644 --- a/libs/wingc/src/jsify/snapshots/capture_type_new_inflight_class_outer.snap +++ b/libs/wingc/src/jsify/snapshots/capture_type_new_inflight_class_outer.snap @@ -89,7 +89,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_type_static_method.snap b/libs/wingc/src/jsify/snapshots/capture_type_static_method.snap index cb4a8b31189..14ac1fdb65a 100644 --- a/libs/wingc/src/jsify/snapshots/capture_type_static_method.snap +++ b/libs/wingc/src/jsify/snapshots/capture_type_static_method.snap @@ -96,7 +96,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_type_static_method_inflight_class.snap b/libs/wingc/src/jsify/snapshots/capture_type_static_method_inflight_class.snap index 29db974a47e..f6ed1e538fc 100644 --- a/libs/wingc/src/jsify/snapshots/capture_type_static_method_inflight_class.snap +++ b/libs/wingc/src/jsify/snapshots/capture_type_static_method_inflight_class.snap @@ -94,7 +94,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/capture_var_from_method_inflight.snap b/libs/wingc/src/jsify/snapshots/capture_var_from_method_inflight.snap index 437c8e3d1c1..b9864a0db6e 100644 --- a/libs/wingc/src/jsify/snapshots/capture_var_from_method_inflight.snap +++ b/libs/wingc/src/jsify/snapshots/capture_var_from_method_inflight.snap @@ -57,7 +57,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/closed_inflight_class_extends_outer_inflight_class.snap b/libs/wingc/src/jsify/snapshots/closed_inflight_class_extends_outer_inflight_class.snap index a37958193b9..a97d5231279 100644 --- a/libs/wingc/src/jsify/snapshots/closed_inflight_class_extends_outer_inflight_class.snap +++ b/libs/wingc/src/jsify/snapshots/closed_inflight_class_extends_outer_inflight_class.snap @@ -92,7 +92,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/closure_field.snap b/libs/wingc/src/jsify/snapshots/closure_field.snap index 1d9951517fc..fc8f3502113 100644 --- a/libs/wingc/src/jsify/snapshots/closure_field.snap +++ b/libs/wingc/src/jsify/snapshots/closure_field.snap @@ -117,7 +117,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -184,7 +184,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/enum_value.snap b/libs/wingc/src/jsify/snapshots/enum_value.snap index aa22d0f6f2a..8142e9ccb2b 100644 --- a/libs/wingc/src/jsify/snapshots/enum_value.snap +++ b/libs/wingc/src/jsify/snapshots/enum_value.snap @@ -28,7 +28,7 @@ module.exports = function({ $MyEnum, $x }) { return $obj; } async handle() { - $helpers.assert(!$helpers.eq($MyEnum.B, $MyEnum.C), "MyEnum.B != MyEnum.C"); + $helpers.assert($helpers.neq($MyEnum.B, $MyEnum.C), "MyEnum.B != MyEnum.C"); $helpers.assert($helpers.eq($x, $MyEnum.C), "x == MyEnum.C"); } } @@ -54,7 +54,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/free_inflight_obj_from_inflight.snap b/libs/wingc/src/jsify/snapshots/free_inflight_obj_from_inflight.snap index 1b17c1910d5..eb5148e95e3 100644 --- a/libs/wingc/src/jsify/snapshots/free_inflight_obj_from_inflight.snap +++ b/libs/wingc/src/jsify/snapshots/free_inflight_obj_from_inflight.snap @@ -62,7 +62,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/func_returns_func.snap b/libs/wingc/src/jsify/snapshots/func_returns_func.snap index ea426b3aa71..34c05c7ced8 100644 --- a/libs/wingc/src/jsify/snapshots/func_returns_func.snap +++ b/libs/wingc/src/jsify/snapshots/func_returns_func.snap @@ -59,7 +59,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/indirect_capture.snap b/libs/wingc/src/jsify/snapshots/indirect_capture.snap index 0104b32d33d..42f7990d964 100644 --- a/libs/wingc/src/jsify/snapshots/indirect_capture.snap +++ b/libs/wingc/src/jsify/snapshots/indirect_capture.snap @@ -124,7 +124,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/inflight_class_extends_both_inside_inflight_closure.snap b/libs/wingc/src/jsify/snapshots/inflight_class_extends_both_inside_inflight_closure.snap index 2dfc6573d83..30c6dce5264 100644 --- a/libs/wingc/src/jsify/snapshots/inflight_class_extends_both_inside_inflight_closure.snap +++ b/libs/wingc/src/jsify/snapshots/inflight_class_extends_both_inside_inflight_closure.snap @@ -53,7 +53,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/inline_inflight_class.snap b/libs/wingc/src/jsify/snapshots/inline_inflight_class.snap index 4c98354b3f1..8ec17f29248 100644 --- a/libs/wingc/src/jsify/snapshots/inline_inflight_class.snap +++ b/libs/wingc/src/jsify/snapshots/inline_inflight_class.snap @@ -82,7 +82,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/json_object.snap b/libs/wingc/src/jsify/snapshots/json_object.snap index 5bd8bce7dda..1edf0c18f9b 100644 --- a/libs/wingc/src/jsify/snapshots/json_object.snap +++ b/libs/wingc/src/jsify/snapshots/json_object.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_binary_preflight_and_inflight_expression.snap b/libs/wingc/src/jsify/snapshots/lift_binary_preflight_and_inflight_expression.snap index 9fe1171026c..4ea7c9e3431 100644 --- a/libs/wingc/src/jsify/snapshots/lift_binary_preflight_and_inflight_expression.snap +++ b/libs/wingc/src/jsify/snapshots/lift_binary_preflight_and_inflight_expression.snap @@ -52,7 +52,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_binary_preflight_expression.snap b/libs/wingc/src/jsify/snapshots/lift_binary_preflight_expression.snap index 5948c9984b8..4f7bf64cd99 100644 --- a/libs/wingc/src/jsify/snapshots/lift_binary_preflight_expression.snap +++ b/libs/wingc/src/jsify/snapshots/lift_binary_preflight_expression.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_element_from_collection_of_objects.snap b/libs/wingc/src/jsify/snapshots/lift_element_from_collection_of_objects.snap index 1e39aaa2d21..a0791351397 100644 --- a/libs/wingc/src/jsify/snapshots/lift_element_from_collection_of_objects.snap +++ b/libs/wingc/src/jsify/snapshots/lift_element_from_collection_of_objects.snap @@ -53,7 +53,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_inflight_closure.snap b/libs/wingc/src/jsify/snapshots/lift_inflight_closure.snap index 9fa8275cfe7..be8c1693586 100644 --- a/libs/wingc/src/jsify/snapshots/lift_inflight_closure.snap +++ b/libs/wingc/src/jsify/snapshots/lift_inflight_closure.snap @@ -71,7 +71,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -98,7 +98,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_inside_preflight_method.snap b/libs/wingc/src/jsify/snapshots/lift_inside_preflight_method.snap index 31cb53c3663..75e55f1f491 100644 --- a/libs/wingc/src/jsify/snapshots/lift_inside_preflight_method.snap +++ b/libs/wingc/src/jsify/snapshots/lift_inside_preflight_method.snap @@ -86,7 +86,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_string.snap b/libs/wingc/src/jsify/snapshots/lift_string.snap index c024831ddb0..81b846bc364 100644 --- a/libs/wingc/src/jsify/snapshots/lift_string.snap +++ b/libs/wingc/src/jsify/snapshots/lift_string.snap @@ -50,7 +50,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_this.snap b/libs/wingc/src/jsify/snapshots/lift_this.snap index 1f98631ba7f..496aa616021 100644 --- a/libs/wingc/src/jsify/snapshots/lift_this.snap +++ b/libs/wingc/src/jsify/snapshots/lift_this.snap @@ -119,7 +119,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_var_with_this.snap b/libs/wingc/src/jsify/snapshots/lift_var_with_this.snap index 21946f22a06..5536097f59b 100644 --- a/libs/wingc/src/jsify/snapshots/lift_var_with_this.snap +++ b/libs/wingc/src/jsify/snapshots/lift_var_with_this.snap @@ -97,7 +97,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_via_closure.snap b/libs/wingc/src/jsify/snapshots/lift_via_closure.snap index 5f66b6663e9..fff768773f4 100644 --- a/libs/wingc/src/jsify/snapshots/lift_via_closure.snap +++ b/libs/wingc/src/jsify/snapshots/lift_via_closure.snap @@ -79,7 +79,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -113,7 +113,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/lift_via_closure_class_explicit.snap b/libs/wingc/src/jsify/snapshots/lift_via_closure_class_explicit.snap index bb0dc454d0f..9b20601aed6 100644 --- a/libs/wingc/src/jsify/snapshots/lift_via_closure_class_explicit.snap +++ b/libs/wingc/src/jsify/snapshots/lift_via_closure_class_explicit.snap @@ -134,7 +134,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/namespaced_static_from_inflight.snap b/libs/wingc/src/jsify/snapshots/namespaced_static_from_inflight.snap index 5dfd1136279..09c1abd9dd6 100644 --- a/libs/wingc/src/jsify/snapshots/namespaced_static_from_inflight.snap +++ b/libs/wingc/src/jsify/snapshots/namespaced_static_from_inflight.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/nested_inflight_after_preflight_operation.snap b/libs/wingc/src/jsify/snapshots/nested_inflight_after_preflight_operation.snap index 49c3141c61c..16b3802af42 100644 --- a/libs/wingc/src/jsify/snapshots/nested_inflight_after_preflight_operation.snap +++ b/libs/wingc/src/jsify/snapshots/nested_inflight_after_preflight_operation.snap @@ -103,7 +103,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/nested_preflight_operation.snap b/libs/wingc/src/jsify/snapshots/nested_preflight_operation.snap index 597e03ce9ee..2d8e71df259 100644 --- a/libs/wingc/src/jsify/snapshots/nested_preflight_operation.snap +++ b/libs/wingc/src/jsify/snapshots/nested_preflight_operation.snap @@ -148,7 +148,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/new_inflight_object.snap b/libs/wingc/src/jsify/snapshots/new_inflight_object.snap index a9790c432de..704e2facafc 100644 --- a/libs/wingc/src/jsify/snapshots/new_inflight_object.snap +++ b/libs/wingc/src/jsify/snapshots/new_inflight_object.snap @@ -89,7 +89,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/no_capture_inside_methods.snap b/libs/wingc/src/jsify/snapshots/no_capture_inside_methods.snap index dd8460ad6d6..c9da3b2a997 100644 --- a/libs/wingc/src/jsify/snapshots/no_capture_inside_methods.snap +++ b/libs/wingc/src/jsify/snapshots/no_capture_inside_methods.snap @@ -55,7 +55,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/no_capture_of_identifier_from_inner_scope.snap b/libs/wingc/src/jsify/snapshots/no_capture_of_identifier_from_inner_scope.snap index 013634342f7..0e7fd3600d7 100644 --- a/libs/wingc/src/jsify/snapshots/no_capture_of_identifier_from_inner_scope.snap +++ b/libs/wingc/src/jsify/snapshots/no_capture_of_identifier_from_inner_scope.snap @@ -55,7 +55,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/no_capture_of_identifier_from_same_scope.snap b/libs/wingc/src/jsify/snapshots/no_capture_of_identifier_from_same_scope.snap index e93c67ade34..5f94ddcd987 100644 --- a/libs/wingc/src/jsify/snapshots/no_capture_of_identifier_from_same_scope.snap +++ b/libs/wingc/src/jsify/snapshots/no_capture_of_identifier_from_same_scope.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/no_capture_shadow_inside_inner_scopes.snap b/libs/wingc/src/jsify/snapshots/no_capture_shadow_inside_inner_scopes.snap index 4afe6ba2c27..522554da085 100644 --- a/libs/wingc/src/jsify/snapshots/no_capture_shadow_inside_inner_scopes.snap +++ b/libs/wingc/src/jsify/snapshots/no_capture_shadow_inside_inner_scopes.snap @@ -63,7 +63,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/no_lift_shadow_inside_inner_scopes.snap b/libs/wingc/src/jsify/snapshots/no_lift_shadow_inside_inner_scopes.snap index 564da72a6cb..4f27731b783 100644 --- a/libs/wingc/src/jsify/snapshots/no_lift_shadow_inside_inner_scopes.snap +++ b/libs/wingc/src/jsify/snapshots/no_lift_shadow_inside_inner_scopes.snap @@ -61,7 +61,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/preflight_collection.snap b/libs/wingc/src/jsify/snapshots/preflight_collection.snap index e2f85696f41..fbb2db78cdd 100644 --- a/libs/wingc/src/jsify/snapshots/preflight_collection.snap +++ b/libs/wingc/src/jsify/snapshots/preflight_collection.snap @@ -52,7 +52,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/preflight_collection_of_preflight_objects.snap b/libs/wingc/src/jsify/snapshots/preflight_collection_of_preflight_objects.snap index 3df8a07051c..d071022b004 100644 --- a/libs/wingc/src/jsify/snapshots/preflight_collection_of_preflight_objects.snap +++ b/libs/wingc/src/jsify/snapshots/preflight_collection_of_preflight_objects.snap @@ -57,7 +57,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/preflight_nested_object_with_operations.snap b/libs/wingc/src/jsify/snapshots/preflight_nested_object_with_operations.snap index 298b891d89e..5a000e77290 100644 --- a/libs/wingc/src/jsify/snapshots/preflight_nested_object_with_operations.snap +++ b/libs/wingc/src/jsify/snapshots/preflight_nested_object_with_operations.snap @@ -101,7 +101,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/preflight_object.snap b/libs/wingc/src/jsify/snapshots/preflight_object.snap index 4c3a2110fc3..81933db2ec9 100644 --- a/libs/wingc/src/jsify/snapshots/preflight_object.snap +++ b/libs/wingc/src/jsify/snapshots/preflight_object.snap @@ -100,7 +100,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/preflight_object_through_property.snap b/libs/wingc/src/jsify/snapshots/preflight_object_through_property.snap index 484f050de93..dbc981fbe3e 100644 --- a/libs/wingc/src/jsify/snapshots/preflight_object_through_property.snap +++ b/libs/wingc/src/jsify/snapshots/preflight_object_through_property.snap @@ -102,7 +102,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/preflight_object_with_operations.snap b/libs/wingc/src/jsify/snapshots/preflight_object_with_operations.snap index 12c98a6ea69..00c7caa3df8 100644 --- a/libs/wingc/src/jsify/snapshots/preflight_object_with_operations.snap +++ b/libs/wingc/src/jsify/snapshots/preflight_object_with_operations.snap @@ -54,7 +54,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/preflight_value_field.snap b/libs/wingc/src/jsify/snapshots/preflight_value_field.snap index a2aa5f0ee2a..7cd709052db 100644 --- a/libs/wingc/src/jsify/snapshots/preflight_value_field.snap +++ b/libs/wingc/src/jsify/snapshots/preflight_value_field.snap @@ -107,7 +107,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/read_primitive_value.snap b/libs/wingc/src/jsify/snapshots/read_primitive_value.snap index 085bd427210..9b0ffc3f8cb 100644 --- a/libs/wingc/src/jsify/snapshots/read_primitive_value.snap +++ b/libs/wingc/src/jsify/snapshots/read_primitive_value.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/reassign_captured_variable.snap b/libs/wingc/src/jsify/snapshots/reassign_captured_variable.snap index aa4c0c4a593..ce16022c1d5 100644 --- a/libs/wingc/src/jsify/snapshots/reassign_captured_variable.snap +++ b/libs/wingc/src/jsify/snapshots/reassign_captured_variable.snap @@ -60,7 +60,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/ref_std_macro.snap b/libs/wingc/src/jsify/snapshots/ref_std_macro.snap index ae08a085072..4c5b2e1950c 100644 --- a/libs/wingc/src/jsify/snapshots/ref_std_macro.snap +++ b/libs/wingc/src/jsify/snapshots/ref_std_macro.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/reference_inflight_class.snap b/libs/wingc/src/jsify/snapshots/reference_inflight_class.snap index a68571de380..9f2591caa0a 100644 --- a/libs/wingc/src/jsify/snapshots/reference_inflight_class.snap +++ b/libs/wingc/src/jsify/snapshots/reference_inflight_class.snap @@ -94,7 +94,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/reference_inflight_from_inflight.snap b/libs/wingc/src/jsify/snapshots/reference_inflight_from_inflight.snap index d707dcb37c6..aea0e36bd37 100644 --- a/libs/wingc/src/jsify/snapshots/reference_inflight_from_inflight.snap +++ b/libs/wingc/src/jsify/snapshots/reference_inflight_from_inflight.snap @@ -113,7 +113,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/reference_lift_of_collection.snap b/libs/wingc/src/jsify/snapshots/reference_lift_of_collection.snap index f7bfd403263..deaf9fc0537 100644 --- a/libs/wingc/src/jsify/snapshots/reference_lift_of_collection.snap +++ b/libs/wingc/src/jsify/snapshots/reference_lift_of_collection.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/reference_static_inflight.snap b/libs/wingc/src/jsify/snapshots/reference_static_inflight.snap index d28bfa9480b..5797f4afaf3 100644 --- a/libs/wingc/src/jsify/snapshots/reference_static_inflight.snap +++ b/libs/wingc/src/jsify/snapshots/reference_static_inflight.snap @@ -96,7 +96,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/reference_static_inflight_which_references_preflight_object.snap b/libs/wingc/src/jsify/snapshots/reference_static_inflight_which_references_preflight_object.snap index 46eed0c2bcc..9303107fb78 100644 --- a/libs/wingc/src/jsify/snapshots/reference_static_inflight_which_references_preflight_object.snap +++ b/libs/wingc/src/jsify/snapshots/reference_static_inflight_which_references_preflight_object.snap @@ -112,7 +112,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/static_external_inflight_class.snap b/libs/wingc/src/jsify/snapshots/static_external_inflight_class.snap index f6ce75c5bc7..34c32615f19 100644 --- a/libs/wingc/src/jsify/snapshots/static_external_inflight_class.snap +++ b/libs/wingc/src/jsify/snapshots/static_external_inflight_class.snap @@ -105,7 +105,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/static_external_preflight_class.snap b/libs/wingc/src/jsify/snapshots/static_external_preflight_class.snap index d8034fcbc47..71b5ad4cef6 100644 --- a/libs/wingc/src/jsify/snapshots/static_external_preflight_class.snap +++ b/libs/wingc/src/jsify/snapshots/static_external_preflight_class.snap @@ -104,7 +104,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/static_inflight_operation.snap b/libs/wingc/src/jsify/snapshots/static_inflight_operation.snap index 357c5e42db0..7cd23a807fc 100644 --- a/libs/wingc/src/jsify/snapshots/static_inflight_operation.snap +++ b/libs/wingc/src/jsify/snapshots/static_inflight_operation.snap @@ -109,7 +109,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/static_local_inflight_class.snap b/libs/wingc/src/jsify/snapshots/static_local_inflight_class.snap index d0e1b033f4f..8473202f2df 100644 --- a/libs/wingc/src/jsify/snapshots/static_local_inflight_class.snap +++ b/libs/wingc/src/jsify/snapshots/static_local_inflight_class.snap @@ -71,7 +71,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/static_on_std_type.snap b/libs/wingc/src/jsify/snapshots/static_on_std_type.snap index 1552037a8d5..75d3b27070a 100644 --- a/libs/wingc/src/jsify/snapshots/static_on_std_type.snap +++ b/libs/wingc/src/jsify/snapshots/static_on_std_type.snap @@ -51,7 +51,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/transitive_reference.snap b/libs/wingc/src/jsify/snapshots/transitive_reference.snap index 3c4813911ee..9fbfd4ca3ff 100644 --- a/libs/wingc/src/jsify/snapshots/transitive_reference.snap +++ b/libs/wingc/src/jsify/snapshots/transitive_reference.snap @@ -134,7 +134,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/transitive_reference_via_inflight_class.snap b/libs/wingc/src/jsify/snapshots/transitive_reference_via_inflight_class.snap index 72ae02fe3bd..cb2e15952ed 100644 --- a/libs/wingc/src/jsify/snapshots/transitive_reference_via_inflight_class.snap +++ b/libs/wingc/src/jsify/snapshots/transitive_reference_via_inflight_class.snap @@ -110,7 +110,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/transitive_reference_via_static.snap b/libs/wingc/src/jsify/snapshots/transitive_reference_via_static.snap index a9204bb6455..d3d2a10683d 100644 --- a/libs/wingc/src/jsify/snapshots/transitive_reference_via_static.snap +++ b/libs/wingc/src/jsify/snapshots/transitive_reference_via_static.snap @@ -167,7 +167,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/two_identical_lifts.snap b/libs/wingc/src/jsify/snapshots/two_identical_lifts.snap index a441b0e6358..47ee7b6f507 100644 --- a/libs/wingc/src/jsify/snapshots/two_identical_lifts.snap +++ b/libs/wingc/src/jsify/snapshots/two_identical_lifts.snap @@ -60,7 +60,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/use_util_functions.snap b/libs/wingc/src/jsify/snapshots/use_util_functions.snap index b634871201f..5133765405a 100644 --- a/libs/wingc/src/jsify/snapshots/use_util_functions.snap +++ b/libs/wingc/src/jsify/snapshots/use_util_functions.snap @@ -50,7 +50,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/jsify/snapshots/wait_util.snap b/libs/wingc/src/jsify/snapshots/wait_util.snap index c498cdb909d..2b82de24b1e 100644 --- a/libs/wingc/src/jsify/snapshots/wait_util.snap +++ b/libs/wingc/src/jsify/snapshots/wait_util.snap @@ -57,7 +57,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/libs/wingc/src/lib.rs b/libs/wingc/src/lib.rs index 4b0e87467e5..855d106f8c4 100644 --- a/libs/wingc/src/lib.rs +++ b/libs/wingc/src/lib.rs @@ -7,7 +7,7 @@ #[macro_use] extern crate lazy_static; -use ast::{AccessModifier, Scope, Symbol, UtilityFunctions}; +use ast::{Scope, Symbol}; use camino::{Utf8Path, Utf8PathBuf}; use closure_transform::ClosureTransformer; use comp_ctx::set_custom_panic_hook; @@ -22,16 +22,14 @@ use lifting::LiftVisitor; use parser::parse_wing_project; use struct_schema::StructSchemaVisitor; use type_check::jsii_importer::JsiiImportSpec; -use type_check::symbol_env::{StatementIdx, SymbolEnvKind}; +use type_check::symbol_env::SymbolEnvKind; use type_check::type_reference_transform::TypeReferenceTransformer; -use type_check::{FunctionSignature, SymbolKind, Type}; use type_check_assert::TypeCheckAssert; use valid_json_visitor::ValidJsonVisitor; use visit::Visit; use wasm_util::{ptr_to_str, string_to_combined_ptr, WASM_RETURN_ERROR}; use wingii::type_system::TypeSystem; -use crate::docs::Docs; use crate::parser::normalize_path; use std::alloc::{alloc, dealloc, Layout}; @@ -39,7 +37,7 @@ use std::mem; use crate::ast::Phase; use crate::type_check::symbol_env::SymbolEnv; -use crate::type_check::{FunctionParameter, TypeChecker, Types}; +use crate::type_check::{TypeChecker, Types}; #[macro_use] #[cfg(test)] @@ -113,7 +111,7 @@ const WINGSDK_MUT_JSON: &'static str = "std.MutJson"; const WINGSDK_RESOURCE: &'static str = "std.Resource"; const WINGSDK_STRUCT: &'static str = "std.Struct"; const WINGSDK_TEST_CLASS_NAME: &'static str = "Test"; -// const WINGSDK_NODE: &'static str = "std.Node"; +const WINGSDK_NODE: &'static str = "std.Node"; const CONSTRUCT_BASE_CLASS: &'static str = "constructs.Construct"; const CONSTRUCT_BASE_INTERFACE: &'static str = "constructs.IConstruct"; @@ -218,61 +216,6 @@ pub fn type_check( let mut env = types.add_symbol_env(SymbolEnv::new(None, SymbolEnvKind::Scope, Phase::Preflight, 0)); types.set_scope_env(scope, env); - add_builtin( - UtilityFunctions::Log.to_string().as_str(), - Type::Function(FunctionSignature { - this_type: None, - parameters: vec![FunctionParameter { - name: "message".into(), - typeref: types.string(), - docs: Docs::with_summary("The message to log"), - variadic: false, - }], - return_type: types.void(), - phase: Phase::Independent, - js_override: Some("console.log($args$)".to_string()), - docs: Docs::with_summary("Logs a message"), - }), - scope, - types, - ); - add_builtin( - UtilityFunctions::Assert.to_string().as_str(), - Type::Function(FunctionSignature { - this_type: None, - parameters: vec![FunctionParameter { - name: "condition".into(), - typeref: types.bool(), - docs: Docs::with_summary("The condition to assert"), - variadic: false, - }], - return_type: types.void(), - phase: Phase::Independent, - js_override: Some("$helpers.assert($args$, \"$args_text$\")".to_string()), - docs: Docs::with_summary("Asserts that a condition is true"), - }), - scope, - types, - ); - add_builtin( - UtilityFunctions::UnsafeCast.to_string().as_str(), - Type::Function(FunctionSignature { - this_type: None, - parameters: vec![FunctionParameter { - name: "value".into(), - typeref: types.anything(), - docs: Docs::with_summary("The value to cast into a different type"), - variadic: false, - }], - return_type: types.anything(), - phase: Phase::Independent, - js_override: Some("$args$".to_string()), - docs: Docs::with_summary("Casts a value into a different type. This is unsafe and can cause runtime errors"), - }), - scope, - types, - ); - let mut tc = TypeChecker::new(types, file_path, file_graph, jsii_types, jsii_imports); tc.add_jsii_module_to_env( &mut env, @@ -281,24 +224,11 @@ pub fn type_check( &Symbol::global(WINGSDK_STD_MODULE), None, ); + tc.add_builtins(scope); tc.type_check_file_or_dir(file_path, scope); } -// TODO: refactor this (why is scope needed?) (move to separate module?) -fn add_builtin(name: &str, typ: Type, scope: &mut Scope, types: &mut Types) { - let sym = Symbol::global(name); - let mut scope_env = types.get_scope_env(&scope); - scope_env - .define( - &sym, - SymbolKind::make_free_variable(sym.clone(), types.add_type(typ), false, Phase::Independent), - AccessModifier::Private, - StatementIdx::Top, - ) - .expect("Failed to add builtin"); -} - pub fn compile( project_dir: &Utf8Path, source_path: &Utf8Path, diff --git a/libs/wingc/src/lsp/snapshots/completions/call_struct_expansion.snap b/libs/wingc/src/lsp/snapshots/completions/call_struct_expansion.snap index e296f4def96..0986bd99bc6 100644 --- a/libs/wingc/src/lsp/snapshots/completions/call_struct_expansion.snap +++ b/libs/wingc/src/lsp/snapshots/completions/call_struct_expansion.snap @@ -13,6 +13,18 @@ source: libs/wingc/src/lsp/completions.rs command: title: triggerCompletion command: editor.action.triggerSuggest +- label: nodeof + kind: 3 + detail: "preflight (construct: IConstruct): Node" + documentation: + kind: markdown + value: "```wing\nnodeof: preflight (construct: IConstruct): Node\n```\n---\nObtain the tree node of a preflight resource.\n### Parameters\n- `construct` — `IConstruct` — The construct to obtain the tree node of" + sortText: cc|nodeof + insertText: nodeof($1) + insertTextFormat: 2 + command: + title: triggerParameterHints + command: editor.action.triggerParameterHints - label: unsafeCast kind: 3 detail: "(value: any): any" diff --git a/libs/wingc/src/lsp/snapshots/completions/call_struct_expansion_partial.snap b/libs/wingc/src/lsp/snapshots/completions/call_struct_expansion_partial.snap index ecd1402ea8c..d103d501497 100644 --- a/libs/wingc/src/lsp/snapshots/completions/call_struct_expansion_partial.snap +++ b/libs/wingc/src/lsp/snapshots/completions/call_struct_expansion_partial.snap @@ -13,6 +13,18 @@ source: libs/wingc/src/lsp/completions.rs command: title: triggerCompletion command: editor.action.triggerSuggest +- label: nodeof + kind: 3 + detail: "preflight (construct: IConstruct): Node" + documentation: + kind: markdown + value: "```wing\nnodeof: preflight (construct: IConstruct): Node\n```\n---\nObtain the tree node of a preflight resource.\n### Parameters\n- `construct` — `IConstruct` — The construct to obtain the tree node of" + sortText: cc|nodeof + insertText: nodeof($1) + insertTextFormat: 2 + command: + title: triggerParameterHints + command: editor.action.triggerParameterHints - label: unsafeCast kind: 3 detail: "(value: any): any" diff --git a/libs/wingc/src/lsp/snapshots/completions/empty.snap b/libs/wingc/src/lsp/snapshots/completions/empty.snap index b2a2890caba..928d4683932 100644 --- a/libs/wingc/src/lsp/snapshots/completions/empty.snap +++ b/libs/wingc/src/lsp/snapshots/completions/empty.snap @@ -25,6 +25,18 @@ source: libs/wingc/src/lsp/completions.rs command: title: triggerParameterHints command: editor.action.triggerParameterHints +- label: nodeof + kind: 3 + detail: "preflight (construct: IConstruct): Node" + documentation: + kind: markdown + value: "```wing\nnodeof: preflight (construct: IConstruct): Node\n```\n---\nObtain the tree node of a preflight resource.\n### Parameters\n- `construct` — `IConstruct` — The construct to obtain the tree node of" + sortText: cc|nodeof + insertText: nodeof($1) + insertTextFormat: 2 + command: + title: triggerParameterHints + command: editor.action.triggerParameterHints - label: unsafeCast kind: 3 detail: "(value: any): any" diff --git a/libs/wingc/src/lsp/snapshots/completions/hide_parent_symbols_defined_later.snap b/libs/wingc/src/lsp/snapshots/completions/hide_parent_symbols_defined_later.snap index b81cb72ef38..549cc206761 100644 --- a/libs/wingc/src/lsp/snapshots/completions/hide_parent_symbols_defined_later.snap +++ b/libs/wingc/src/lsp/snapshots/completions/hide_parent_symbols_defined_later.snap @@ -39,6 +39,18 @@ source: libs/wingc/src/lsp/completions.rs command: title: triggerParameterHints command: editor.action.triggerParameterHints +- label: nodeof + kind: 3 + detail: "preflight (construct: IConstruct): Node" + documentation: + kind: markdown + value: "```wing\nnodeof: preflight (construct: IConstruct): Node\n```\n---\nObtain the tree node of a preflight resource.\n### Parameters\n- `construct` — `IConstruct` — The construct to obtain the tree node of" + sortText: cc|nodeof + insertText: nodeof($1) + insertTextFormat: 2 + command: + title: triggerParameterHints + command: editor.action.triggerParameterHints - label: unsafeCast kind: 3 detail: "(value: any): any" diff --git a/libs/wingc/src/lsp/snapshots/completions/only_show_symbols_in_scope.snap b/libs/wingc/src/lsp/snapshots/completions/only_show_symbols_in_scope.snap index a53b6f738e1..fca2d20168f 100644 --- a/libs/wingc/src/lsp/snapshots/completions/only_show_symbols_in_scope.snap +++ b/libs/wingc/src/lsp/snapshots/completions/only_show_symbols_in_scope.snap @@ -8,6 +8,18 @@ source: libs/wingc/src/lsp/completions.rs kind: markdown value: "```wing\npreflight a: num\n```" sortText: bb|a +- label: nodeof + kind: 3 + detail: "preflight (construct: IConstruct): Node" + documentation: + kind: markdown + value: "```wing\nnodeof: preflight (construct: IConstruct): Node\n```\n---\nObtain the tree node of a preflight resource.\n### Parameters\n- `construct` — `IConstruct` — The construct to obtain the tree node of" + sortText: cc|nodeof + insertText: nodeof($1) + insertTextFormat: 2 + command: + title: triggerParameterHints + command: editor.action.triggerParameterHints - label: unsafeCast kind: 3 detail: "(value: any): any" diff --git a/libs/wingc/src/lsp/snapshots/completions/struct_literal_value.snap b/libs/wingc/src/lsp/snapshots/completions/struct_literal_value.snap index 1b9d234b5a5..efde023e612 100644 --- a/libs/wingc/src/lsp/snapshots/completions/struct_literal_value.snap +++ b/libs/wingc/src/lsp/snapshots/completions/struct_literal_value.snap @@ -1,6 +1,18 @@ --- source: libs/wingc/src/lsp/completions.rs --- +- label: nodeof + kind: 3 + detail: "preflight (construct: IConstruct): Node" + documentation: + kind: markdown + value: "```wing\nnodeof: preflight (construct: IConstruct): Node\n```\n---\nObtain the tree node of a preflight resource.\n### Parameters\n- `construct` — `IConstruct` — The construct to obtain the tree node of" + sortText: cc|nodeof + insertText: nodeof($1) + insertTextFormat: 2 + command: + title: triggerParameterHints + command: editor.action.triggerParameterHints - label: unsafeCast kind: 3 detail: "(value: any): any" diff --git a/libs/wingc/src/lsp/snapshots/completions/struct_show_values.snap b/libs/wingc/src/lsp/snapshots/completions/struct_show_values.snap index b25ee967f11..887142a4126 100644 --- a/libs/wingc/src/lsp/snapshots/completions/struct_show_values.snap +++ b/libs/wingc/src/lsp/snapshots/completions/struct_show_values.snap @@ -8,6 +8,18 @@ source: libs/wingc/src/lsp/completions.rs kind: markdown value: "```wing\npreflight x: num\n```" sortText: bb|x +- label: nodeof + kind: 3 + detail: "preflight (construct: IConstruct): Node" + documentation: + kind: markdown + value: "```wing\nnodeof: preflight (construct: IConstruct): Node\n```\n---\nObtain the tree node of a preflight resource.\n### Parameters\n- `construct` — `IConstruct` — The construct to obtain the tree node of" + sortText: cc|nodeof + insertText: nodeof($1) + insertTextFormat: 2 + command: + title: triggerParameterHints + command: editor.action.triggerParameterHints - label: unsafeCast kind: 3 detail: "(value: any): any" diff --git a/libs/wingc/src/type_check.rs b/libs/wingc/src/type_check.rs index 70dc41e26f5..d1a58767da7 100644 --- a/libs/wingc/src/type_check.rs +++ b/libs/wingc/src/type_check.rs @@ -8,7 +8,7 @@ pub(crate) mod type_reference_transform; use crate::ast::{ self, AccessModifier, AssignmentKind, BringSource, CalleeKind, ClassField, ExprId, FunctionDefinition, IfLet, New, - TypeAnnotationKind, + TypeAnnotationKind, UtilityFunctions, }; use crate::ast::{ ArgList, BinaryOperator, Class as AstClass, Elifs, Expr, ExprKind, FunctionBody, @@ -26,7 +26,7 @@ use crate::visit_types::{VisitType, VisitTypeMut}; use crate::{ dbg_panic, debug, CONSTRUCT_BASE_INTERFACE, UTIL_CLASS_NAME, WINGSDK_ARRAY, WINGSDK_ASSEMBLY_NAME, WINGSDK_BRINGABLE_MODULES, WINGSDK_DURATION, WINGSDK_GENERIC, WINGSDK_JSON, WINGSDK_MAP, WINGSDK_MUT_ARRAY, - WINGSDK_MUT_JSON, WINGSDK_MUT_MAP, WINGSDK_MUT_SET, WINGSDK_RESOURCE, WINGSDK_SET, WINGSDK_STD_MODULE, + WINGSDK_MUT_JSON, WINGSDK_MUT_MAP, WINGSDK_MUT_SET, WINGSDK_NODE, WINGSDK_RESOURCE, WINGSDK_SET, WINGSDK_STD_MODULE, WINGSDK_STRING, WINGSDK_STRUCT, }; use camino::{Utf8Path, Utf8PathBuf}; @@ -1895,6 +1895,100 @@ impl<'a> TypeChecker<'a> { } } + pub fn add_builtins(&mut self, scope: &mut Scope) { + self.add_builtin( + UtilityFunctions::Log.to_string().as_str(), + Type::Function(FunctionSignature { + this_type: None, + parameters: vec![FunctionParameter { + name: "message".into(), + typeref: self.types.string(), + docs: Docs::with_summary("The message to log"), + variadic: false, + }], + return_type: self.types.void(), + phase: Phase::Independent, + js_override: Some("console.log($args$)".to_string()), + docs: Docs::with_summary("Logs a message"), + }), + scope, + ); + self.add_builtin( + UtilityFunctions::Assert.to_string().as_str(), + Type::Function(FunctionSignature { + this_type: None, + parameters: vec![FunctionParameter { + name: "condition".into(), + typeref: self.types.bool(), + docs: Docs::with_summary("The condition to assert"), + variadic: false, + }], + return_type: self.types.void(), + phase: Phase::Independent, + js_override: Some("$helpers.assert($args$, \"$args_text$\")".to_string()), + docs: Docs::with_summary("Asserts that a condition is true"), + }), + scope, + ); + self.add_builtin( + UtilityFunctions::UnsafeCast.to_string().as_str(), + Type::Function(FunctionSignature { + this_type: None, + parameters: vec![FunctionParameter { + name: "value".into(), + typeref: self.types.anything(), + docs: Docs::with_summary("The value to cast into a different type"), + variadic: false, + }], + return_type: self.types.anything(), + phase: Phase::Independent, + js_override: Some("$args$".to_string()), + docs: Docs::with_summary("Casts a value into a different type. This is unsafe and can cause runtime errors"), + }), + scope, + ); + + let std_node_fqn = format!("{}.{}", WINGSDK_ASSEMBLY_NAME, WINGSDK_NODE); + let std_node = self + .types + .libraries + .lookup_nested_str(&std_node_fqn, None) + .expect("std.Node not found in type system") + .0 + .as_type() + .expect("std.Node was found but it's not a type"); + self.add_builtin( + UtilityFunctions::Nodeof.to_string().as_str(), + Type::Function(FunctionSignature { + this_type: None, + parameters: vec![FunctionParameter { + name: "construct".into(), + typeref: self.types.construct_interface(), + docs: Docs::with_summary("The construct to obtain the tree node of"), + variadic: false, + }], + return_type: std_node, + phase: Phase::Preflight, + js_override: Some("$helpers.nodeof($args$)".to_string()), + docs: Docs::with_summary("Obtain the tree node of a preflight resource."), + }), + scope, + ); + } + + pub fn add_builtin(&mut self, name: &str, typ: Type, scope: &mut Scope) { + let sym = Symbol::global(name); + let mut scope_env = self.types.get_scope_env(&scope); + scope_env + .define( + &sym, + SymbolKind::make_free_variable(sym.clone(), self.types.add_type(typ), false, Phase::Independent), + AccessModifier::Private, + StatementIdx::Top, + ) + .expect("Failed to add builtin"); + } + // Validates types in the expression make sense and returns the expression's inferred type fn type_check_exp(&mut self, exp: &Expr, env: &mut SymbolEnv) -> (TypeRef, Phase) { self.type_check_exp_ext(exp, env, ExprVisitInfo::NoInfo) diff --git a/libs/wingsdk/src/helpers.ts b/libs/wingsdk/src/helpers.ts index 2be88470c54..99b33d89ef7 100644 --- a/libs/wingsdk/src/helpers.ts +++ b/libs/wingsdk/src/helpers.ts @@ -1,4 +1,8 @@ -import { deepStrictEqual } from "node:assert"; +// Code in this file will be automatically included in all inflight code bundles, +// so avoid importing anything heavy here. +import { deepStrictEqual, notDeepStrictEqual } from "node:assert"; +import type { Construct } from "constructs"; +import { Node } from "./std/node"; export function eq(a: any, b: any): boolean { try { @@ -9,6 +13,15 @@ export function eq(a: any, b: any): boolean { } } +export function neq(a: any, b: any): boolean { + try { + notDeepStrictEqual(a, b); + return true; + } catch { + return false; + } +} + export function assert(condition: any, message: string): asserts condition { if (!condition) { throw new Error("assertion failed: " + message); @@ -24,3 +37,7 @@ export function range(start: number, end: number, inclusive: boolean) { } return iterator(); } + +export function nodeof(construct: Construct): Node { + return Node.of(construct); +} diff --git a/libs/wingsdk/src/std/node.ts b/libs/wingsdk/src/std/node.ts index cb0d3cfa583..43aefd94941 100644 --- a/libs/wingsdk/src/std/node.ts +++ b/libs/wingsdk/src/std/node.ts @@ -6,7 +6,7 @@ import { MetadataOptions, IValidation, } from "constructs"; -import { Connections } from "../core"; +import { Connections } from "../core/connections"; const NODE_SYMBOL = Symbol.for("@winglang/sdk.std.Node"); export const APP_SYMBOL = Symbol.for("@winglang/sdk.std.Node/app"); diff --git a/tools/hangar/__snapshots__/invalid.ts.snap b/tools/hangar/__snapshots__/invalid.ts.snap index 26289d462d6..8c27294fc34 100644 --- a/tools/hangar/__snapshots__/invalid.ts.snap +++ b/tools/hangar/__snapshots__/invalid.ts.snap @@ -1554,6 +1554,98 @@ error: Expected type to be \\"Bucket\\", but got \\"bool\\" instead +Tests 1 failed (1) +Test Files 1 failed (1) +Duration " +`; + +exports[`global_symbols.test.w 1`] = ` +"error: Symbol \\"log\\" already defined in this scope + --> ../../../examples/tests/invalid/global_symbols.test.w:1:5 + | +1 | let log = \\"hi\\"; + | ^^^ Symbol \\"log\\" already defined in this scope + + +error: Symbol \\"assert\\" already defined in this scope + --> ../../../examples/tests/invalid/global_symbols.test.w:3:5 + | +3 | let assert = \\"there\\"; + | ^^^^^^ Symbol \\"assert\\" already defined in this scope + + +error: Symbol \\"unsafeCast\\" already defined in this scope + --> ../../../examples/tests/invalid/global_symbols.test.w:5:5 + | +5 | let unsafeCast = \\"wingnuts\\"; + | ^^^^^^^^^^ Symbol \\"unsafeCast\\" already defined in this scope + + +error: Symbol \\"nodeof\\" already defined in this scope + --> ../../../examples/tests/invalid/global_symbols.test.w:7:5 + | +7 | let nodeof = \\"!\\"; + | ^^^^^^ Symbol \\"nodeof\\" already defined in this scope + + +error: Variable is not reassignable + --> ../../../examples/tests/invalid/global_symbols.test.w:10:1 + | +10 | log = \\"hi\\"; + | ^^^ Variable is not reassignable + + +error: Expected type to be \\"(message: str): void\\", but got \\"str\\" instead + --> ../../../examples/tests/invalid/global_symbols.test.w:10:7 + | +10 | log = \\"hi\\"; + | ^^^^ Expected type to be \\"(message: str): void\\", but got \\"str\\" instead + + +error: Variable is not reassignable + --> ../../../examples/tests/invalid/global_symbols.test.w:12:1 + | +12 | assert = \\"there\\"; + | ^^^^^^ Variable is not reassignable + + +error: Expected type to be \\"(condition: bool): void\\", but got \\"str\\" instead + --> ../../../examples/tests/invalid/global_symbols.test.w:12:10 + | +12 | assert = \\"there\\"; + | ^^^^^^^ Expected type to be \\"(condition: bool): void\\", but got \\"str\\" instead + + +error: Variable is not reassignable + --> ../../../examples/tests/invalid/global_symbols.test.w:14:1 + | +14 | unsafeCast = \\"wingnuts\\"; + | ^^^^^^^^^^ Variable is not reassignable + + +error: Expected type to be \\"(value: any): any\\", but got \\"str\\" instead + --> ../../../examples/tests/invalid/global_symbols.test.w:14:14 + | +14 | unsafeCast = \\"wingnuts\\"; + | ^^^^^^^^^^ Expected type to be \\"(value: any): any\\", but got \\"str\\" instead + + +error: Variable is not reassignable + --> ../../../examples/tests/invalid/global_symbols.test.w:16:1 + | +16 | nodeof = \\"!\\"; + | ^^^^^^ Variable is not reassignable + + +error: Expected type to be \\"preflight (construct: IConstruct): Node\\", but got \\"str\\" instead + --> ../../../examples/tests/invalid/global_symbols.test.w:16:10 + | +16 | nodeof = \\"!\\"; + | ^^^ Expected type to be \\"preflight (construct: IConstruct): Node\\", but got \\"str\\" instead + + + + Tests 1 failed (1) Test Files 1 failed (1) Duration " diff --git a/tools/hangar/__snapshots__/test_corpus/valid/api.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/api.test.w_compile_tf-aws.md index 3666d09ad1a..21621b97ce7 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/api.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/api.test.w_compile_tf-aws.md @@ -474,7 +474,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -509,7 +509,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -548,7 +548,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/api_cors_custom.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/api_cors_custom.test.w_compile_tf-aws.md index c928241e37b..468e416f551 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/api_cors_custom.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/api_cors_custom.test.w_compile_tf-aws.md @@ -333,7 +333,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -360,7 +360,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -396,7 +396,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -433,7 +433,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/api_cors_default.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/api_cors_default.test.w_compile_tf-aws.md index 8f37a154f39..ace583bcc76 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/api_cors_default.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/api_cors_default.test.w_compile_tf-aws.md @@ -308,7 +308,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -335,7 +335,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -371,7 +371,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/api_valid_path.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/api_valid_path.test.w_compile_tf-aws.md index 8315c844f9c..f2164cab0c1 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/api_valid_path.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/api_valid_path.test.w_compile_tf-aws.md @@ -407,7 +407,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/assert.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/assert.test.w_compile_tf-aws.md index e88850badb0..169773c358b 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/assert.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/assert.test.w_compile_tf-aws.md @@ -20,11 +20,11 @@ module.exports = function({ $s1, $s2 }) { $helpers.assert($helpers.eq("`s1`", "`s1`"), "\"`s1`\" == \"`s1`\""); $helpers.assert($helpers.eq($s1, $s1), "s1 == s1"); $helpers.assert($helpers.eq(String.raw({ raw: ["", ""] }, $s1), String.raw({ raw: ["", ""] }, $s1)), "\"{s1}\" == \"{s1}\""); - $helpers.assert(!$helpers.eq(String.raw({ raw: ["", ""] }, $s1), String.raw({ raw: ["", ""] }, $s2)), "\"{s1}\" != \"{s2}\""); + $helpers.assert($helpers.neq(String.raw({ raw: ["", ""] }, $s1), String.raw({ raw: ["", ""] }, $s2)), "\"{s1}\" != \"{s2}\""); $helpers.assert($helpers.eq(String.raw({ raw: ["a", ""] }, $s1), String.raw({ raw: ["a", ""] }, $s1)), "\"a{s1}\" == \"a{s1}\""); - $helpers.assert(!$helpers.eq(String.raw({ raw: ["a", ""] }, $s1), String.raw({ raw: ["b", ""] }, $s1)), "\"a{s1}\" != \"b{s1}\""); + $helpers.assert($helpers.neq(String.raw({ raw: ["a", ""] }, $s1), String.raw({ raw: ["b", ""] }, $s1)), "\"a{s1}\" != \"b{s1}\""); $helpers.assert($helpers.eq(String.raw({ raw: ["", "a"] }, $s1), String.raw({ raw: ["", "a"] }, $s1)), "\"{s1}a\" == \"{s1}a\""); - $helpers.assert(!$helpers.eq(String.raw({ raw: ["", "a"] }, $s1), String.raw({ raw: ["", "b"] }, $s1)), "\"{s1}a\" != \"{s1}b\""); + $helpers.assert($helpers.neq(String.raw({ raw: ["", "a"] }, $s1), String.raw({ raw: ["", "b"] }, $s1)), "\"{s1}a\" != \"{s1}b\""); $helpers.assert($helpers.eq(String.raw({ raw: ["`'", ""] }, $s1), String.raw({ raw: ["`'", ""] }, $s1)), "\"`\'{s1}\" == \"`\'{s1}\""); $helpers.assert($helpers.eq(String.raw({ raw: ["a", "b", "c"] }, $s1, $s2), String.raw({ raw: ["a", "b", "c"] }, $s1, $s2)), "\"a{s1}b{s2}c\" == \"a{s1}b{s2}c\""); } @@ -69,7 +69,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -111,11 +111,11 @@ class $Root extends $stdlib.std.Resource { $helpers.assert($helpers.eq("`s1`", "`s1`"), "\"`s1`\" == \"`s1`\""); $helpers.assert($helpers.eq(s1, s1), "s1 == s1"); $helpers.assert($helpers.eq(String.raw({ raw: ["", ""] }, s1), String.raw({ raw: ["", ""] }, s1)), "\"{s1}\" == \"{s1}\""); - $helpers.assert(!$helpers.eq(String.raw({ raw: ["", ""] }, s1), String.raw({ raw: ["", ""] }, s2)), "\"{s1}\" != \"{s2}\""); + $helpers.assert($helpers.neq(String.raw({ raw: ["", ""] }, s1), String.raw({ raw: ["", ""] }, s2)), "\"{s1}\" != \"{s2}\""); $helpers.assert($helpers.eq(String.raw({ raw: ["a", ""] }, s1), String.raw({ raw: ["a", ""] }, s1)), "\"a{s1}\" == \"a{s1}\""); - $helpers.assert(!$helpers.eq(String.raw({ raw: ["a", ""] }, s1), String.raw({ raw: ["b", ""] }, s1)), "\"a{s1}\" != \"b{s1}\""); + $helpers.assert($helpers.neq(String.raw({ raw: ["a", ""] }, s1), String.raw({ raw: ["b", ""] }, s1)), "\"a{s1}\" != \"b{s1}\""); $helpers.assert($helpers.eq(String.raw({ raw: ["", "a"] }, s1), String.raw({ raw: ["", "a"] }, s1)), "\"{s1}a\" == \"{s1}a\""); - $helpers.assert(!$helpers.eq(String.raw({ raw: ["", "a"] }, s1), String.raw({ raw: ["", "b"] }, s1)), "\"{s1}a\" != \"{s1}b\""); + $helpers.assert($helpers.neq(String.raw({ raw: ["", "a"] }, s1), String.raw({ raw: ["", "b"] }, s1)), "\"{s1}a\" != \"{s1}b\""); $helpers.assert($helpers.eq(String.raw({ raw: ["`'", ""] }, s1), String.raw({ raw: ["`'", ""] }, s1)), "\"`\'{s1}\" == \"`\'{s1}\""); $helpers.assert($helpers.eq(String.raw({ raw: ["a", "b", "c"] }, s1, s2), String.raw({ raw: ["a", "b", "c"] }, s1, s2)), "\"a{s1}b{s2}c\" == \"a{s1}b{s2}c\""); this.node.root.new("@winglang/sdk.std.Test", std.Test, this, "test:assert works inflight", new $Closure1(this, "$Closure1")); diff --git a/tools/hangar/__snapshots__/test_corpus/valid/asynchronous_model_implicit_await_in_functions.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/asynchronous_model_implicit_await_in_functions.test.w_compile_tf-aws.md index 41715b58011..89e75199a88 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/asynchronous_model_implicit_await_in_functions.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/asynchronous_model_implicit_await_in_functions.test.w_compile_tf-aws.md @@ -277,7 +277,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -304,7 +304,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/bring_jsii.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/bring_jsii.test.w_compile_tf-aws.md index c499b47afa6..894e94c14cd 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/bring_jsii.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/bring_jsii.test.w_compile_tf-aws.md @@ -59,7 +59,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/bring_local.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/bring_local.test.w_compile_tf-aws.md index 8ebcfa135cc..89392dc3815 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/bring_local.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/bring_local.test.w_compile_tf-aws.md @@ -298,7 +298,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -386,7 +386,7 @@ class $Root extends $stdlib.std.Resource { this.node.root.new("@winglang/sdk.std.Test", std.Test, this, "test:add data to store", new $Closure1(this, "$Closure1")); const s = ({"x": 1, "y": 2}); const c = file1.Color.BLUE; - $helpers.assert(!$helpers.eq(c, file1.Color.RED), "c != file1.Color.RED"); + $helpers.assert($helpers.neq(c, file1.Color.RED), "c != file1.Color.RED"); const t = new Triangle(this, "Triangle"); } } @@ -439,7 +439,7 @@ class Store extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/bring_projen.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/bring_projen.test.w_compile_tf-aws.md index 3e01a0c1c15..43ac8124853 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/bring_projen.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/bring_projen.test.w_compile_tf-aws.md @@ -32,7 +32,7 @@ const projen = require("projen"); class $Root extends $stdlib.std.Resource { constructor($scope, $id) { super($scope, $id); - $helpers.assert(!$helpers.eq(projen.LogLevel.OFF, projen.LogLevel.VERBOSE), "projen.LogLevel.OFF != projen.LogLevel.VERBOSE"); + $helpers.assert($helpers.neq(projen.LogLevel.OFF, projen.LogLevel.VERBOSE), "projen.LogLevel.OFF != projen.LogLevel.VERBOSE"); } } const $PlatformManager = new $stdlib.platform.PlatformManager({platformPaths: $platforms}); diff --git a/tools/hangar/__snapshots__/test_corpus/valid/bring_wing_library.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/bring_wing_library.test.w_compile_tf-aws.md index f0e52d91eb3..652b908c619 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/bring_wing_library.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/bring_wing_library.test.w_compile_tf-aws.md @@ -127,7 +127,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/bucket_keys.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/bucket_keys.test.w_compile_tf-aws.md index 84efac41726..9b01b7a2a42 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/bucket_keys.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/bucket_keys.test.w_compile_tf-aws.md @@ -80,7 +80,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/call_static_of_myself.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/call_static_of_myself.test.w_compile_tf-aws.md index 66699ec82d6..e267019842f 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/call_static_of_myself.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/call_static_of_myself.test.w_compile_tf-aws.md @@ -168,7 +168,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/calling_inflight_variants.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/calling_inflight_variants.test.w_compile_tf-aws.md index 0b6f072f496..4bae54db90e 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/calling_inflight_variants.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/calling_inflight_variants.test.w_compile_tf-aws.md @@ -121,7 +121,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -190,7 +190,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/capture_containers.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/capture_containers.test.w_compile_tf-aws.md index 6a9fe03232f..571ce5f99b2 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/capture_containers.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/capture_containers.test.w_compile_tf-aws.md @@ -64,7 +64,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/capture_in_binary.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/capture_in_binary.test.w_compile_tf-aws.md index 9d4e169bff6..e57c125a0ee 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/capture_in_binary.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/capture_in_binary.test.w_compile_tf-aws.md @@ -72,7 +72,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/capture_mutables.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/capture_mutables.test.w_compile_tf-aws.md index dbdaed61068..8d25c146e2b 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/capture_mutables.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/capture_mutables.test.w_compile_tf-aws.md @@ -78,7 +78,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -118,7 +118,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/capture_primitives.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/capture_primitives.test.w_compile_tf-aws.md index b5ad5f7d921..25a23a7ebbb 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/capture_primitives.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/capture_primitives.test.w_compile_tf-aws.md @@ -176,7 +176,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/capture_reassigable_class_field.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/capture_reassigable_class_field.test.w_compile_tf-aws.md index 488007625f2..4f17befc100 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/capture_reassigable_class_field.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/capture_reassigable_class_field.test.w_compile_tf-aws.md @@ -167,7 +167,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -236,7 +236,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -270,7 +270,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/capture_reassignable.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/capture_reassignable.test.w_compile_tf-aws.md index 87b2365388a..9e3637eaaa7 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/capture_reassignable.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/capture_reassignable.test.w_compile_tf-aws.md @@ -76,7 +76,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -110,7 +110,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/capture_resource_and_data.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/capture_resource_and_data.test.w_compile_tf-aws.md index 5562802df9b..cc1dcec451e 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/capture_resource_and_data.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/capture_resource_and_data.test.w_compile_tf-aws.md @@ -86,7 +86,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/capture_resource_with_no_inflight.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/capture_resource_with_no_inflight.test.w_compile_tf-aws.md index 94eefd171d9..052f4ea40b0 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/capture_resource_with_no_inflight.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/capture_resource_with_no_inflight.test.w_compile_tf-aws.md @@ -135,7 +135,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/capture_tokens.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/capture_tokens.test.w_compile_tf-aws.md index ac132078af7..89b564ec3c2 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/capture_tokens.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/capture_tokens.test.w_compile_tf-aws.md @@ -266,7 +266,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -300,7 +300,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/captures.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/captures.test.w_compile_tf-aws.md index 36aade70155..e60a67fdcfc 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/captures.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/captures.test.w_compile_tf-aws.md @@ -643,7 +643,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -681,7 +681,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -715,7 +715,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/class.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/class.test.w_compile_tf-aws.md index ba2a606b9f7..0d928cd0120 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/class.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/class.test.w_compile_tf-aws.md @@ -502,7 +502,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -616,7 +616,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -681,7 +681,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -772,7 +772,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/closure_class.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/closure_class.test.w_compile_tf-aws.md index a78ae5ff438..21dbc79a5e7 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/closure_class.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/closure_class.test.w_compile_tf-aws.md @@ -105,7 +105,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/construct-base.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/construct-base.test.w_compile_tf-aws.md index f185690f7e4..259c856e5b2 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/construct-base.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/construct-base.test.w_compile_tf-aws.md @@ -90,7 +90,7 @@ class $Root extends $stdlib.std.Resource { return c.node.path; }); const getDisplayName = ((r) => { - return (std.Node.of(r)).title; + return $helpers.nodeof(r).title; }); const q = this.node.root.new("@cdktf/provider-aws.sqsQueue.SqsQueue", aws.sqsQueue.SqsQueue, this, "aws.sqsQueue.SqsQueue"); const wr = new WingResource(this, "WingResource"); diff --git a/tools/hangar/__snapshots__/test_corpus/valid/debug_env.test.w_test_sim.md b/tools/hangar/__snapshots__/test_corpus/valid/debug_env.test.w_test_sim.md index dfc5e12e7bf..33823613a5d 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/debug_env.test.w_test_sim.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/debug_env.test.w_test_sim.md @@ -4,7 +4,7 @@ ```log [symbol environment at debug_env.test.w:7:5] level 0: { this => A } -level 1: { A => A [type], assert => (condition: bool): void, cloud => cloud [namespace], log => (message: str): void, std => std [namespace], unsafeCast => (value: any): any } +level 1: { A => A [type], assert => (condition: bool): void, cloud => cloud [namespace], log => (message: str): void, nodeof => preflight (construct: IConstruct): Node, std => std [namespace], unsafeCast => (value: any): any } ``` ## stdout.log diff --git a/tools/hangar/__snapshots__/test_corpus/valid/deep_equality.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/deep_equality.test.w_compile_tf-aws.md index dc11423eda5..93578c681a8 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/deep_equality.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/deep_equality.test.w_compile_tf-aws.md @@ -35,8 +35,8 @@ module.exports = function({ $arrayA, $arrayB, $arrayC }) { return $obj; } async handle() { - $helpers.assert(!$helpers.eq($arrayA, $arrayC), "arrayA != arrayC"); - $helpers.assert((!!$helpers.eq($arrayA, $arrayB)), "!(arrayA != arrayB)"); + $helpers.assert($helpers.neq($arrayA, $arrayC), "arrayA != arrayC"); + $helpers.assert((!$helpers.neq($arrayA, $arrayB)), "!(arrayA != arrayB)"); } } return $Closure10; @@ -77,8 +77,8 @@ module.exports = function({ $cat1, $cat2, $cat3 }) { return $obj; } async handle() { - $helpers.assert(!$helpers.eq($cat1, $cat3), "cat1 != cat3"); - $helpers.assert((!!$helpers.eq($cat1, $cat2)), "!(cat1 != cat2)"); + $helpers.assert($helpers.neq($cat1, $cat3), "cat1 != cat3"); + $helpers.assert((!$helpers.neq($cat1, $cat2)), "!(cat1 != cat2)"); } } return $Closure12; @@ -98,8 +98,8 @@ module.exports = function({ $numA, $numC, $strA, $strC }) { return $obj; } async handle() { - $helpers.assert(!$helpers.eq($numA, $numC), "numA != numC"); - $helpers.assert(!$helpers.eq($strA, $strC), "strA != strC"); + $helpers.assert($helpers.neq($numA, $numC), "numA != numC"); + $helpers.assert($helpers.neq($strA, $strC), "strA != strC"); } } return $Closure2; @@ -140,8 +140,8 @@ module.exports = function({ $jsonA, $jsonB, $jsonC }) { return $obj; } async handle() { - $helpers.assert(!$helpers.eq($jsonA, $jsonC), "jsonA != jsonC"); - $helpers.assert((!!$helpers.eq($jsonA, $jsonB)), "!(jsonA != jsonB)"); + $helpers.assert($helpers.neq($jsonA, $jsonC), "jsonA != jsonC"); + $helpers.assert((!$helpers.neq($jsonA, $jsonB)), "!(jsonA != jsonB)"); } } return $Closure4; @@ -182,8 +182,8 @@ module.exports = function({ $setA, $setB, $setC }) { return $obj; } async handle() { - $helpers.assert(!$helpers.eq($setA, $setC), "setA != setC"); - $helpers.assert((!!$helpers.eq($setA, $setB)), "!(setA != setB)"); + $helpers.assert($helpers.neq($setA, $setC), "setA != setC"); + $helpers.assert((!$helpers.neq($setA, $setB)), "!(setA != setB)"); } } return $Closure6; @@ -224,8 +224,8 @@ module.exports = function({ $mapA, $mapB, $mapC }) { return $obj; } async handle() { - $helpers.assert(!$helpers.eq($mapA, $mapC), "mapA != mapC"); - $helpers.assert((!!$helpers.eq($mapA, $mapB)), "!(mapA != mapB)"); + $helpers.assert($helpers.neq($mapA, $mapC), "mapA != mapC"); + $helpers.assert((!$helpers.neq($mapA, $mapB)), "!(mapA != mapB)"); } } return $Closure8; @@ -289,7 +289,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -329,7 +329,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -369,7 +369,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -405,7 +405,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -443,7 +443,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -479,7 +479,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -517,7 +517,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -553,7 +553,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -591,7 +591,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -627,7 +627,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -665,7 +665,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -701,7 +701,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/double_reference.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/double_reference.test.w_compile_tf-aws.md index f64b85594e0..7e8f8389491 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/double_reference.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/double_reference.test.w_compile_tf-aws.md @@ -184,7 +184,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/doubler.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/doubler.test.w_compile_tf-aws.md index f0f7f711e91..34461522062 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/doubler.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/doubler.test.w_compile_tf-aws.md @@ -296,7 +296,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -329,7 +329,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -388,7 +388,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -415,7 +415,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/enums.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/enums.test.w_compile_tf-aws.md index 131b2be09fc..94b0d31a490 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/enums.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/enums.test.w_compile_tf-aws.md @@ -56,7 +56,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/expressions_string_interpolation.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/expressions_string_interpolation.test.w_compile_tf-aws.md index cd581e88c90..ad168064356 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/expressions_string_interpolation.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/expressions_string_interpolation.test.w_compile_tf-aws.md @@ -57,7 +57,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -96,8 +96,8 @@ class $Root extends $stdlib.std.Resource { const endingWithCoolStrings = String.raw({ raw: ["cool -> ", " ", ""] }, regularString, number); $helpers.assert($helpers.eq(String.raw({ raw: ["", ""] }, (1 + 1)), "2"), "\"{1+1}\" == \"2\""); $helpers.assert($helpers.eq("{1+1}", "{1+1}"), "\"\\{1+1}\" == \"\\{1+1}\""); - $helpers.assert(!$helpers.eq("{1+1}", "2"), "\"\\{1+1}\" != \"2\""); - $helpers.assert(!$helpers.eq("{1+1}", "{2}"), "\"\\{1+1}\" != \"\\{2}\""); + $helpers.assert($helpers.neq("{1+1}", "2"), "\"\\{1+1}\" != \"2\""); + $helpers.assert($helpers.neq("{1+1}", "{2}"), "\"\\{1+1}\" != \"\\{2}\""); this.node.root.new("@winglang/sdk.std.Test", std.Test, this, "test:str interpolation with lifted expr", new $Closure1(this, "$Closure1")); } } diff --git a/tools/hangar/__snapshots__/test_corpus/valid/extern_implementation.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/extern_implementation.test.w_compile_tf-aws.md index 9cfb9ba14fc..417e04a3caf 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/extern_implementation.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/extern_implementation.test.w_compile_tf-aws.md @@ -142,7 +142,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -176,7 +176,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/file_counter.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/file_counter.test.w_compile_tf-aws.md index 6e82fd067b2..9a00df20e54 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/file_counter.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/file_counter.test.w_compile_tf-aws.md @@ -221,7 +221,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/for_loop.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/for_loop.test.w_compile_tf-aws.md index 0d6861b51aa..a8af17a9e89 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/for_loop.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/for_loop.test.w_compile_tf-aws.md @@ -185,7 +185,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/function_returns_function.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/function_returns_function.test.w_compile_tf-aws.md index ce04bf68776..b9f6de517c6 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/function_returns_function.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/function_returns_function.test.w_compile_tf-aws.md @@ -64,7 +64,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/function_type.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/function_type.test.w_compile_tf-aws.md index bb6e739fe06..8256cc8fa12 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/function_type.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/function_type.test.w_compile_tf-aws.md @@ -110,7 +110,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -137,7 +137,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -164,7 +164,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/hello.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/hello.test.w_compile_tf-aws.md index c1c451121de..69c4a4774d9 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/hello.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/hello.test.w_compile_tf-aws.md @@ -199,7 +199,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/identical_inflights.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/identical_inflights.test.w_compile_tf-aws.md index eb50d120d4a..a34416fa904 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/identical_inflights.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/identical_inflights.test.w_compile_tf-aws.md @@ -73,7 +73,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -100,7 +100,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/impl_interface.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/impl_interface.test.w_compile_tf-aws.md index 1c2a1b37263..7faa5f36bea 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/impl_interface.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/impl_interface.test.w_compile_tf-aws.md @@ -174,7 +174,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -239,7 +239,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inference.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inference.test.w_compile_tf-aws.md index ad3a6c194fc..ecab4660e88 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inference.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inference.test.w_compile_tf-aws.md @@ -251,7 +251,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight-subscribers.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight-subscribers.test.w_compile_tf-aws.md index 3f4e6c77f3c..a79cc385987 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight-subscribers.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight-subscribers.test.w_compile_tf-aws.md @@ -327,7 +327,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -354,7 +354,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_capture_static.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_capture_static.test.w_compile_tf-aws.md index 410ffe217d6..56752362243 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_capture_static.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_capture_static.test.w_compile_tf-aws.md @@ -212,7 +212,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -246,7 +246,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -274,7 +274,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -301,7 +301,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_as_struct_members.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_as_struct_members.test.w_compile_tf-aws.md index 8e0b51c8398..a779b1d04a4 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_as_struct_members.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_as_struct_members.test.w_compile_tf-aws.md @@ -116,7 +116,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -144,7 +144,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_capture_const.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_capture_const.test.w_compile_tf-aws.md index 06fb1df8de9..d72fcdf776d 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_capture_const.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_capture_const.test.w_compile_tf-aws.md @@ -104,7 +104,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_definitions.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_definitions.test.w_compile_tf-aws.md index e65e0a9290e..2cd73b5c5ff 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_definitions.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_definitions.test.w_compile_tf-aws.md @@ -238,7 +238,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -324,7 +324,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -388,7 +388,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_inner_capture_mutable.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_inner_capture_mutable.test.w_compile_tf-aws.md index 1ab04244dee..193cfbfec09 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_inner_capture_mutable.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_inner_capture_mutable.test.w_compile_tf-aws.md @@ -67,7 +67,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_inside_inflight_closure.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_inside_inflight_closure.test.w_compile_tf-aws.md index 2b9f229fe79..a0774213c05 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_inside_inflight_closure.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_inside_inflight_closure.test.w_compile_tf-aws.md @@ -254,7 +254,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -312,7 +312,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -346,7 +346,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_outside_inflight_closure.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_outside_inflight_closure.test.w_compile_tf-aws.md index 8fff1a7ad52..a615ce87a1f 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_outside_inflight_closure.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_outside_inflight_closure.test.w_compile_tf-aws.md @@ -112,7 +112,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_structural_interace_handler.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_structural_interace_handler.test.w_compile_tf-aws.md index a5fbbbdeca1..5a75eec9555 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_structural_interace_handler.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_structural_interace_handler.test.w_compile_tf-aws.md @@ -107,7 +107,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_without_init.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_without_init.test.w_compile_tf-aws.md index 9aa0de8fa1e..01f53918840 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_without_init.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_class_without_init.test.w_compile_tf-aws.md @@ -93,7 +93,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_closure_inside_preflight_closure.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_closure_inside_preflight_closure.test.w_compile_tf-aws.md index 9c54803c0b9..57cd447bfad 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_closure_inside_preflight_closure.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_closure_inside_preflight_closure.test.w_compile_tf-aws.md @@ -73,7 +73,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflight_init.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflight_init.test.w_compile_tf-aws.md index 80fbbc181b8..6b7067e1337 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflight_init.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflight_init.test.w_compile_tf-aws.md @@ -263,7 +263,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -291,7 +291,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -319,7 +319,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -346,7 +346,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inflights_calling_inflights.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inflights_calling_inflights.test.w_compile_tf-aws.md index 09bd05ff970..a9c2340d016 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inflights_calling_inflights.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inflights_calling_inflights.test.w_compile_tf-aws.md @@ -274,7 +274,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -308,7 +308,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -342,7 +342,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -382,7 +382,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -449,7 +449,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inherit_stdlib_class.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inherit_stdlib_class.test.w_compile_tf-aws.md index 3a811b13a4b..8ea65a7b439 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inherit_stdlib_class.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inherit_stdlib_class.test.w_compile_tf-aws.md @@ -314,7 +314,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -341,7 +341,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/inheritance_class_inflight.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/inheritance_class_inflight.test.w_compile_tf-aws.md index a90b80da2d7..4017ee690e3 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/inheritance_class_inflight.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/inheritance_class_inflight.test.w_compile_tf-aws.md @@ -150,7 +150,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/issue_2889.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/issue_2889.test.w_compile_tf-aws.md index 155bf8ec299..ec6d53dd4c2 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/issue_2889.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/issue_2889.test.w_compile_tf-aws.md @@ -276,7 +276,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -304,7 +304,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/json_bucket.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/json_bucket.test.w_compile_tf-aws.md index e5467b51db4..ee3d2fd7d97 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/json_bucket.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/json_bucket.test.w_compile_tf-aws.md @@ -195,7 +195,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -231,7 +231,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/json_static.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/json_static.test.w_compile_tf-aws.md index 542ee0f58bd..98b28609f39 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/json_static.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/json_static.test.w_compile_tf-aws.md @@ -79,7 +79,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -114,7 +114,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/lift_expr_with_this.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/lift_expr_with_this.test.w_compile_tf-aws.md index c371e578ddc..ffd5b8d5eb4 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/lift_expr_with_this.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/lift_expr_with_this.test.w_compile_tf-aws.md @@ -96,7 +96,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/lift_redefinition.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/lift_redefinition.test.w_compile_tf-aws.md index 4adf85a1b54..b713d5ff2e8 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/lift_redefinition.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/lift_redefinition.test.w_compile_tf-aws.md @@ -57,7 +57,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/lift_this.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/lift_this.test.w_compile_tf-aws.md index 7a116c57ee2..1aba1e5883f 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/lift_this.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/lift_this.test.w_compile_tf-aws.md @@ -109,7 +109,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/lift_via_closure.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/lift_via_closure.test.w_compile_tf-aws.md index f76cca45cf7..76b5974c643 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/lift_via_closure.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/lift_via_closure.test.w_compile_tf-aws.md @@ -153,7 +153,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -232,7 +232,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -266,7 +266,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/lift_via_closure_explicit.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/lift_via_closure_explicit.test.w_compile_tf-aws.md index 767bf8afcb2..b0af4f4fc0c 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/lift_via_closure_explicit.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/lift_via_closure_explicit.test.w_compile_tf-aws.md @@ -129,7 +129,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/lift_with_phase_ind.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/lift_with_phase_ind.test.w_compile_tf-aws.md index f90c9cdf43c..656f6b96bd7 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/lift_with_phase_ind.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/lift_with_phase_ind.test.w_compile_tf-aws.md @@ -61,7 +61,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/new_in_static.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/new_in_static.test.w_compile_tf-aws.md index c3229db1e9c..3008aca865b 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/new_in_static.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/new_in_static.test.w_compile_tf-aws.md @@ -136,7 +136,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/nil.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/nil.test.w_compile_tf-aws.md index 3b20087c706..c42c218efe2 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/nil.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/nil.test.w_compile_tf-aws.md @@ -36,7 +36,7 @@ module.exports = function({ $foo }) { $helpers.assert($helpers.eq((((await $foo.getOptionalValue())) != null), false), "foo.getOptionalValue()? == false"); (await $foo.setOptionalValue("hello")); $helpers.assert($helpers.eq((((await $foo.getOptionalValue())) != null), true), "foo.getOptionalValue()? == true"); - $helpers.assert(!$helpers.eq((await $foo.getOptionalValue()), undefined), "foo.getOptionalValue() != nil"); + $helpers.assert($helpers.neq((await $foo.getOptionalValue()), undefined), "foo.getOptionalValue() != nil"); (await $foo.setOptionalValue(undefined)); $helpers.assert($helpers.eq((((await $foo.getOptionalValue())) != null), false), "foo.getOptionalValue()? == false"); $helpers.assert($helpers.eq((await $foo.getOptionalValue()), undefined), "foo.getOptionalValue() == nil"); @@ -137,7 +137,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -171,7 +171,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/optionals.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/optionals.test.w_compile_tf-aws.md index a6999efe1c1..c5755df2e42 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/optionals.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/optionals.test.w_compile_tf-aws.md @@ -239,7 +239,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -375,7 +375,7 @@ class $Root extends $stdlib.std.Resource { if ($if_let_value != undefined) { const parsedName = $if_let_value; $helpers.assert($helpers.eq(parsedName.first, "BadName"), "parsedName.first == \"BadName\""); - if (!$helpers.eq(parsedName.last, "")) { + if ($helpers.neq(parsedName.last, "")) { $helpers.assert(false, "false"); } } diff --git a/tools/hangar/__snapshots__/test_corpus/valid/print.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/print.test.w_compile_tf-aws.md index 7b352f95013..ac6bdeed82d 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/print.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/print.test.w_compile_tf-aws.md @@ -78,7 +78,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -105,7 +105,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/redis.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/redis.test.w_compile_tf-aws.md index f9a2650de08..c62ca65a728 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/redis.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/redis.test.w_compile_tf-aws.md @@ -37,7 +37,7 @@ module.exports = function({ $queue, $r, $r2, $util_Util }) { $helpers.assert($helpers.eq(value2, "does redis again"), "value2 == \"does redis again\""); (await $queue.push("world!")); (await $util_Util.waitUntil(async () => { - return !$helpers.eq((await $r.get("hello")), undefined); + return $helpers.neq((await $r.get("hello")), undefined); })); $helpers.assert($helpers.eq("world!", String.raw({ raw: ["", ""] }, (await $r.get("hello")))), "\"world!\" == \"{r.get(\"hello\")}\""); } @@ -549,7 +549,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -583,7 +583,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/resource.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/resource.test.w_compile_tf-aws.md index 462f2b9af31..d3e3874fb44 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/resource.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/resource.test.w_compile_tf-aws.md @@ -800,7 +800,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -846,7 +846,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -882,7 +882,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -918,7 +918,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -996,7 +996,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/resource_as_inflight_literal.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/resource_as_inflight_literal.test.w_compile_tf-aws.md index 92740f65c81..89d61e02ef2 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/resource_as_inflight_literal.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/resource_as_inflight_literal.test.w_compile_tf-aws.md @@ -208,7 +208,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/resource_call_static.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/resource_call_static.test.w_compile_tf-aws.md index 61ada23add5..2151bcdf5ed 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/resource_call_static.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/resource_call_static.test.w_compile_tf-aws.md @@ -126,7 +126,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/resource_captures.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/resource_captures.test.w_compile_tf-aws.md index ebeaa90b7df..bc136e12ad7 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/resource_captures.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/resource_captures.test.w_compile_tf-aws.md @@ -429,7 +429,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/resource_captures_globals.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/resource_captures_globals.test.w_compile_tf-aws.md index 04dc96bc018..8f666638f01 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/resource_captures_globals.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/resource_captures_globals.test.w_compile_tf-aws.md @@ -531,7 +531,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -565,7 +565,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/shadowing.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/shadowing.test.w_compile_tf-aws.md index f38e7b63abf..82a825ad098 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/shadowing.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/shadowing.test.w_compile_tf-aws.md @@ -88,7 +88,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -122,7 +122,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/statements_if.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/statements_if.test.w_compile_tf-aws.md index 04ffd0e6312..531e3543c3e 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/statements_if.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/statements_if.test.w_compile_tf-aws.md @@ -75,7 +75,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/static_members.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/static_members.test.w_compile_tf-aws.md index 184f1dd6521..2304caa42f0 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/static_members.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/static_members.test.w_compile_tf-aws.md @@ -112,7 +112,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/std_string.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/std_string.test.w_compile_tf-aws.md index 2ed271c4cbb..98fac018471 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/std_string.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/std_string.test.w_compile_tf-aws.md @@ -57,7 +57,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/store.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/store.w_compile_tf-aws.md index 722b6da742c..32bfdda52e7 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/store.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/store.w_compile_tf-aws.md @@ -105,7 +105,7 @@ class Store extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/struct_from_json.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/struct_from_json.test.w_compile_tf-aws.md index 937e0a6c594..5a60f54a274 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/struct_from_json.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/struct_from_json.test.w_compile_tf-aws.md @@ -194,7 +194,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -229,7 +229,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -257,7 +257,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -292,7 +292,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -332,7 +332,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/structs.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/structs.test.w_compile_tf-aws.md index 8732b95de2d..61fd3cccb3f 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/structs.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/structs.test.w_compile_tf-aws.md @@ -110,7 +110,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/super_call.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/super_call.test.w_compile_tf-aws.md index a42cc09c156..2ced411fc0f 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/super_call.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/super_call.test.w_compile_tf-aws.md @@ -422,7 +422,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -516,7 +516,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/symbol_shadow.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/symbol_shadow.test.w_compile_tf-aws.md index b6498147493..2149ca8243e 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/symbol_shadow.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/symbol_shadow.test.w_compile_tf-aws.md @@ -137,7 +137,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -194,7 +194,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -228,7 +228,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -259,7 +259,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/test_bucket.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/test_bucket.test.w_compile_tf-aws.md index be9d637ff24..a0cb4a622d3 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/test_bucket.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/test_bucket.test.w_compile_tf-aws.md @@ -93,7 +93,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -127,7 +127,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/test_without_bring.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/test_without_bring.test.w_compile_tf-aws.md index 4779a16d5fd..0f1860e8bec 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/test_without_bring.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/test_without_bring.test.w_compile_tf-aws.md @@ -55,7 +55,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/use_inflight_method_inside_init_closure.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/use_inflight_method_inside_init_closure.test.w_compile_tf-aws.md index cc15611165a..ec15a0932b8 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/use_inflight_method_inside_init_closure.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/use_inflight_method_inside_init_closure.test.w_compile_tf-aws.md @@ -182,7 +182,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/website_with_api.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/website_with_api.test.w_compile_tf-aws.md index ee943d23c62..151009b3e6c 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/website_with_api.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/website_with_api.test.w_compile_tf-aws.md @@ -626,7 +626,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -661,7 +661,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -696,7 +696,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` @@ -733,7 +733,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return ` diff --git a/tools/hangar/__snapshots__/test_corpus/valid/while_loop_await.test.w_compile_tf-aws.md b/tools/hangar/__snapshots__/test_corpus/valid/while_loop_await.test.w_compile_tf-aws.md index a4c3612ac31..97f8d3cb153 100644 --- a/tools/hangar/__snapshots__/test_corpus/valid/while_loop_await.test.w_compile_tf-aws.md +++ b/tools/hangar/__snapshots__/test_corpus/valid/while_loop_await.test.w_compile_tf-aws.md @@ -194,7 +194,7 @@ class $Root extends $stdlib.std.Resource { _hash = require('crypto').createHash('md5').update(this._toInflight()).digest('hex'); constructor($scope, $id, ) { super($scope, $id); - (std.Node.of(this)).hidden = true; + $helpers.nodeof(this).hidden = true; } static _toInflightType() { return `