~mna/snow unlisted

3218da62e2c9031e1c0744610e00bf8a31b7d19a — Martin Angers 9 months ago 31fec45
pkg/semantic: print number of interfaces in file/struct, adjust expected test results
217 files changed, 360 insertions(+), 306 deletions(-)

M pkg/printer/printer.go
M pkg/semantic/testdata/check/cycle.snow.want
M pkg/semantic/testdata/check/empty.snow.want
M pkg/semantic/testdata/check/fn.snow.want
M pkg/semantic/testdata/check/fn_access_invalid_struct_field.snow.want
M pkg/semantic/testdata/check/fn_access_struct_type_field.snow.want
M pkg/semantic/testdata/check/fn_access_var_outside_struct.snow.want
M pkg/semantic/testdata/check/fn_assign_invalid.snow.want
M pkg/semantic/testdata/check/fn_assign_let.snow.want
M pkg/semantic/testdata/check/fn_assign_struct_fields.snow.want
M pkg/semantic/testdata/check/fn_assign_struct_method_to_var.snow.want
M pkg/semantic/testdata/check/fn_assign_type.snow.want
M pkg/semantic/testdata/check/fn_assign_unifying_type.snow.want
M pkg/semantic/testdata/check/fn_call_fn_value_with_labels.snow.want
M pkg/semantic/testdata/check/fn_call_struct_init.snow.want
M pkg/semantic/testdata/check/fn_call_struct_init_no_label.snow.want
M pkg/semantic/testdata/check/fn_call_struct_init_only_required_no_order.snow.want
M pkg/semantic/testdata/check/fn_call_struct_method.snow.want
M pkg/semantic/testdata/check/fn_call_unifying_type.snow.want
M pkg/semantic/testdata/check/fn_call_with_invalid_labels.snow.want
M pkg/semantic/testdata/check/fn_call_with_labels.snow.want
M pkg/semantic/testdata/check/fn_call_wrong_arity.snow.want
M pkg/semantic/testdata/check/fn_compare.snow.want
M pkg/semantic/testdata/check/fn_complex_selectors.snow.want
M pkg/semantic/testdata/check/fn_duplicate_param_name.snow.want
M pkg/semantic/testdata/check/fn_explicit_void.snow.want
M pkg/semantic/testdata/check/fn_extern_pkg_before_conflict_name.snow.want
M pkg/semantic/testdata/check/fn_extern_pkg_conflict_name.snow.want
M pkg/semantic/testdata/check/fn_extern_ref_method.snow.want
M pkg/semantic/testdata/check/fn_extern_with_body.snow.want
M pkg/semantic/testdata/check/fn_fn_arg.snow.want
M pkg/semantic/testdata/check/fn_generic_decl_after_inst.snow.want
M pkg/semantic/testdata/check/fn_generic_fn_uses_generic_fn.snow.want
M pkg/semantic/testdata/check/fn_generic_identity.snow.want
M pkg/semantic/testdata/check/fn_generic_unused_in_signature.snow.want
M pkg/semantic/testdata/check/fn_guard_fallthrough.snow.want
M pkg/semantic/testdata/check/fn_ident_as_type.snow.want
M pkg/semantic/testdata/check/fn_init_order.snow.want
M pkg/semantic/testdata/check/fn_invalid_attr.snow.want
M pkg/semantic/testdata/check/fn_invalid_extern_fields.snow.want
M pkg/semantic/testdata/check/fn_invalid_generic_use_in_fn.snow.want
M pkg/semantic/testdata/check/fn_invalid_main.snow.want
M pkg/semantic/testdata/check/fn_invalid_ref.snow.want
M pkg/semantic/testdata/check/fn_invalid_ref_call.snow.want
M pkg/semantic/testdata/check/fn_invalid_ref_call_via_value.snow.want
M pkg/semantic/testdata/check/fn_invalid_return.snow.want
M pkg/semantic/testdata/check/fn_invalid_tuple_access.snow.want
M pkg/semantic/testdata/check/fn_main_extern.snow.want
M pkg/semantic/testdata/check/fn_many_extern.snow.want
M pkg/semantic/testdata/check/fn_method_explicit_self.snow.want
M pkg/semantic/testdata/check/fn_multi_vars_per_decl.snow.want
M pkg/semantic/testdata/check/fn_nested_block.snow.want
M pkg/semantic/testdata/check/fn_nested_fn.snow.want
M pkg/semantic/testdata/check/fn_nested_fn_init_order.snow.want
M pkg/semantic/testdata/check/fn_nested_generic_fn.snow.want
M pkg/semantic/testdata/check/fn_nested_struct_method.snow.want
M pkg/semantic/testdata/check/fn_nested_struct_self.snow.want
M pkg/semantic/testdata/check/fn_nested_structs.snow.want
M pkg/semantic/testdata/check/fn_nested_tuple_type.snow.want
M pkg/semantic/testdata/check/fn_non_type_selectors.snow.want
M pkg/semantic/testdata/check/fn_param_type_is_var_in_body.snow.want
M pkg/semantic/testdata/check/fn_params.snow.want
M pkg/semantic/testdata/check/fn_params_locals.snow.want
M pkg/semantic/testdata/check/fn_recursion.snow.want
M pkg/semantic/testdata/check/fn_ref_on_fn_nested_in_method.snow.want
M pkg/semantic/testdata/check/fn_return_internal_struct.snow.want
M pkg/semantic/testdata/check/fn_return_missing_value.snow.want
M pkg/semantic/testdata/check/fn_return_struct.snow.want
M pkg/semantic/testdata/check/fn_return_unifying_type.snow.want
M pkg/semantic/testdata/check/fn_struct_main_method.snow.want
M pkg/semantic/testdata/check/fn_struct_method_access_top_level.snow.want
M pkg/semantic/testdata/check/fn_struct_order_independent.snow.want
M pkg/semantic/testdata/check/fn_struct_same_name_diff_scope.snow.want
M pkg/semantic/testdata/check/fn_struct_selector.snow.want
M pkg/semantic/testdata/check/fn_struct_self_shadow.snow.want
M pkg/semantic/testdata/check/fn_struct_self_uses.snow.want
M pkg/semantic/testdata/check/fn_tuple_assign_compatible_types.snow.want
M pkg/semantic/testdata/check/fn_tuple_assign_incompatible_types.snow.want
M pkg/semantic/testdata/check/fn_tuple_expr_select_field.snow.want
M pkg/semantic/testdata/check/fn_type_as_value.snow.want
M pkg/semantic/testdata/check/fn_unknown_symbol.snow.want
M pkg/semantic/testdata/check/fn_var_as_param_type.snow.want
M pkg/semantic/testdata/check/fn_without_body.snow.want
M pkg/semantic/testdata/check/fns.snow.want
M pkg/semantic/testdata/check/generic_struct_instantiation.snow.want
M pkg/semantic/testdata/check/guard_else.snow.want
M pkg/semantic/testdata/check/if_else_if.snow.want
M pkg/semantic/testdata/check/if_non_bool.snow.want
M pkg/semantic/testdata/check/invalid_binary_op.snow.want
M pkg/semantic/testdata/check/let.snow.want
M pkg/semantic/testdata/check/let_invalid_tuple_type.snow.want
M pkg/semantic/testdata/check/let_invalid_unary.snow.want
M pkg/semantic/testdata/check/let_unary.snow.want
M pkg/semantic/testdata/check/paren_type.snow.want
M pkg/semantic/testdata/check/struct_complex_generic.snow.want
M pkg/semantic/testdata/check/struct_generic.snow.want
M pkg/semantic/testdata/check/struct_simple_generic.snow.want
M pkg/semantic/testdata/check/struct_var_expr_call_method.snow.want
M pkg/semantic/testdata/check/top_level_fn_init_order.snow.want
M pkg/semantic/testdata/check/top_level_init_order.snow.want
M pkg/semantic/testdata/check/tuple_as_struct_generic.snow.want
M pkg/semantic/testdata/check/var.snow.want
M pkg/semantic/testdata/check/var_auto_ref.snow.want
M pkg/semantic/testdata/check/var_bool.snow.want
M pkg/semantic/testdata/check/var_duplicate_symbol.snow.want
M pkg/semantic/testdata/check/var_tuple_type.snow.want
A pkg/semantic/testdata/generic_interface.snow.notyet
A pkg/semantic/testdata/scopes/generic_interface.snow.err
A pkg/semantic/testdata/scopes/generic_interface.snow.want
M pkg/semantic/testdata/types/cycle.snow.want
M pkg/semantic/testdata/types/empty.snow.want
M pkg/semantic/testdata/types/fn.snow.want
M pkg/semantic/testdata/types/fn_access_invalid_struct_field.snow.want
M pkg/semantic/testdata/types/fn_access_struct_type_field.snow.want
M pkg/semantic/testdata/types/fn_access_var_outside_struct.snow.want
M pkg/semantic/testdata/types/fn_assign_invalid.snow.want
M pkg/semantic/testdata/types/fn_assign_let.snow.want
M pkg/semantic/testdata/types/fn_assign_struct_fields.snow.want
M pkg/semantic/testdata/types/fn_assign_struct_method_to_var.snow.want
M pkg/semantic/testdata/types/fn_assign_type.snow.want
M pkg/semantic/testdata/types/fn_assign_unifying_type.snow.want
M pkg/semantic/testdata/types/fn_call_fn_value_with_labels.snow.want
M pkg/semantic/testdata/types/fn_call_struct_init.snow.want
M pkg/semantic/testdata/types/fn_call_struct_init_no_label.snow.want
M pkg/semantic/testdata/types/fn_call_struct_init_only_required_no_order.snow.want
M pkg/semantic/testdata/types/fn_call_struct_method.snow.want
M pkg/semantic/testdata/types/fn_call_unifying_type.snow.want
M pkg/semantic/testdata/types/fn_call_with_invalid_labels.snow.want
M pkg/semantic/testdata/types/fn_call_with_labels.snow.want
M pkg/semantic/testdata/types/fn_call_wrong_arity.snow.want
M pkg/semantic/testdata/types/fn_compare.snow.want
M pkg/semantic/testdata/types/fn_complex_selectors.snow.want
M pkg/semantic/testdata/types/fn_duplicate_param_name.snow.want
M pkg/semantic/testdata/types/fn_explicit_void.snow.want
M pkg/semantic/testdata/types/fn_extern_pkg_before_conflict_name.snow.want
M pkg/semantic/testdata/types/fn_extern_pkg_conflict_name.snow.want
M pkg/semantic/testdata/types/fn_extern_ref_method.snow.want
M pkg/semantic/testdata/types/fn_extern_with_body.snow.want
M pkg/semantic/testdata/types/fn_fn_arg.snow.want
M pkg/semantic/testdata/types/fn_generic_decl_after_inst.snow.want
M pkg/semantic/testdata/types/fn_generic_fn_uses_generic_fn.snow.want
M pkg/semantic/testdata/types/fn_generic_identity.snow.want
M pkg/semantic/testdata/types/fn_generic_unused_in_signature.snow.want
M pkg/semantic/testdata/types/fn_guard_fallthrough.snow.want
M pkg/semantic/testdata/types/fn_ident_as_type.snow.want
M pkg/semantic/testdata/types/fn_init_order.snow.want
M pkg/semantic/testdata/types/fn_invalid_attr.snow.want
M pkg/semantic/testdata/types/fn_invalid_extern_fields.snow.want
M pkg/semantic/testdata/types/fn_invalid_generic_use_in_fn.snow.want
M pkg/semantic/testdata/types/fn_invalid_main.snow.want
M pkg/semantic/testdata/types/fn_invalid_ref.snow.want
M pkg/semantic/testdata/types/fn_invalid_ref_call.snow.want
M pkg/semantic/testdata/types/fn_invalid_ref_call_via_value.snow.want
M pkg/semantic/testdata/types/fn_invalid_return.snow.want
M pkg/semantic/testdata/types/fn_invalid_tuple_access.snow.want
M pkg/semantic/testdata/types/fn_main_extern.snow.want
M pkg/semantic/testdata/types/fn_many_extern.snow.want
M pkg/semantic/testdata/types/fn_method_explicit_self.snow.want
M pkg/semantic/testdata/types/fn_multi_vars_per_decl.snow.want
M pkg/semantic/testdata/types/fn_nested_block.snow.want
M pkg/semantic/testdata/types/fn_nested_fn.snow.want
M pkg/semantic/testdata/types/fn_nested_fn_init_order.snow.want
M pkg/semantic/testdata/types/fn_nested_generic_fn.snow.want
M pkg/semantic/testdata/types/fn_nested_struct_method.snow.want
M pkg/semantic/testdata/types/fn_nested_struct_self.snow.want
M pkg/semantic/testdata/types/fn_nested_structs.snow.want
M pkg/semantic/testdata/types/fn_nested_tuple_type.snow.want
M pkg/semantic/testdata/types/fn_non_type_selectors.snow.want
M pkg/semantic/testdata/types/fn_param_type_is_var_in_body.snow.want
M pkg/semantic/testdata/types/fn_params.snow.want
M pkg/semantic/testdata/types/fn_params_locals.snow.want
M pkg/semantic/testdata/types/fn_recursion.snow.want
M pkg/semantic/testdata/types/fn_ref_on_fn_nested_in_method.snow.want
M pkg/semantic/testdata/types/fn_return_internal_struct.snow.want
M pkg/semantic/testdata/types/fn_return_missing_value.snow.want
M pkg/semantic/testdata/types/fn_return_struct.snow.want
M pkg/semantic/testdata/types/fn_return_unifying_type.snow.want
M pkg/semantic/testdata/types/fn_struct_main_method.snow.want
M pkg/semantic/testdata/types/fn_struct_method_access_top_level.snow.want
M pkg/semantic/testdata/types/fn_struct_order_independent.snow.want
M pkg/semantic/testdata/types/fn_struct_same_name_diff_scope.snow.want
M pkg/semantic/testdata/types/fn_struct_selector.snow.want
M pkg/semantic/testdata/types/fn_struct_self_shadow.snow.want
M pkg/semantic/testdata/types/fn_struct_self_uses.snow.want
M pkg/semantic/testdata/types/fn_tuple_assign_compatible_types.snow.want
M pkg/semantic/testdata/types/fn_tuple_assign_incompatible_types.snow.want
M pkg/semantic/testdata/types/fn_tuple_expr_select_field.snow.want
M pkg/semantic/testdata/types/fn_type_as_value.snow.want
M pkg/semantic/testdata/types/fn_unknown_symbol.snow.want
M pkg/semantic/testdata/types/fn_var_as_param_type.snow.want
M pkg/semantic/testdata/types/fn_without_body.snow.want
M pkg/semantic/testdata/types/fns.snow.want
A pkg/semantic/testdata/types/generic_interface.snow.err
A pkg/semantic/testdata/types/generic_interface.snow.want
M pkg/semantic/testdata/types/generic_struct_instantiation.snow.want
M pkg/semantic/testdata/types/guard_else.snow.want
M pkg/semantic/testdata/types/if_else_if.snow.want
M pkg/semantic/testdata/types/if_non_bool.snow.want
M pkg/semantic/testdata/types/interface.snow.want
M pkg/semantic/testdata/types/invalid_binary_op.snow.want
M pkg/semantic/testdata/types/let.snow.want
M pkg/semantic/testdata/types/let_invalid_tuple_type.snow.want
M pkg/semantic/testdata/types/let_invalid_unary.snow.want
M pkg/semantic/testdata/types/let_unary.snow.want
M pkg/semantic/testdata/types/paren_type.snow.want
M pkg/semantic/testdata/types/struct_complex_generic.snow.want
M pkg/semantic/testdata/types/struct_generic.snow.want
M pkg/semantic/testdata/types/struct_simple_generic.snow.want
M pkg/semantic/testdata/types/struct_var_expr_call_method.snow.want
M pkg/semantic/testdata/types/top_level_fn_init_order.snow.want
M pkg/semantic/testdata/types/top_level_init_order.snow.want
M pkg/semantic/testdata/types/tuple_as_struct_generic.snow.want
M pkg/semantic/testdata/types/var.snow.want
M pkg/semantic/testdata/types/var_auto_ref.snow.want
M pkg/semantic/testdata/types/var_bool.snow.want
M pkg/semantic/testdata/types/var_duplicate_symbol.snow.want
M pkg/semantic/testdata/types/var_tuple_type.snow.want
M pkg/printer/printer.go => pkg/printer/printer.go +4 -3
@@ 155,7 155,8 @@ func (p *semanticPrinter) Visit(n semantic.Node) semantic.Visitor {

	switch n := n.(type) {
	case *semantic.File:
		p.printMsg(fmt.Sprintf("file %s [%d, %d, %d]", p.file.Name(), len(n.Vars), len(n.Fns), len(n.Structs)), true)
		p.printMsg(fmt.Sprintf("file %s [%d, %d, %d, %d]",
			p.file.Name(), len(n.Vars), len(n.Fns), len(n.Structs), len(n.Interfaces)), true)
	case *semantic.Fn:
		format := "fn %s"
		args := []interface{}{n.Ident()}


@@ 177,8 178,8 @@ func (p *semanticPrinter) Visit(n semantic.Node) semantic.Visitor {
		}
		p.printMsg(fmt.Sprintf("%s %s", lbl, n.Ident()), true)
	case *semantic.Struct:
		format := "struct %s [%d, %d, %d"
		args := []interface{}{n.Ident(), len(n.Vars), len(n.Fns), len(n.Structs)}
		format := "struct %s [%d, %d, %d, %d"
		args := []interface{}{n.Ident(), len(n.Vars), len(n.Fns), len(n.Structs), len(n.Interfaces)}
		if n.GenericParams != nil {
			format += ", $%d"
			args = append(args, len(n.GenericParams.Elems))

M pkg/semantic/testdata/check/cycle.snow.want => pkg/semantic/testdata/check/cycle.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/cycle.snow [3, 0, 0]
file testdata/cycle.snow [3, 0, 0, 0]
  var= A [var: unresolved]
    ident B [var: unresolved]
  var= B [var: unresolved]

M pkg/semantic/testdata/check/empty.snow.want => pkg/semantic/testdata/check/empty.snow.want +1 -1
@@ 1,1 1,1 @@
file testdata/empty.snow [0, 0, 0]
file testdata/empty.snow [0, 0, 0, 0]

M pkg/semantic/testdata/check/fn.snow.want => pkg/semantic/testdata/check/fn.snow.want +1 -1
@@ 1,3 1,3 @@
file testdata/fn.snow [0, 1, 0]
file testdata/fn.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [0]

M pkg/semantic/testdata/check/fn_access_invalid_struct_field.snow.want => pkg/semantic/testdata/check/fn_access_invalid_struct_field.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_access_invalid_struct_field.snow [0, 1, 1]
file testdata/fn_access_invalid_struct_field.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [4]
      var: s [var: struct S]


@@ 16,6 16,6 @@ file testdata/fn_access_invalid_struct_field.snow [0, 1, 1]
        select [invalid: unresolved]
          ident s [var: struct S]
          ident z [invalid: unresolved]
  struct S [1, 0, 0] [type: struct S]
  struct S [1, 0, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_access_struct_type_field.snow.want => pkg/semantic/testdata/check/fn_access_struct_type_field.snow.want +2 -2
@@ 1,10 1,10 @@
file testdata/fn_access_struct_type_field.snow [0, 1, 1]
file testdata/fn_access_struct_type_field.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [1]
      var= y [var: int]
        select [invalid: int]
          ident Point [type: struct Point]
          ident x [var: int]
  struct Point [1, 0, 0] [type: struct Point]
  struct Point [1, 0, 0, 0] [type: struct Point]
    var: x [var: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_access_var_outside_struct.snow.want => pkg/semantic/testdata/check/fn_access_var_outside_struct.snow.want +3 -3
@@ 1,9 1,9 @@
file testdata/fn_access_var_outside_struct.snow [0, 1, 0]
file testdata/fn_access_var_outside_struct.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [2]
      var: x [var: int]
        ident int [type: int]
      struct S [1, 1, 1] [type: struct S]
      struct S [1, 1, 1, 0] [type: struct S]
        var: y [var: string]
          ident string [type: string]
        fn get [let: () -> int]


@@ 11,7 11,7 @@ file testdata/fn_access_var_outside_struct.snow [0, 1, 0]
          block [1]
            return
              ident x [var: int]
        struct T [0, 1, 0] [type: struct T]
        struct T [0, 1, 0, 0] [type: struct T]
          fn get [let: () -> string]
            ident string [type: string]
            block [1]

M pkg/semantic/testdata/check/fn_assign_invalid.snow.want => pkg/semantic/testdata/check/fn_assign_invalid.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_assign_invalid.snow [0, 1, 0]
file testdata/fn_assign_invalid.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [2]
      var: x [var: f64]

M pkg/semantic/testdata/check/fn_assign_let.snow.want => pkg/semantic/testdata/check/fn_assign_let.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_assign_let.snow [0, 1, 0]
file testdata/fn_assign_let.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [2]
      let= x [let: int]

M pkg/semantic/testdata/check/fn_assign_struct_fields.snow.want => pkg/semantic/testdata/check/fn_assign_struct_fields.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_assign_struct_fields.snow [0, 1, 1]
file testdata/fn_assign_struct_fields.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [8]
      var: vs [var: struct S]


@@ 35,7 35,7 @@ file testdata/fn_assign_struct_fields.snow [0, 1, 1]
          ident ls [let: struct S]
          ident z [let: () -> void]
        ident test [let: () -> void]
  struct S [2, 1, 0] [type: struct S]
  struct S [2, 1, 0, 0] [type: struct S]
    let: x [let: int]
      ident int [type: int]
    var: y [var: int]

M pkg/semantic/testdata/check/fn_assign_struct_method_to_var.snow.want => pkg/semantic/testdata/check/fn_assign_struct_method_to_var.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_assign_struct_method_to_var.snow [0, 1, 1]
file testdata/fn_assign_struct_method_to_var.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [6]
      var: s [var: struct S]


@@ 28,7 28,7 @@ file testdata/fn_assign_struct_method_to_var.snow [0, 1, 1]
        select [let: (int) -> void]
          ident s2 [let: struct S]
          ident set [let: (int) -> void]
  struct S [1, 2, 0] [type: struct S]
  struct S [1, 2, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    fn get [let: () -> int]

M pkg/semantic/testdata/check/fn_assign_type.snow.want => pkg/semantic/testdata/check/fn_assign_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_assign_type.snow [0, 1, 0]
file testdata/fn_assign_type.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [1]
      assign

M pkg/semantic/testdata/check/fn_assign_unifying_type.snow.want => pkg/semantic/testdata/check/fn_assign_unifying_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_assign_unifying_type.snow [0, 1, 0]
file testdata/fn_assign_unifying_type.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      var: x [var: u8]

M pkg/semantic/testdata/check/fn_call_fn_value_with_labels.snow.want => pkg/semantic/testdata/check/fn_call_fn_value_with_labels.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_call_fn_value_with_labels.snow [0, 2, 0]
file testdata/fn_call_fn_value_with_labels.snow [0, 2, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_call_struct_init.snow.want => pkg/semantic/testdata/check/fn_call_struct_init.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_struct_init.snow [0, 1, 1]
file testdata/fn_call_struct_init.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [1]
      var= s [var: struct S]


@@ 6,7 6,7 @@ file testdata/fn_call_struct_init.snow [0, 1, 1]
          ident S [type: struct S]
          int [1] [const: int]
          string ["a"] [const: string]
  struct S [2, 0, 0] [type: struct S]
  struct S [2, 0, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    let: y [let: string]

M pkg/semantic/testdata/check/fn_call_struct_init_no_label.snow.want => pkg/semantic/testdata/check/fn_call_struct_init_no_label.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_struct_init_no_label.snow [0, 1, 1]
file testdata/fn_call_struct_init_no_label.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [1]
      var= s [var: struct S]


@@ 6,7 6,7 @@ file testdata/fn_call_struct_init_no_label.snow [0, 1, 1]
          ident S [type: struct S]
          int [1] [const: int]
          string ["a"] [const: string]
  struct S [2, 0, 0] [type: struct S]
  struct S [2, 0, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    let: y [let: string]

M pkg/semantic/testdata/check/fn_call_struct_init_only_required_no_order.snow.want => pkg/semantic/testdata/check/fn_call_struct_init_only_required_no_order.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_struct_init_only_required_no_order.snow [0, 1, 1]
file testdata/fn_call_struct_init_only_required_no_order.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [2]
      var= s [var: struct S]


@@ 10,7 10,7 @@ file testdata/fn_call_struct_init_only_required_no_order.snow [0, 1, 1]
        call [b] [1] [value: struct S]
          ident S [type: struct S]
          string ["b"] [const: string]
  struct S [3, 0, 0] [type: struct S]
  struct S [3, 0, 0, 0] [type: struct S]
    var: a [var: int]
      ident int [type: int]
    let: b [let: string]

M pkg/semantic/testdata/check/fn_call_struct_method.snow.want => pkg/semantic/testdata/check/fn_call_struct_method.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_struct_method.snow [0, 1, 1]
file testdata/fn_call_struct_method.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [2]
      var: p [var: struct Point]


@@ 9,7 9,7 @@ file testdata/fn_call_struct_method.snow [0, 1, 1]
            ident p [var: struct Point]
            ident add [let: (int) -> void]
          int [1] [const: int]
  struct Point [1, 1, 0] [type: struct Point]
  struct Point [1, 1, 0, 0] [type: struct Point]
    var: x [var: int]
      ident int [type: int]
    fn add [let: (int) -> void]

M pkg/semantic/testdata/check/fn_call_unifying_type.snow.want => pkg/semantic/testdata/check/fn_call_unifying_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_call_unifying_type.snow [0, 2, 0]
file testdata/fn_call_unifying_type.snow [0, 2, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_call_with_invalid_labels.snow.want => pkg/semantic/testdata/check/fn_call_with_invalid_labels.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_call_with_invalid_labels.snow [0, 2, 0]
file testdata/fn_call_with_invalid_labels.snow [0, 2, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_call_with_labels.snow.want => pkg/semantic/testdata/check/fn_call_with_labels.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_with_labels.snow [0, 2, 1]
file testdata/fn_call_with_labels.snow [0, 2, 1, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]


@@ 45,7 45,7 @@ file testdata/fn_call_with_labels.snow [0, 2, 1]
                ident s [var: struct S]
              ident do [let: (int) -> void]
          int [6] [const: int]
  struct S [0, 1, 0] [type: struct S]
  struct S [0, 1, 0, 0] [type: struct S]
    fn do [let: (int) -> void]
      let: z [let: int]
        ident int [type: int]

M pkg/semantic/testdata/check/fn_call_wrong_arity.snow.want => pkg/semantic/testdata/check/fn_call_wrong_arity.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_call_wrong_arity.snow [0, 2, 0]
file testdata/fn_call_wrong_arity.snow [0, 2, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_compare.snow.want => pkg/semantic/testdata/check/fn_compare.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_compare.snow [0, 1, 0]
file testdata/fn_compare.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [2]
      var= x [var: int]

M pkg/semantic/testdata/check/fn_complex_selectors.snow.want => pkg/semantic/testdata/check/fn_complex_selectors.snow.want +3 -3
@@ 1,4 1,4 @@
file testdata/fn_complex_selectors.snow [0, 2, 1]
file testdata/fn_complex_selectors.snow [0, 2, 1, 0]
  fn create [let: () -> struct S]
    ident S [type: struct S]
    block [2]


@@ 36,12 36,12 @@ file testdata/fn_complex_selectors.snow [0, 2, 1]
                  ident s2 [var: struct T]
                ident do [let: () -> (int, () -> int)]
            ident 1 [value: () -> int]
  struct S [2, 0, 1] [type: struct S]
  struct S [2, 0, 1, 0] [type: struct S]
    var: s1 [var: int]
      ident int [type: int]
    var: s2 [var: struct T]
      ident T [type: struct T]
    struct T [1, 1, 0] [type: struct T]
    struct T [1, 1, 0, 0] [type: struct T]
      var: t1 [var: string]
        ident string [type: string]
      fn do [let: () -> (int, () -> int)]

M pkg/semantic/testdata/check/fn_duplicate_param_name.snow.want => pkg/semantic/testdata/check/fn_duplicate_param_name.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_duplicate_param_name.snow [0, 1, 0]
file testdata/fn_duplicate_param_name.snow [0, 1, 0, 0]
  fn dup [let: (int, string) -> void]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_explicit_void.snow.want => pkg/semantic/testdata/check/fn_explicit_void.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_explicit_void.snow [0, 3, 0]
file testdata/fn_explicit_void.snow [0, 3, 0, 0]
  fn do_nothing [let: () -> void]
    ident void [type: void]
    block [1]

M pkg/semantic/testdata/check/fn_extern_pkg_before_conflict_name.snow.want => pkg/semantic/testdata/check/fn_extern_pkg_before_conflict_name.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_extern_pkg_before_conflict_name.snow [0, 1, 0]
file testdata/fn_extern_pkg_before_conflict_name.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [4]
      fn print [let: (int) -> void]

M pkg/semantic/testdata/check/fn_extern_pkg_conflict_name.snow.want => pkg/semantic/testdata/check/fn_extern_pkg_conflict_name.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_extern_pkg_conflict_name.snow [0, 1, 0]
file testdata/fn_extern_pkg_conflict_name.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [4]
      var: fmt [var: int]

M pkg/semantic/testdata/check/fn_extern_ref_method.snow.want => pkg/semantic/testdata/check/fn_extern_ref_method.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/fn_extern_ref_method.snow [0, 1, 0]
file testdata/fn_extern_ref_method.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [1]
      struct S [0, 1, 0] [type: struct S]
      struct S [0, 1, 0, 0] [type: struct S]
        ref fn f [let: () -> void]
          @ [import, symbol] [2] [value: struct extern]
            ident extern [type: struct extern]

M pkg/semantic/testdata/check/fn_extern_with_body.snow.want => pkg/semantic/testdata/check/fn_extern_with_body.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_extern_with_body.snow [0, 1, 0]
file testdata/fn_extern_with_body.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    @ [import, symbol] [2] [value: struct extern]
      ident extern [type: struct extern]

M pkg/semantic/testdata/check/fn_fn_arg.snow.want => pkg/semantic/testdata/check/fn_fn_arg.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_fn_arg.snow [0, 3, 0]
file testdata/fn_fn_arg.snow [0, 3, 0, 0]
  fn do [let: (int, (int) -> int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_generic_decl_after_inst.snow.want => pkg/semantic/testdata/check/fn_generic_decl_after_inst.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_generic_decl_after_inst.snow [0, 2, 0]
file testdata/fn_generic_decl_after_inst.snow [0, 2, 0, 0]
  fn main [let: () -> void]
    block [1]
      let= a [let: int]

M pkg/semantic/testdata/check/fn_generic_fn_uses_generic_fn.snow.want => pkg/semantic/testdata/check/fn_generic_fn_uses_generic_fn.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_generic_fn_uses_generic_fn.snow [0, 3, 0]
file testdata/fn_generic_fn_uses_generic_fn.snow [0, 3, 0, 0]
  fn A [$1] [let: ($T) -> $T]
    generic type $T [type: $T]
    let: v [let: $T]

M pkg/semantic/testdata/check/fn_generic_identity.snow.want => pkg/semantic/testdata/check/fn_generic_identity.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_generic_identity.snow [0, 5, 0]
file testdata/fn_generic_identity.snow [0, 5, 0, 0]
  fn id [$1] [let: ($T) -> $T]
    generic type $T [type: $T]
    let: v [let: $T]

M pkg/semantic/testdata/check/fn_generic_unused_in_signature.snow.want => pkg/semantic/testdata/check/fn_generic_unused_in_signature.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_generic_unused_in_signature.snow [0, 6, 0]
file testdata/fn_generic_unused_in_signature.snow [0, 6, 0, 0]
  fn g1 [$2] [let: (int) -> int]
    generic type $T [type: $T]
    generic type $U [type: $U]

M pkg/semantic/testdata/check/fn_guard_fallthrough.snow.want => pkg/semantic/testdata/check/fn_guard_fallthrough.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_guard_fallthrough.snow [0, 1, 0]
file testdata/fn_guard_fallthrough.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      var: x [var: bool]

M pkg/semantic/testdata/check/fn_ident_as_type.snow.want => pkg/semantic/testdata/check/fn_ident_as_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_ident_as_type.snow [1, 1, 0]
file testdata/fn_ident_as_type.snow [1, 1, 0, 0]
  var: x [var: () -> void]
    ident test [let: () -> void]
  fn test [let: () -> void]

M pkg/semantic/testdata/check/fn_init_order.snow.want => pkg/semantic/testdata/check/fn_init_order.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_init_order.snow [0, 1, 0]
file testdata/fn_init_order.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [2]
      var= A [var: unresolved]

M pkg/semantic/testdata/check/fn_invalid_attr.snow.want => pkg/semantic/testdata/check/fn_invalid_attr.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_attr.snow [0, 1, 0]
file testdata/fn_invalid_attr.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    @ [x] [1] [value: unresolved]
      ident invalid [invalid: unresolved]

M pkg/semantic/testdata/check/fn_invalid_extern_fields.snow.want => pkg/semantic/testdata/check/fn_invalid_extern_fields.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_extern_fields.snow [0, 3, 0]
file testdata/fn_invalid_extern_fields.snow [0, 3, 0, 0]
  fn test1 [let: () -> void]
    @ [badField] [1] [value: struct extern]
      ident extern [type: struct extern]

M pkg/semantic/testdata/check/fn_invalid_generic_use_in_fn.snow.want => pkg/semantic/testdata/check/fn_invalid_generic_use_in_fn.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_generic_use_in_fn.snow [0, 1, 0]
file testdata/fn_invalid_generic_use_in_fn.snow [0, 1, 0, 0]
  fn g [$2] [let: ($T, $U) -> void]
    generic type $T [type: $T]
    generic type $U [type: $U]

M pkg/semantic/testdata/check/fn_invalid_main.snow.want => pkg/semantic/testdata/check/fn_invalid_main.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_main.snow [0, 1, 0]
file testdata/fn_invalid_main.snow [0, 1, 0, 0]
  fn main [let: (int) -> string]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_invalid_ref.snow.want => pkg/semantic/testdata/check/fn_invalid_ref.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_ref.snow [0, 1, 0]
file testdata/fn_invalid_ref.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [1]
      ref fn test [let: () -> void]

M pkg/semantic/testdata/check/fn_invalid_ref_call.snow.want => pkg/semantic/testdata/check/fn_invalid_ref_call.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/fn_invalid_ref_call.snow [0, 1, 0]
file testdata/fn_invalid_ref_call.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      struct S [1, 1, 0] [type: struct S]
      struct S [1, 1, 0, 0] [type: struct S]
        var: x [var: int]
          ident int [type: int]
        ref fn set [let: (int) -> void]

M pkg/semantic/testdata/check/fn_invalid_ref_call_via_value.snow.want => pkg/semantic/testdata/check/fn_invalid_ref_call_via_value.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/fn_invalid_ref_call_via_value.snow [0, 1, 0]
file testdata/fn_invalid_ref_call_via_value.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      struct S [1, 1, 0] [type: struct S]
      struct S [1, 1, 0, 0] [type: struct S]
        var: x [var: int]
          ident int [type: int]
        ref fn set [let: (int) -> void]

M pkg/semantic/testdata/check/fn_invalid_return.snow.want => pkg/semantic/testdata/check/fn_invalid_return.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_return.snow [0, 1, 0]
file testdata/fn_invalid_return.snow [0, 1, 0, 0]
  fn test [let: () -> uint]
    ident uint [type: uint]
    block [1]

M pkg/semantic/testdata/check/fn_invalid_tuple_access.snow.want => pkg/semantic/testdata/check/fn_invalid_tuple_access.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_tuple_access.snow [0, 1, 0]
file testdata/fn_invalid_tuple_access.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      var: x [var: (int, string, (bool, uint))]

M pkg/semantic/testdata/check/fn_main_extern.snow.want => pkg/semantic/testdata/check/fn_main_extern.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_main_extern.snow [0, 1, 0]
file testdata/fn_main_extern.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    @ [import, symbol] [2] [value: struct extern]
      ident extern [type: struct extern]

M pkg/semantic/testdata/check/fn_many_extern.snow.want => pkg/semantic/testdata/check/fn_many_extern.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_many_extern.snow [0, 1, 0]
file testdata/fn_many_extern.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    @ [import, symbol] [2] [value: struct extern]
      ident extern [type: struct extern]

M pkg/semantic/testdata/check/fn_method_explicit_self.snow.want => pkg/semantic/testdata/check/fn_method_explicit_self.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_method_explicit_self.snow [0, 1, 1]
file testdata/fn_method_explicit_self.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [2]
      var: s [var: struct S]


@@ 8,7 8,7 @@ file testdata/fn_method_explicit_self.snow [0, 1, 1]
          select [let: () -> int]
            ident s [var: struct S]
            ident getX [let: () -> int]
  struct S [1, 1, 0] [type: struct S]
  struct S [1, 1, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    fn getX [let: () -> int]

M pkg/semantic/testdata/check/fn_multi_vars_per_decl.snow.want => pkg/semantic/testdata/check/fn_multi_vars_per_decl.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_multi_vars_per_decl.snow [0, 1, 0]
file testdata/fn_multi_vars_per_decl.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      var:= x [var: int]

M pkg/semantic/testdata/check/fn_nested_block.snow.want => pkg/semantic/testdata/check/fn_nested_block.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_block.snow [0, 1, 0]
file testdata/fn_nested_block.snow [0, 1, 0, 0]
  fn test [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_nested_fn.snow.want => pkg/semantic/testdata/check/fn_nested_fn.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_fn.snow [0, 1, 0]
file testdata/fn_nested_fn.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [4]
      fn add [let: (int, int) -> int]

M pkg/semantic/testdata/check/fn_nested_fn_init_order.snow.want => pkg/semantic/testdata/check/fn_nested_fn_init_order.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_fn_init_order.snow [0, 1, 0]
file testdata/fn_nested_fn_init_order.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      fn A [let: () -> void]

M pkg/semantic/testdata/check/fn_nested_generic_fn.snow.want => pkg/semantic/testdata/check/fn_nested_generic_fn.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_generic_fn.snow [0, 3, 0]
file testdata/fn_nested_generic_fn.snow [0, 3, 0, 0]
  fn call [let: ((bool) -> bool) -> bool]
    let: f [let: (bool) -> bool]
      sig [1->1] [type: (bool) -> bool]

M pkg/semantic/testdata/check/fn_nested_struct_method.snow.want => pkg/semantic/testdata/check/fn_nested_struct_method.snow.want +3 -3
@@ 1,7 1,7 @@
file testdata/fn_nested_struct_method.snow [0, 1, 0]
file testdata/fn_nested_struct_method.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [6]
      struct S [1, 1, 1] [type: struct S]
      struct S [1, 1, 1, 0] [type: struct S]
        var: x [var: string]
          ident string [type: string]
        ref fn init [let: () -> void]


@@ 9,7 9,7 @@ file testdata/fn_nested_struct_method.snow [0, 1, 0]
            assign
              ident x [var: string]
              string ["hello"] [const: string]
        struct T [1, 1, 0] [type: struct T]
        struct T [1, 1, 0, 0] [type: struct T]
          var: y [var: string]
            ident string [type: string]
          ref fn append [let: (string) -> void]

M pkg/semantic/testdata/check/fn_nested_struct_self.snow.want => pkg/semantic/testdata/check/fn_nested_struct_self.snow.want +3 -3
@@ 1,8 1,8 @@
file testdata/fn_nested_struct_self.snow [0, 0, 1]
  struct S [1, 0, 1] [type: struct S]
file testdata/fn_nested_struct_self.snow [0, 0, 1, 0]
  struct S [1, 0, 1, 0] [type: struct S]
    var: x [var: string]
      ident string [type: string]
    struct T [1, 1, 0] [type: struct T]
    struct T [1, 1, 0, 0] [type: struct T]
      var: x [var: int]
        ident int [type: int]
      fn negate [let: () -> int]

M pkg/semantic/testdata/check/fn_nested_structs.snow.want => pkg/semantic/testdata/check/fn_nested_structs.snow.want +3 -3
@@ 1,10 1,10 @@
file testdata/fn_nested_structs.snow [0, 1, 0]
file testdata/fn_nested_structs.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      struct Outer [1, 0, 1] [type: struct Outer]
      struct Outer [1, 0, 1, 0] [type: struct Outer]
        let: x [let: struct Inner]
          ident Inner [type: struct Inner]
        struct Inner [1, 0, 0] [type: struct Inner]
        struct Inner [1, 0, 0, 0] [type: struct Inner]
          let: y [let: int]
            ident int [type: int]
      var: o [var: struct Outer]

M pkg/semantic/testdata/check/fn_nested_tuple_type.snow.want => pkg/semantic/testdata/check/fn_nested_tuple_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_tuple_type.snow [0, 1, 0]
file testdata/fn_nested_tuple_type.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [1]
      var: x [var: (int, (bool, string))]

M pkg/semantic/testdata/check/fn_non_type_selectors.snow.want => pkg/semantic/testdata/check/fn_non_type_selectors.snow.want +3 -3
@@ 1,4 1,4 @@
file testdata/fn_non_type_selectors.snow [2, 1, 1]
file testdata/fn_non_type_selectors.snow [2, 1, 1, 0]
  var: x [var: int]
    ident int [type: int]
  let: y [let: string]


@@ 40,9 40,9 @@ file testdata/fn_non_type_selectors.snow [2, 1, 1]
              ident S [type: struct S]
              ident T [type: struct T]
            ident tt [var: int]
  struct S [1, 0, 1] [type: struct S]
  struct S [1, 0, 1, 0] [type: struct S]
    var: ss [var: int]
      ident int [type: int]
    struct T [1, 0, 0] [type: struct T]
    struct T [1, 0, 0, 0] [type: struct T]
      var: tt [var: int]
        ident int [type: int]

M pkg/semantic/testdata/check/fn_param_type_is_var_in_body.snow.want => pkg/semantic/testdata/check/fn_param_type_is_var_in_body.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_param_type_is_var_in_body.snow [0, 1, 0]
file testdata/fn_param_type_is_var_in_body.snow [0, 1, 0, 0]
  fn test [let: (int) -> void]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_params.snow.want => pkg/semantic/testdata/check/fn_params.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_params.snow [0, 1, 0]
file testdata/fn_params.snow [0, 1, 0, 0]
  fn test [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_params_locals.snow.want => pkg/semantic/testdata/check/fn_params_locals.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_params_locals.snow [0, 1, 0]
file testdata/fn_params_locals.snow [0, 1, 0, 0]
  fn test [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_recursion.snow.want => pkg/semantic/testdata/check/fn_recursion.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_recursion.snow [0, 1, 0]
file testdata/fn_recursion.snow [0, 1, 0, 0]
  fn test [let: (int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_ref_on_fn_nested_in_method.snow.want => pkg/semantic/testdata/check/fn_ref_on_fn_nested_in_method.snow.want +2 -2
@@ 1,5 1,5 @@
file testdata/fn_ref_on_fn_nested_in_method.snow [0, 0, 1]
  struct S [1, 1, 0] [type: struct S]
file testdata/fn_ref_on_fn_nested_in_method.snow [0, 0, 1, 0]
  struct S [1, 1, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    ref fn rf [let: () -> void]

M pkg/semantic/testdata/check/fn_return_internal_struct.snow.want => pkg/semantic/testdata/check/fn_return_internal_struct.snow.want +2 -2
@@ 1,8 1,8 @@
file testdata/fn_return_internal_struct.snow [0, 1, 0]
file testdata/fn_return_internal_struct.snow [0, 1, 0, 0]
  fn test [let: () -> unresolved]
    ident S [invalid: unresolved]
    block [3]
      struct S [0, 0, 0] [type: struct S]
      struct S [0, 0, 0, 0] [type: struct S]
      var: s [var: struct S]
        ident S [type: struct S]
      return

M pkg/semantic/testdata/check/fn_return_missing_value.snow.want => pkg/semantic/testdata/check/fn_return_missing_value.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_return_missing_value.snow [0, 1, 0]
file testdata/fn_return_missing_value.snow [0, 1, 0, 0]
  fn test [let: () -> int]
    ident int [type: int]
    block [1]

M pkg/semantic/testdata/check/fn_return_struct.snow.want => pkg/semantic/testdata/check/fn_return_struct.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_return_struct.snow [0, 2, 1]
file testdata/fn_return_struct.snow [0, 2, 1, 0]
  fn newS [let: () -> struct S]
    ident S [type: struct S]
    block [2]


@@ 42,7 42,7 @@ file testdata/fn_return_struct.snow [0, 2, 1]
            ident newS [let: () -> struct S]
          ident z [let: () -> void]
        ident test [let: () -> void]
  struct S [2, 1, 0] [type: struct S]
  struct S [2, 1, 0, 0] [type: struct S]
    let: x [let: int]
      ident int [type: int]
    var: y [var: int]

M pkg/semantic/testdata/check/fn_return_unifying_type.snow.want => pkg/semantic/testdata/check/fn_return_unifying_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_return_unifying_type.snow [0, 1, 0]
file testdata/fn_return_unifying_type.snow [0, 1, 0, 0]
  fn test [let: () -> i16]
    ident i16 [type: i16]
    block [2]

M pkg/semantic/testdata/check/fn_struct_main_method.snow.want => pkg/semantic/testdata/check/fn_struct_main_method.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/fn_struct_main_method.snow [0, 1, 1]
file testdata/fn_struct_main_method.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [0]
  struct S [0, 1, 0] [type: struct S]
  struct S [0, 1, 0, 0] [type: struct S]
    fn main [let: (int) -> void]
      let: x [let: int]
        ident int [type: int]

M pkg/semantic/testdata/check/fn_struct_method_access_top_level.snow.want => pkg/semantic/testdata/check/fn_struct_method_access_top_level.snow.want +2 -2
@@ 1,9 1,9 @@
file testdata/fn_struct_method_access_top_level.snow [1, 1, 1]
file testdata/fn_struct_method_access_top_level.snow [1, 1, 1, 0]
  var: x [var: int]
    ident int [type: int]
  fn main [let: () -> void]
    block [0]
  struct S [0, 1, 0] [type: struct S]
  struct S [0, 1, 0, 0] [type: struct S]
    fn get [let: () -> int]
      ident int [type: int]
      block [1]

M pkg/semantic/testdata/check/fn_struct_order_independent.snow.want => pkg/semantic/testdata/check/fn_struct_order_independent.snow.want +2 -2
@@ 1,5 1,5 @@
file testdata/fn_struct_order_independent.snow [0, 0, 1]
  struct S [2, 1, 0] [type: struct S]
file testdata/fn_struct_order_independent.snow [0, 0, 1, 0]
  struct S [2, 1, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    let: y [let: int]

M pkg/semantic/testdata/check/fn_struct_same_name_diff_scope.snow.want => pkg/semantic/testdata/check/fn_struct_same_name_diff_scope.snow.want +3 -3
@@ 1,11 1,11 @@
file testdata/fn_struct_same_name_diff_scope.snow [0, 1, 0]
file testdata/fn_struct_same_name_diff_scope.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      struct A [0, 0, 0] [type: struct A]
      struct A [0, 0, 0, 0] [type: struct A]
      var: a [var: struct A]
        ident A [type: struct A]
      block [3]
        struct A [0, 0, 0] [type: struct A]
        struct A [0, 0, 0, 0] [type: struct A]
        var: b [var: struct A]
          ident A [type: struct A]
        assign

M pkg/semantic/testdata/check/fn_struct_selector.snow.want => pkg/semantic/testdata/check/fn_struct_selector.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_struct_selector.snow [0, 1, 1]
file testdata/fn_struct_selector.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [2]
      var: p [var: struct Point]


@@ 7,6 7,6 @@ file testdata/fn_struct_selector.snow [0, 1, 1]
        select [let: int]
          ident p [var: struct Point]
          ident x [let: int]
  struct Point [1, 0, 0] [type: struct Point]
  struct Point [1, 0, 0, 0] [type: struct Point]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/fn_struct_self_shadow.snow.want => pkg/semantic/testdata/check/fn_struct_self_shadow.snow.want +2 -2
@@ 1,5 1,5 @@
file testdata/fn_struct_self_shadow.snow [0, 0, 1]
  struct S [1, 1, 0] [type: struct S]
file testdata/fn_struct_self_shadow.snow [0, 0, 1, 0]
  struct S [1, 1, 0, 0] [type: struct S]
    var: self [var: int]
      ident int [type: int]
    fn get [let: () -> int]

M pkg/semantic/testdata/check/fn_struct_self_uses.snow.want => pkg/semantic/testdata/check/fn_struct_self_uses.snow.want +2 -2
@@ 1,5 1,5 @@
file testdata/fn_struct_self_uses.snow [0, 0, 1]
  struct S [0, 1, 0] [type: struct S]
file testdata/fn_struct_self_uses.snow [0, 0, 1, 0]
  struct S [0, 1, 0, 0] [type: struct S]
    fn set [let: () -> void]
      block [1]
        var: self [var: int]

M pkg/semantic/testdata/check/fn_tuple_assign_compatible_types.snow.want => pkg/semantic/testdata/check/fn_tuple_assign_compatible_types.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_tuple_assign_compatible_types.snow [0, 1, 0]
file testdata/fn_tuple_assign_compatible_types.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [4]
      var: i [var: i16]

M pkg/semantic/testdata/check/fn_tuple_assign_incompatible_types.snow.want => pkg/semantic/testdata/check/fn_tuple_assign_incompatible_types.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_tuple_assign_incompatible_types.snow [0, 1, 0]
file testdata/fn_tuple_assign_incompatible_types.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [4]
      var: t [var: (i32, u16, bool)]

M pkg/semantic/testdata/check/fn_tuple_expr_select_field.snow.want => pkg/semantic/testdata/check/fn_tuple_expr_select_field.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_tuple_expr_select_field.snow [0, 1, 0]
file testdata/fn_tuple_expr_select_field.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [4]
      var= t1 [var: (int, int, int)]

M pkg/semantic/testdata/check/fn_type_as_value.snow.want => pkg/semantic/testdata/check/fn_type_as_value.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_type_as_value.snow [0, 1, 0]
file testdata/fn_type_as_value.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [1]
      let= res [let: int]

M pkg/semantic/testdata/check/fn_unknown_symbol.snow.want => pkg/semantic/testdata/check/fn_unknown_symbol.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_unknown_symbol.snow [0, 1, 0]
file testdata/fn_unknown_symbol.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [1]
      expr

M pkg/semantic/testdata/check/fn_var_as_param_type.snow.want => pkg/semantic/testdata/check/fn_var_as_param_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_var_as_param_type.snow [3, 1, 0]
file testdata/fn_var_as_param_type.snow [3, 1, 0, 0]
  var: x [var: int]
    ident int [type: int]
  var: f [var: (int) -> void]

M pkg/semantic/testdata/check/fn_without_body.snow.want => pkg/semantic/testdata/check/fn_without_body.snow.want +1 -1
@@ 1,2 1,2 @@
file testdata/fn_without_body.snow [0, 1, 0]
file testdata/fn_without_body.snow [0, 1, 0, 0]
  fn test [let: () -> void]

M pkg/semantic/testdata/check/fns.snow.want => pkg/semantic/testdata/check/fns.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fns.snow [0, 3, 0]
file testdata/fns.snow [0, 3, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/check/generic_struct_instantiation.snow.want => pkg/semantic/testdata/check/generic_struct_instantiation.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/generic_struct_instantiation.snow [0, 1, 1]
file testdata/generic_struct_instantiation.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [2]
      let= g1 [let: struct G[int]]


@@ 11,7 11,7 @@ file testdata/generic_struct_instantiation.snow [0, 1, 1]
        generic inst [1] [type: struct G[string]]
          ident G [type: struct G]
          ident string [type: string]
  struct G [1, 0, 0, $1] [type: struct G]
  struct G [1, 0, 0, 0, $1] [type: struct G]
    generic type $T [type: $T]
    var: x [var: $T]
      ident $T [type: $T]

M pkg/semantic/testdata/check/guard_else.snow.want => pkg/semantic/testdata/check/guard_else.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/guard_else.snow [0, 1, 0]
file testdata/guard_else.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      var= x [var: bool]

M pkg/semantic/testdata/check/if_else_if.snow.want => pkg/semantic/testdata/check/if_else_if.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/if_else_if.snow [0, 1, 0]
file testdata/if_else_if.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      var= x [var: bool]

M pkg/semantic/testdata/check/if_non_bool.snow.want => pkg/semantic/testdata/check/if_non_bool.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/if_non_bool.snow [0, 1, 0]
file testdata/if_non_bool.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [2]
      var= x [var: int]

M pkg/semantic/testdata/check/invalid_binary_op.snow.want => pkg/semantic/testdata/check/invalid_binary_op.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/invalid_binary_op.snow [3, 0, 0]
file testdata/invalid_binary_op.snow [3, 0, 0, 0]
  var= x [var: int]
    int [3] [const: int]
  var= y [var: string]

M pkg/semantic/testdata/check/let.snow.want => pkg/semantic/testdata/check/let.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/let.snow [1, 0, 0]
file testdata/let.snow [1, 0, 0, 0]
  let:= y [let: string]
    ident string [type: string]
    string ["abc"] [const: string]

M pkg/semantic/testdata/check/let_invalid_tuple_type.snow.want => pkg/semantic/testdata/check/let_invalid_tuple_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/let_invalid_tuple_type.snow [1, 0, 0]
file testdata/let_invalid_tuple_type.snow [1, 0, 0, 0]
  let: x [let: (int, bool)]
    tuple type [2] [type: (int, bool)]
      ident int [type: int]

M pkg/semantic/testdata/check/let_invalid_unary.snow.want => pkg/semantic/testdata/check/let_invalid_unary.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/let_invalid_unary.snow [1, 0, 0]
file testdata/let_invalid_unary.snow [1, 0, 0, 0]
  let= x [let: unresolved]
    unary [!] [value: unresolved]
      string ["a"] [const: string]

M pkg/semantic/testdata/check/let_unary.snow.want => pkg/semantic/testdata/check/let_unary.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/let_unary.snow [1, 0, 0]
file testdata/let_unary.snow [1, 0, 0, 0]
  let= x [let: int]
    unary [-] [value: int]
      int [1] [const: int]

M pkg/semantic/testdata/check/paren_type.snow.want => pkg/semantic/testdata/check/paren_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/paren_type.snow [1, 0, 0]
file testdata/paren_type.snow [1, 0, 0, 0]
  var:= x [var: int]
    paren [type: int]
      ident int [type: int]

M pkg/semantic/testdata/check/struct_complex_generic.snow.want => pkg/semantic/testdata/check/struct_complex_generic.snow.want +3 -3
@@ 1,4 1,4 @@
file testdata/struct_complex_generic.snow [0, 3, 1]
file testdata/struct_complex_generic.snow [0, 3, 1, 0]
  fn str [let: (string) -> string]
    let: s [let: string]
      ident string [type: string]


@@ 29,7 29,7 @@ file testdata/struct_complex_generic.snow [0, 3, 1]
                ident string [type: string]
            ident str [let: (string) -> string]
          ident integer [let: (int) -> int]
  struct A [2, 0, 1, $2] [type: struct A]
  struct A [2, 0, 1, 0, $2] [type: struct A]
    generic type $T [type: $T]
    generic type $U [type: $U]
    var: bb [var: struct B[$U]]


@@ 40,7 40,7 @@ file testdata/struct_complex_generic.snow [0, 3, 1]
      sig [1->1] [type: ($T) -> $T]
        ident $T [type: $T]
        ident $T [type: $T]
    struct B [1, 0, 0, $1] [type: struct B]
    struct B [1, 0, 0, 0, $1] [type: struct B]
      generic type $V [type: $V]
      var: ffb [var: ($V) -> $V]
        sig [1->1] [type: ($V) -> $V]

M pkg/semantic/testdata/check/struct_generic.snow.want => pkg/semantic/testdata/check/struct_generic.snow.want +5 -5
@@ 1,5 1,5 @@
file testdata/struct_generic.snow [0, 0, 4]
  struct A [2, 1, 0] [type: struct A]
file testdata/struct_generic.snow [0, 0, 4, 0]
  struct A [2, 1, 0, 0] [type: struct A]
    var: x [var: unresolved]
      ident $T [invalid: unresolved]
    let: y [let: unresolved]


@@ 14,7 14,7 @@ file testdata/struct_generic.snow [0, 0, 4]
          block [1]
            let: c [let: unresolved]
              ident $W [invalid: unresolved]
  struct B [1, 1, 0, $3] [type: struct B]
  struct B [1, 1, 0, 0, $3] [type: struct B]
    generic type $T [type: $T]
    generic type $U [type: $U]
    generic type $V [type: $V]


@@ 26,7 26,7 @@ file testdata/struct_generic.snow [0, 0, 4]
      block [1]
        var: z [var: $U]
          ident $U [type: $U]
  struct C [2, 0, 0, $3] [type: struct C]
  struct C [2, 0, 0, 0, $3] [type: struct C]
    generic type $T [type: $T]
    generic type $U [type: $U]
    generic type $T [type: $T]


@@ 34,7 34,7 @@ file testdata/struct_generic.snow [0, 0, 4]
      ident $T [type: $T]
    let: y [let: $U]
      ident $U [type: $U]
  struct D [3, 0, 0, $2] [type: struct D]
  struct D [3, 0, 0, 0, $2] [type: struct D]
    generic type $T [type: $T]
    generic type $U [type: $U]
    var: v [var: $T]

M pkg/semantic/testdata/check/struct_simple_generic.snow.want => pkg/semantic/testdata/check/struct_simple_generic.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/struct_simple_generic.snow [0, 2, 1]
file testdata/struct_simple_generic.snow [0, 2, 1, 0]
  fn main [let: () -> void]
    block [2]
      let= a [let: struct A[int]]


@@ 20,7 20,7 @@ file testdata/struct_simple_generic.snow [0, 2, 1]
      string ["Println"] [const: string]
    let: i [let: int]
      ident int [type: int]
  struct A [1, 0, 0, $1] [type: struct A]
  struct A [1, 0, 0, 0, $1] [type: struct A]
    generic type $T [type: $T]
    var: x [var: $T]
      ident $T [type: $T]

M pkg/semantic/testdata/check/struct_var_expr_call_method.snow.want => pkg/semantic/testdata/check/struct_var_expr_call_method.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/struct_var_expr_call_method.snow [0, 1, 1]
file testdata/struct_var_expr_call_method.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [0]
  struct S [3, 2, 0] [type: struct S]
  struct S [3, 2, 0, 0] [type: struct S]
    var:= x [var: int]
      ident int [type: int]
      call [0] [value: int]

M pkg/semantic/testdata/check/top_level_fn_init_order.snow.want => pkg/semantic/testdata/check/top_level_fn_init_order.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/top_level_fn_init_order.snow [0, 2, 0]
file testdata/top_level_fn_init_order.snow [0, 2, 0, 0]
  fn A [let: () -> void]
    block [1]
      expr

M pkg/semantic/testdata/check/top_level_init_order.snow.want => pkg/semantic/testdata/check/top_level_init_order.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/top_level_init_order.snow [2, 0, 0]
file testdata/top_level_init_order.snow [2, 0, 0, 0]
  var= A [var: int]
    ident B [let: int]
  let= B [let: int]

M pkg/semantic/testdata/check/tuple_as_struct_generic.snow.want => pkg/semantic/testdata/check/tuple_as_struct_generic.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/tuple_as_struct_generic.snow [0, 2, 1]
file testdata/tuple_as_struct_generic.snow [0, 2, 1, 0]
  fn main [let: () -> void]
    block [2]
      let:= s [let: struct S[(int, bool, string)]]


@@ 34,7 34,7 @@ file testdata/tuple_as_struct_generic.snow [0, 2, 1]
      string ["Println"] [const: string]
    let: v [let: string]
      ident string [type: string]
  struct S [1, 0, 0, $1] [type: struct S]
  struct S [1, 0, 0, 0, $1] [type: struct S]
    generic type $T [type: $T]
    let: t [let: $T]
      ident $T [type: $T]

M pkg/semantic/testdata/check/var.snow.want => pkg/semantic/testdata/check/var.snow.want +1 -1
@@ 1,3 1,3 @@
file testdata/var.snow [1, 0, 0]
file testdata/var.snow [1, 0, 0, 0]
  var: x [var: int]
    ident int [type: int]

M pkg/semantic/testdata/check/var_auto_ref.snow.want => pkg/semantic/testdata/check/var_auto_ref.snow.want +1 -1
@@ 1,3 1,3 @@
file testdata/var_auto_ref.snow [1, 0, 0]
file testdata/var_auto_ref.snow [1, 0, 0, 0]
  var= x [var: unresolved]
    ident x [var: unresolved]

M pkg/semantic/testdata/check/var_bool.snow.want => pkg/semantic/testdata/check/var_bool.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/var_bool.snow [2, 0, 0]
file testdata/var_bool.snow [2, 0, 0, 0]
  var= t [var: bool]
    ident true [let: bool]
  var= f [var: bool]

M pkg/semantic/testdata/check/var_duplicate_symbol.snow.want => pkg/semantic/testdata/check/var_duplicate_symbol.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/var_duplicate_symbol.snow [2, 0, 0]
file testdata/var_duplicate_symbol.snow [2, 0, 0, 0]
  var: x [var: int]
    ident int [type: int]
  var: x [var: string]

M pkg/semantic/testdata/check/var_tuple_type.snow.want => pkg/semantic/testdata/check/var_tuple_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/var_tuple_type.snow [1, 0, 0]
file testdata/var_tuple_type.snow [1, 0, 0, 0]
  var: x [var: (int, string, bool)]
    tuple type [3] [type: (int, string, bool)]
      ident int [type: int]

A pkg/semantic/testdata/generic_interface.snow.notyet => pkg/semantic/testdata/generic_interface.snow.notyet +4 -0
@@ 0,0 1,4 @@
interface I[$T, $U] {
  fn get_t() -> $T
  ref fn set_u(u: $U)
}

A pkg/semantic/testdata/scopes/generic_interface.snow.err => pkg/semantic/testdata/scopes/generic_interface.snow.err +0 -0

A pkg/semantic/testdata/scopes/generic_interface.snow.want => pkg/semantic/testdata/scopes/generic_interface.snow.want +40 -0
@@ 0,0 1,40 @@
1 *semantic.Unit {
.  bool
.  extern
.  f32
.  f64
.  false
.  float
.  i16
.  i32
.  i64
.  i8
.  int
.  string
.  true
.  u16
.  u32
.  u64
.  u8
.  uint
.  void
.  2 *semantic.Struct {
.  .  import
.  .  pkg
.  .  symbol
.  }
.  3 *semantic.File {
.  .  I
.  .  4 *semantic.Interface {
.  .  .  $T
.  .  .  $U
.  .  .  get_t
.  .  .  set_u
.  .  .  5 *semantic.Fn {
.  .  .  }
.  .  .  6 *semantic.Fn {
.  .  .  .  u
.  .  .  }
.  .  }
.  }
}

M pkg/semantic/testdata/types/cycle.snow.want => pkg/semantic/testdata/types/cycle.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/cycle.snow [3, 0, 0]
file testdata/cycle.snow [3, 0, 0, 0]
  var= A [var: unresolved]
    ident B [var: unresolved]
  var= B [var: unresolved]

M pkg/semantic/testdata/types/empty.snow.want => pkg/semantic/testdata/types/empty.snow.want +1 -1
@@ 1,1 1,1 @@
file testdata/empty.snow [0, 0, 0]
file testdata/empty.snow [0, 0, 0, 0]

M pkg/semantic/testdata/types/fn.snow.want => pkg/semantic/testdata/types/fn.snow.want +1 -1
@@ 1,3 1,3 @@
file testdata/fn.snow [0, 1, 0]
file testdata/fn.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [0]

M pkg/semantic/testdata/types/fn_access_invalid_struct_field.snow.want => pkg/semantic/testdata/types/fn_access_invalid_struct_field.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_access_invalid_struct_field.snow [0, 1, 1]
file testdata/fn_access_invalid_struct_field.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [4]
      var: s [var: struct S]


@@ 16,6 16,6 @@ file testdata/fn_access_invalid_struct_field.snow [0, 1, 1]
        select [invalid: unresolved]
          ident s [var: struct S]
          ident z [invalid: unresolved]
  struct S [1, 0, 0] [type: struct S]
  struct S [1, 0, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_access_struct_type_field.snow.want => pkg/semantic/testdata/types/fn_access_struct_type_field.snow.want +2 -2
@@ 1,10 1,10 @@
file testdata/fn_access_struct_type_field.snow [0, 1, 1]
file testdata/fn_access_struct_type_field.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [1]
      var= y [var: int]
        select [invalid: int]
          ident Point [type: struct Point]
          ident x [var: int]
  struct Point [1, 0, 0] [type: struct Point]
  struct Point [1, 0, 0, 0] [type: struct Point]
    var: x [var: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_access_var_outside_struct.snow.want => pkg/semantic/testdata/types/fn_access_var_outside_struct.snow.want +3 -3
@@ 1,9 1,9 @@
file testdata/fn_access_var_outside_struct.snow [0, 1, 0]
file testdata/fn_access_var_outside_struct.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [2]
      var: x [var: int]
        ident int [type: int]
      struct S [1, 1, 1] [type: struct S]
      struct S [1, 1, 1, 0] [type: struct S]
        var: y [var: string]
          ident string [type: string]
        fn get [let: () -> int]


@@ 11,7 11,7 @@ file testdata/fn_access_var_outside_struct.snow [0, 1, 0]
          block [1]
            return
              ident x [var: int]
        struct T [0, 1, 0] [type: struct T]
        struct T [0, 1, 0, 0] [type: struct T]
          fn get [let: () -> string]
            ident string [type: string]
            block [1]

M pkg/semantic/testdata/types/fn_assign_invalid.snow.want => pkg/semantic/testdata/types/fn_assign_invalid.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_assign_invalid.snow [0, 1, 0]
file testdata/fn_assign_invalid.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [2]
      var: x [var: f64]

M pkg/semantic/testdata/types/fn_assign_let.snow.want => pkg/semantic/testdata/types/fn_assign_let.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_assign_let.snow [0, 1, 0]
file testdata/fn_assign_let.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [2]
      let= x [let: int]

M pkg/semantic/testdata/types/fn_assign_struct_fields.snow.want => pkg/semantic/testdata/types/fn_assign_struct_fields.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_assign_struct_fields.snow [0, 1, 1]
file testdata/fn_assign_struct_fields.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [8]
      var: vs [var: struct S]


@@ 35,7 35,7 @@ file testdata/fn_assign_struct_fields.snow [0, 1, 1]
          ident ls [let: struct S]
          ident z [let: () -> void]
        ident test [let: () -> void]
  struct S [2, 1, 0] [type: struct S]
  struct S [2, 1, 0, 0] [type: struct S]
    let: x [let: int]
      ident int [type: int]
    var: y [var: int]

M pkg/semantic/testdata/types/fn_assign_struct_method_to_var.snow.want => pkg/semantic/testdata/types/fn_assign_struct_method_to_var.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_assign_struct_method_to_var.snow [0, 1, 1]
file testdata/fn_assign_struct_method_to_var.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [6]
      var: s [var: struct S]


@@ 28,7 28,7 @@ file testdata/fn_assign_struct_method_to_var.snow [0, 1, 1]
        select [let: (int) -> void]
          ident s2 [let: struct S]
          ident set [let: (int) -> void]
  struct S [1, 2, 0] [type: struct S]
  struct S [1, 2, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    fn get [let: () -> int]

M pkg/semantic/testdata/types/fn_assign_type.snow.want => pkg/semantic/testdata/types/fn_assign_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_assign_type.snow [0, 1, 0]
file testdata/fn_assign_type.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [1]
      assign

M pkg/semantic/testdata/types/fn_assign_unifying_type.snow.want => pkg/semantic/testdata/types/fn_assign_unifying_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_assign_unifying_type.snow [0, 1, 0]
file testdata/fn_assign_unifying_type.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      var: x [var: u8]

M pkg/semantic/testdata/types/fn_call_fn_value_with_labels.snow.want => pkg/semantic/testdata/types/fn_call_fn_value_with_labels.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_call_fn_value_with_labels.snow [0, 2, 0]
file testdata/fn_call_fn_value_with_labels.snow [0, 2, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_call_struct_init.snow.want => pkg/semantic/testdata/types/fn_call_struct_init.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_struct_init.snow [0, 1, 1]
file testdata/fn_call_struct_init.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [1]
      var= s [var: struct S]


@@ 6,7 6,7 @@ file testdata/fn_call_struct_init.snow [0, 1, 1]
          ident S [type: struct S]
          int [1] [const: int]
          string ["a"] [const: string]
  struct S [2, 0, 0] [type: struct S]
  struct S [2, 0, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    let: y [let: string]

M pkg/semantic/testdata/types/fn_call_struct_init_no_label.snow.want => pkg/semantic/testdata/types/fn_call_struct_init_no_label.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_struct_init_no_label.snow [0, 1, 1]
file testdata/fn_call_struct_init_no_label.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [1]
      var= s [var: struct S]


@@ 6,7 6,7 @@ file testdata/fn_call_struct_init_no_label.snow [0, 1, 1]
          ident S [type: struct S]
          int [1] [const: int]
          string ["a"] [const: string]
  struct S [2, 0, 0] [type: struct S]
  struct S [2, 0, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    let: y [let: string]

M pkg/semantic/testdata/types/fn_call_struct_init_only_required_no_order.snow.want => pkg/semantic/testdata/types/fn_call_struct_init_only_required_no_order.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_struct_init_only_required_no_order.snow [0, 1, 1]
file testdata/fn_call_struct_init_only_required_no_order.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [2]
      var= s [var: struct S]


@@ 10,7 10,7 @@ file testdata/fn_call_struct_init_only_required_no_order.snow [0, 1, 1]
        call [b] [1] [value: struct S]
          ident S [type: struct S]
          string ["b"] [const: string]
  struct S [3, 0, 0] [type: struct S]
  struct S [3, 0, 0, 0] [type: struct S]
    var: a [var: int]
      ident int [type: int]
    let: b [let: string]

M pkg/semantic/testdata/types/fn_call_struct_method.snow.want => pkg/semantic/testdata/types/fn_call_struct_method.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_struct_method.snow [0, 1, 1]
file testdata/fn_call_struct_method.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [2]
      var: p [var: struct Point]


@@ 9,7 9,7 @@ file testdata/fn_call_struct_method.snow [0, 1, 1]
            ident p [var: struct Point]
            ident add [let: (int) -> void]
          int [1] [const: int]
  struct Point [1, 1, 0] [type: struct Point]
  struct Point [1, 1, 0, 0] [type: struct Point]
    var: x [var: int]
      ident int [type: int]
    fn add [let: (int) -> void]

M pkg/semantic/testdata/types/fn_call_unifying_type.snow.want => pkg/semantic/testdata/types/fn_call_unifying_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_call_unifying_type.snow [0, 2, 0]
file testdata/fn_call_unifying_type.snow [0, 2, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_call_with_invalid_labels.snow.want => pkg/semantic/testdata/types/fn_call_with_invalid_labels.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_call_with_invalid_labels.snow [0, 2, 0]
file testdata/fn_call_with_invalid_labels.snow [0, 2, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_call_with_labels.snow.want => pkg/semantic/testdata/types/fn_call_with_labels.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_call_with_labels.snow [0, 2, 1]
file testdata/fn_call_with_labels.snow [0, 2, 1, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]


@@ 45,7 45,7 @@ file testdata/fn_call_with_labels.snow [0, 2, 1]
                ident s [var: struct S]
              ident do [let: (int) -> void]
          int [6] [const: int]
  struct S [0, 1, 0] [type: struct S]
  struct S [0, 1, 0, 0] [type: struct S]
    fn do [let: (int) -> void]
      let: z [let: int]
        ident int [type: int]

M pkg/semantic/testdata/types/fn_call_wrong_arity.snow.want => pkg/semantic/testdata/types/fn_call_wrong_arity.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_call_wrong_arity.snow [0, 2, 0]
file testdata/fn_call_wrong_arity.snow [0, 2, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_compare.snow.want => pkg/semantic/testdata/types/fn_compare.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_compare.snow [0, 1, 0]
file testdata/fn_compare.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [2]
      var= x [var: int]

M pkg/semantic/testdata/types/fn_complex_selectors.snow.want => pkg/semantic/testdata/types/fn_complex_selectors.snow.want +3 -3
@@ 1,4 1,4 @@
file testdata/fn_complex_selectors.snow [0, 2, 1]
file testdata/fn_complex_selectors.snow [0, 2, 1, 0]
  fn create [let: () -> struct S]
    ident S [type: struct S]
    block [2]


@@ 36,12 36,12 @@ file testdata/fn_complex_selectors.snow [0, 2, 1]
                  ident s2 [var: struct T]
                ident do [let: () -> (int, () -> int)]
            ident 1 [value: () -> int]
  struct S [2, 0, 1] [type: struct S]
  struct S [2, 0, 1, 0] [type: struct S]
    var: s1 [var: int]
      ident int [type: int]
    var: s2 [var: struct T]
      ident T [type: struct T]
    struct T [1, 1, 0] [type: struct T]
    struct T [1, 1, 0, 0] [type: struct T]
      var: t1 [var: string]
        ident string [type: string]
      fn do [let: () -> (int, () -> int)]

M pkg/semantic/testdata/types/fn_duplicate_param_name.snow.want => pkg/semantic/testdata/types/fn_duplicate_param_name.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_duplicate_param_name.snow [0, 1, 0]
file testdata/fn_duplicate_param_name.snow [0, 1, 0, 0]
  fn dup [let: (int, string) -> void]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_explicit_void.snow.want => pkg/semantic/testdata/types/fn_explicit_void.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_explicit_void.snow [0, 3, 0]
file testdata/fn_explicit_void.snow [0, 3, 0, 0]
  fn do_nothing [let: () -> void]
    ident void [type: void]
    block [1]

M pkg/semantic/testdata/types/fn_extern_pkg_before_conflict_name.snow.want => pkg/semantic/testdata/types/fn_extern_pkg_before_conflict_name.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_extern_pkg_before_conflict_name.snow [0, 1, 0]
file testdata/fn_extern_pkg_before_conflict_name.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [4]
      fn print [let: (int) -> void]

M pkg/semantic/testdata/types/fn_extern_pkg_conflict_name.snow.want => pkg/semantic/testdata/types/fn_extern_pkg_conflict_name.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_extern_pkg_conflict_name.snow [0, 1, 0]
file testdata/fn_extern_pkg_conflict_name.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [4]
      var: fmt [var: int]

M pkg/semantic/testdata/types/fn_extern_ref_method.snow.want => pkg/semantic/testdata/types/fn_extern_ref_method.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/fn_extern_ref_method.snow [0, 1, 0]
file testdata/fn_extern_ref_method.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [1]
      struct S [0, 1, 0] [type: struct S]
      struct S [0, 1, 0, 0] [type: struct S]
        ref fn f [let: () -> void]
          @ [import, symbol] [2] [value: struct extern]
            ident extern [type: struct extern]

M pkg/semantic/testdata/types/fn_extern_with_body.snow.want => pkg/semantic/testdata/types/fn_extern_with_body.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_extern_with_body.snow [0, 1, 0]
file testdata/fn_extern_with_body.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    @ [import, symbol] [2] [value: struct extern]
      ident extern [type: struct extern]

M pkg/semantic/testdata/types/fn_fn_arg.snow.want => pkg/semantic/testdata/types/fn_fn_arg.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_fn_arg.snow [0, 3, 0]
file testdata/fn_fn_arg.snow [0, 3, 0, 0]
  fn do [let: (int, (int) -> int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_generic_decl_after_inst.snow.want => pkg/semantic/testdata/types/fn_generic_decl_after_inst.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_generic_decl_after_inst.snow [0, 2, 0]
file testdata/fn_generic_decl_after_inst.snow [0, 2, 0, 0]
  fn main [let: () -> void]
    block [1]
      let= a [let: int]

M pkg/semantic/testdata/types/fn_generic_fn_uses_generic_fn.snow.want => pkg/semantic/testdata/types/fn_generic_fn_uses_generic_fn.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_generic_fn_uses_generic_fn.snow [0, 3, 0]
file testdata/fn_generic_fn_uses_generic_fn.snow [0, 3, 0, 0]
  fn A [$1] [let: ($T) -> $T]
    generic type $T [type: $T]
    let: v [let: $T]

M pkg/semantic/testdata/types/fn_generic_identity.snow.want => pkg/semantic/testdata/types/fn_generic_identity.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_generic_identity.snow [0, 5, 0]
file testdata/fn_generic_identity.snow [0, 5, 0, 0]
  fn id [$1] [let: ($T) -> $T]
    generic type $T [type: $T]
    let: v [let: $T]

M pkg/semantic/testdata/types/fn_generic_unused_in_signature.snow.want => pkg/semantic/testdata/types/fn_generic_unused_in_signature.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_generic_unused_in_signature.snow [0, 6, 0]
file testdata/fn_generic_unused_in_signature.snow [0, 6, 0, 0]
  fn g1 [$2] [let: (int) -> int]
    generic type $T [type: $T]
    generic type $U [type: $U]

M pkg/semantic/testdata/types/fn_guard_fallthrough.snow.want => pkg/semantic/testdata/types/fn_guard_fallthrough.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_guard_fallthrough.snow [0, 1, 0]
file testdata/fn_guard_fallthrough.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      var: x [var: bool]

M pkg/semantic/testdata/types/fn_ident_as_type.snow.want => pkg/semantic/testdata/types/fn_ident_as_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_ident_as_type.snow [1, 1, 0]
file testdata/fn_ident_as_type.snow [1, 1, 0, 0]
  var: x [var: () -> void]
    ident test [let: () -> void]
  fn test [let: () -> void]

M pkg/semantic/testdata/types/fn_init_order.snow.want => pkg/semantic/testdata/types/fn_init_order.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_init_order.snow [0, 1, 0]
file testdata/fn_init_order.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [2]
      var= A [var: unresolved]

M pkg/semantic/testdata/types/fn_invalid_attr.snow.want => pkg/semantic/testdata/types/fn_invalid_attr.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_attr.snow [0, 1, 0]
file testdata/fn_invalid_attr.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    @ [x] [1] [value: unresolved]
      ident invalid [invalid: unresolved]

M pkg/semantic/testdata/types/fn_invalid_extern_fields.snow.want => pkg/semantic/testdata/types/fn_invalid_extern_fields.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_extern_fields.snow [0, 3, 0]
file testdata/fn_invalid_extern_fields.snow [0, 3, 0, 0]
  fn test1 [let: () -> void]
    @ [badField] [1] [value: struct extern]
      ident extern [type: struct extern]

M pkg/semantic/testdata/types/fn_invalid_generic_use_in_fn.snow.want => pkg/semantic/testdata/types/fn_invalid_generic_use_in_fn.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_generic_use_in_fn.snow [0, 1, 0]
file testdata/fn_invalid_generic_use_in_fn.snow [0, 1, 0, 0]
  fn g [$2] [let: ($T, $U) -> void]
    generic type $T [type: $T]
    generic type $U [type: $U]

M pkg/semantic/testdata/types/fn_invalid_main.snow.want => pkg/semantic/testdata/types/fn_invalid_main.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_main.snow [0, 1, 0]
file testdata/fn_invalid_main.snow [0, 1, 0, 0]
  fn main [let: (int) -> string]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_invalid_ref.snow.want => pkg/semantic/testdata/types/fn_invalid_ref.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_ref.snow [0, 1, 0]
file testdata/fn_invalid_ref.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [1]
      ref fn test [let: () -> void]

M pkg/semantic/testdata/types/fn_invalid_ref_call.snow.want => pkg/semantic/testdata/types/fn_invalid_ref_call.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/fn_invalid_ref_call.snow [0, 1, 0]
file testdata/fn_invalid_ref_call.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      struct S [1, 1, 0] [type: struct S]
      struct S [1, 1, 0, 0] [type: struct S]
        var: x [var: int]
          ident int [type: int]
        ref fn set [let: (int) -> void]

M pkg/semantic/testdata/types/fn_invalid_ref_call_via_value.snow.want => pkg/semantic/testdata/types/fn_invalid_ref_call_via_value.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/fn_invalid_ref_call_via_value.snow [0, 1, 0]
file testdata/fn_invalid_ref_call_via_value.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      struct S [1, 1, 0] [type: struct S]
      struct S [1, 1, 0, 0] [type: struct S]
        var: x [var: int]
          ident int [type: int]
        ref fn set [let: (int) -> void]

M pkg/semantic/testdata/types/fn_invalid_return.snow.want => pkg/semantic/testdata/types/fn_invalid_return.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_return.snow [0, 1, 0]
file testdata/fn_invalid_return.snow [0, 1, 0, 0]
  fn test [let: () -> uint]
    ident uint [type: uint]
    block [1]

M pkg/semantic/testdata/types/fn_invalid_tuple_access.snow.want => pkg/semantic/testdata/types/fn_invalid_tuple_access.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_invalid_tuple_access.snow [0, 1, 0]
file testdata/fn_invalid_tuple_access.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      var: x [var: (int, string, (bool, uint))]

M pkg/semantic/testdata/types/fn_main_extern.snow.want => pkg/semantic/testdata/types/fn_main_extern.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_main_extern.snow [0, 1, 0]
file testdata/fn_main_extern.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    @ [import, symbol] [2] [value: struct extern]
      ident extern [type: struct extern]

M pkg/semantic/testdata/types/fn_many_extern.snow.want => pkg/semantic/testdata/types/fn_many_extern.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_many_extern.snow [0, 1, 0]
file testdata/fn_many_extern.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    @ [import, symbol] [2] [value: struct extern]
      ident extern [type: struct extern]

M pkg/semantic/testdata/types/fn_method_explicit_self.snow.want => pkg/semantic/testdata/types/fn_method_explicit_self.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_method_explicit_self.snow [0, 1, 1]
file testdata/fn_method_explicit_self.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [2]
      var: s [var: struct S]


@@ 8,7 8,7 @@ file testdata/fn_method_explicit_self.snow [0, 1, 1]
          select [let: () -> int]
            ident s [var: struct S]
            ident getX [let: () -> int]
  struct S [1, 1, 0] [type: struct S]
  struct S [1, 1, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    fn getX [let: () -> int]

M pkg/semantic/testdata/types/fn_multi_vars_per_decl.snow.want => pkg/semantic/testdata/types/fn_multi_vars_per_decl.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_multi_vars_per_decl.snow [0, 1, 0]
file testdata/fn_multi_vars_per_decl.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      var:= x [var: int]

M pkg/semantic/testdata/types/fn_nested_block.snow.want => pkg/semantic/testdata/types/fn_nested_block.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_block.snow [0, 1, 0]
file testdata/fn_nested_block.snow [0, 1, 0, 0]
  fn test [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_nested_fn.snow.want => pkg/semantic/testdata/types/fn_nested_fn.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_fn.snow [0, 1, 0]
file testdata/fn_nested_fn.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [4]
      fn add [let: (int, int) -> int]

M pkg/semantic/testdata/types/fn_nested_fn_init_order.snow.want => pkg/semantic/testdata/types/fn_nested_fn_init_order.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_fn_init_order.snow [0, 1, 0]
file testdata/fn_nested_fn_init_order.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [3]
      fn A [let: () -> void]

M pkg/semantic/testdata/types/fn_nested_generic_fn.snow.want => pkg/semantic/testdata/types/fn_nested_generic_fn.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_generic_fn.snow [0, 3, 0]
file testdata/fn_nested_generic_fn.snow [0, 3, 0, 0]
  fn call [let: ((bool) -> bool) -> bool]
    let: f [let: (bool) -> bool]
      sig [1->1] [type: (bool) -> bool]

M pkg/semantic/testdata/types/fn_nested_struct_method.snow.want => pkg/semantic/testdata/types/fn_nested_struct_method.snow.want +3 -3
@@ 1,7 1,7 @@
file testdata/fn_nested_struct_method.snow [0, 1, 0]
file testdata/fn_nested_struct_method.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [6]
      struct S [1, 1, 1] [type: struct S]
      struct S [1, 1, 1, 0] [type: struct S]
        var: x [var: string]
          ident string [type: string]
        ref fn init [let: () -> void]


@@ 9,7 9,7 @@ file testdata/fn_nested_struct_method.snow [0, 1, 0]
            assign
              ident x [var: string]
              string ["hello"] [const: string]
        struct T [1, 1, 0] [type: struct T]
        struct T [1, 1, 0, 0] [type: struct T]
          var: y [var: string]
            ident string [type: string]
          ref fn append [let: (string) -> void]

M pkg/semantic/testdata/types/fn_nested_struct_self.snow.want => pkg/semantic/testdata/types/fn_nested_struct_self.snow.want +3 -3
@@ 1,8 1,8 @@
file testdata/fn_nested_struct_self.snow [0, 0, 1]
  struct S [1, 0, 1] [type: struct S]
file testdata/fn_nested_struct_self.snow [0, 0, 1, 0]
  struct S [1, 0, 1, 0] [type: struct S]
    var: x [var: string]
      ident string [type: string]
    struct T [1, 1, 0] [type: struct T]
    struct T [1, 1, 0, 0] [type: struct T]
      var: x [var: int]
        ident int [type: int]
      fn negate [let: () -> int]

M pkg/semantic/testdata/types/fn_nested_structs.snow.want => pkg/semantic/testdata/types/fn_nested_structs.snow.want +3 -3
@@ 1,10 1,10 @@
file testdata/fn_nested_structs.snow [0, 1, 0]
file testdata/fn_nested_structs.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      struct Outer [1, 0, 1] [type: struct Outer]
      struct Outer [1, 0, 1, 0] [type: struct Outer]
        let: x [let: struct Inner]
          ident Inner [type: struct Inner]
        struct Inner [1, 0, 0] [type: struct Inner]
        struct Inner [1, 0, 0, 0] [type: struct Inner]
          let: y [let: int]
            ident int [type: int]
      var: o [var: struct Outer]

M pkg/semantic/testdata/types/fn_nested_tuple_type.snow.want => pkg/semantic/testdata/types/fn_nested_tuple_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_nested_tuple_type.snow [0, 1, 0]
file testdata/fn_nested_tuple_type.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [1]
      var: x [var: (int, (bool, string))]

M pkg/semantic/testdata/types/fn_non_type_selectors.snow.want => pkg/semantic/testdata/types/fn_non_type_selectors.snow.want +3 -3
@@ 1,4 1,4 @@
file testdata/fn_non_type_selectors.snow [2, 1, 1]
file testdata/fn_non_type_selectors.snow [2, 1, 1, 0]
  var: x [var: int]
    ident int [type: int]
  let: y [let: string]


@@ 40,9 40,9 @@ file testdata/fn_non_type_selectors.snow [2, 1, 1]
              ident S [type: struct S]
              ident T [type: struct T]
            ident tt [var: int]
  struct S [1, 0, 1] [type: struct S]
  struct S [1, 0, 1, 0] [type: struct S]
    var: ss [var: int]
      ident int [type: int]
    struct T [1, 0, 0] [type: struct T]
    struct T [1, 0, 0, 0] [type: struct T]
      var: tt [var: int]
        ident int [type: int]

M pkg/semantic/testdata/types/fn_param_type_is_var_in_body.snow.want => pkg/semantic/testdata/types/fn_param_type_is_var_in_body.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_param_type_is_var_in_body.snow [0, 1, 0]
file testdata/fn_param_type_is_var_in_body.snow [0, 1, 0, 0]
  fn test [let: (int) -> void]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_params.snow.want => pkg/semantic/testdata/types/fn_params.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_params.snow [0, 1, 0]
file testdata/fn_params.snow [0, 1, 0, 0]
  fn test [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_params_locals.snow.want => pkg/semantic/testdata/types/fn_params_locals.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_params_locals.snow [0, 1, 0]
file testdata/fn_params_locals.snow [0, 1, 0, 0]
  fn test [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_recursion.snow.want => pkg/semantic/testdata/types/fn_recursion.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_recursion.snow [0, 1, 0]
file testdata/fn_recursion.snow [0, 1, 0, 0]
  fn test [let: (int) -> int]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_ref_on_fn_nested_in_method.snow.want => pkg/semantic/testdata/types/fn_ref_on_fn_nested_in_method.snow.want +2 -2
@@ 1,5 1,5 @@
file testdata/fn_ref_on_fn_nested_in_method.snow [0, 0, 1]
  struct S [1, 1, 0] [type: struct S]
file testdata/fn_ref_on_fn_nested_in_method.snow [0, 0, 1, 0]
  struct S [1, 1, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    ref fn rf [let: () -> void]

M pkg/semantic/testdata/types/fn_return_internal_struct.snow.want => pkg/semantic/testdata/types/fn_return_internal_struct.snow.want +2 -2
@@ 1,8 1,8 @@
file testdata/fn_return_internal_struct.snow [0, 1, 0]
file testdata/fn_return_internal_struct.snow [0, 1, 0, 0]
  fn test [let: () -> unresolved]
    ident S [invalid: unresolved]
    block [3]
      struct S [0, 0, 0] [type: struct S]
      struct S [0, 0, 0, 0] [type: struct S]
      var: s [var: struct S]
        ident S [type: struct S]
      return

M pkg/semantic/testdata/types/fn_return_missing_value.snow.want => pkg/semantic/testdata/types/fn_return_missing_value.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_return_missing_value.snow [0, 1, 0]
file testdata/fn_return_missing_value.snow [0, 1, 0, 0]
  fn test [let: () -> int]
    ident int [type: int]
    block [1]

M pkg/semantic/testdata/types/fn_return_struct.snow.want => pkg/semantic/testdata/types/fn_return_struct.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_return_struct.snow [0, 2, 1]
file testdata/fn_return_struct.snow [0, 2, 1, 0]
  fn newS [let: () -> struct S]
    ident S [type: struct S]
    block [2]


@@ 42,7 42,7 @@ file testdata/fn_return_struct.snow [0, 2, 1]
            ident newS [let: () -> struct S]
          ident z [let: () -> void]
        ident test [let: () -> void]
  struct S [2, 1, 0] [type: struct S]
  struct S [2, 1, 0, 0] [type: struct S]
    let: x [let: int]
      ident int [type: int]
    var: y [var: int]

M pkg/semantic/testdata/types/fn_return_unifying_type.snow.want => pkg/semantic/testdata/types/fn_return_unifying_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_return_unifying_type.snow [0, 1, 0]
file testdata/fn_return_unifying_type.snow [0, 1, 0, 0]
  fn test [let: () -> i16]
    ident i16 [type: i16]
    block [2]

M pkg/semantic/testdata/types/fn_struct_main_method.snow.want => pkg/semantic/testdata/types/fn_struct_main_method.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/fn_struct_main_method.snow [0, 1, 1]
file testdata/fn_struct_main_method.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [0]
  struct S [0, 1, 0] [type: struct S]
  struct S [0, 1, 0, 0] [type: struct S]
    fn main [let: (int) -> void]
      let: x [let: int]
        ident int [type: int]

M pkg/semantic/testdata/types/fn_struct_method_access_top_level.snow.want => pkg/semantic/testdata/types/fn_struct_method_access_top_level.snow.want +2 -2
@@ 1,9 1,9 @@
file testdata/fn_struct_method_access_top_level.snow [1, 1, 1]
file testdata/fn_struct_method_access_top_level.snow [1, 1, 1, 0]
  var: x [var: int]
    ident int [type: int]
  fn main [let: () -> void]
    block [0]
  struct S [0, 1, 0] [type: struct S]
  struct S [0, 1, 0, 0] [type: struct S]
    fn get [let: () -> int]
      ident int [type: int]
      block [1]

M pkg/semantic/testdata/types/fn_struct_order_independent.snow.want => pkg/semantic/testdata/types/fn_struct_order_independent.snow.want +2 -2
@@ 1,5 1,5 @@
file testdata/fn_struct_order_independent.snow [0, 0, 1]
  struct S [2, 1, 0] [type: struct S]
file testdata/fn_struct_order_independent.snow [0, 0, 1, 0]
  struct S [2, 1, 0, 0] [type: struct S]
    var: x [var: int]
      ident int [type: int]
    let: y [let: int]

M pkg/semantic/testdata/types/fn_struct_same_name_diff_scope.snow.want => pkg/semantic/testdata/types/fn_struct_same_name_diff_scope.snow.want +3 -3
@@ 1,11 1,11 @@
file testdata/fn_struct_same_name_diff_scope.snow [0, 1, 0]
file testdata/fn_struct_same_name_diff_scope.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      struct A [0, 0, 0] [type: struct A]
      struct A [0, 0, 0, 0] [type: struct A]
      var: a [var: struct A]
        ident A [type: struct A]
      block [3]
        struct A [0, 0, 0] [type: struct A]
        struct A [0, 0, 0, 0] [type: struct A]
        var: b [var: struct A]
          ident A [type: struct A]
        assign

M pkg/semantic/testdata/types/fn_struct_selector.snow.want => pkg/semantic/testdata/types/fn_struct_selector.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/fn_struct_selector.snow [0, 1, 1]
file testdata/fn_struct_selector.snow [0, 1, 1, 0]
  fn test [let: () -> void]
    block [2]
      var: p [var: struct Point]


@@ 7,6 7,6 @@ file testdata/fn_struct_selector.snow [0, 1, 1]
        select [let: int]
          ident p [var: struct Point]
          ident x [let: int]
  struct Point [1, 0, 0] [type: struct Point]
  struct Point [1, 0, 0, 0] [type: struct Point]
    let: x [let: int]
      ident int [type: int]

M pkg/semantic/testdata/types/fn_struct_self_shadow.snow.want => pkg/semantic/testdata/types/fn_struct_self_shadow.snow.want +2 -2
@@ 1,5 1,5 @@
file testdata/fn_struct_self_shadow.snow [0, 0, 1]
  struct S [1, 1, 0] [type: struct S]
file testdata/fn_struct_self_shadow.snow [0, 0, 1, 0]
  struct S [1, 1, 0, 0] [type: struct S]
    var: self [var: int]
      ident int [type: int]
    fn get [let: () -> int]

M pkg/semantic/testdata/types/fn_struct_self_uses.snow.want => pkg/semantic/testdata/types/fn_struct_self_uses.snow.want +2 -2
@@ 1,5 1,5 @@
file testdata/fn_struct_self_uses.snow [0, 0, 1]
  struct S [0, 1, 0] [type: struct S]
file testdata/fn_struct_self_uses.snow [0, 0, 1, 0]
  struct S [0, 1, 0, 0] [type: struct S]
    fn set [let: () -> void]
      block [1]
        var: self [var: int]

M pkg/semantic/testdata/types/fn_tuple_assign_compatible_types.snow.want => pkg/semantic/testdata/types/fn_tuple_assign_compatible_types.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_tuple_assign_compatible_types.snow [0, 1, 0]
file testdata/fn_tuple_assign_compatible_types.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [4]
      var: i [var: i16]

M pkg/semantic/testdata/types/fn_tuple_assign_incompatible_types.snow.want => pkg/semantic/testdata/types/fn_tuple_assign_incompatible_types.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_tuple_assign_incompatible_types.snow [0, 1, 0]
file testdata/fn_tuple_assign_incompatible_types.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [4]
      var: t [var: (i32, u16, bool)]

M pkg/semantic/testdata/types/fn_tuple_expr_select_field.snow.want => pkg/semantic/testdata/types/fn_tuple_expr_select_field.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_tuple_expr_select_field.snow [0, 1, 0]
file testdata/fn_tuple_expr_select_field.snow [0, 1, 0, 0]
  fn main [let: () -> void]
    block [4]
      var= t1 [var: (int, int, int)]

M pkg/semantic/testdata/types/fn_type_as_value.snow.want => pkg/semantic/testdata/types/fn_type_as_value.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_type_as_value.snow [0, 1, 0]
file testdata/fn_type_as_value.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [1]
      let= res [let: int]

M pkg/semantic/testdata/types/fn_unknown_symbol.snow.want => pkg/semantic/testdata/types/fn_unknown_symbol.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_unknown_symbol.snow [0, 1, 0]
file testdata/fn_unknown_symbol.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [1]
      expr

M pkg/semantic/testdata/types/fn_var_as_param_type.snow.want => pkg/semantic/testdata/types/fn_var_as_param_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fn_var_as_param_type.snow [3, 1, 0]
file testdata/fn_var_as_param_type.snow [3, 1, 0, 0]
  var: x [var: int]
    ident int [type: int]
  var: f [var: (int) -> void]

M pkg/semantic/testdata/types/fn_without_body.snow.want => pkg/semantic/testdata/types/fn_without_body.snow.want +1 -1
@@ 1,2 1,2 @@
file testdata/fn_without_body.snow [0, 1, 0]
file testdata/fn_without_body.snow [0, 1, 0, 0]
  fn test [let: () -> void]

M pkg/semantic/testdata/types/fns.snow.want => pkg/semantic/testdata/types/fns.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/fns.snow [0, 3, 0]
file testdata/fns.snow [0, 3, 0, 0]
  fn add [let: (int, int) -> int]
    let: x [let: int]
      ident int [type: int]

A pkg/semantic/testdata/types/generic_interface.snow.err => pkg/semantic/testdata/types/generic_interface.snow.err +0 -0

A pkg/semantic/testdata/types/generic_interface.snow.want => pkg/semantic/testdata/types/generic_interface.snow.want +9 -0
@@ 0,0 1,9 @@
file testdata/generic_interface.snow [0, 0, 0, 1]
  interface I [2, $2] [type: interface I]
    generic type $T [type: $T]
    generic type $U [type: $U]
    fn get_t [let: () -> $T]
      ident $T [type: $T]
    ref fn set_u [let: ($U) -> void]
      let: u [let: $U]
        ident $U [type: $U]

M pkg/semantic/testdata/types/generic_struct_instantiation.snow.want => pkg/semantic/testdata/types/generic_struct_instantiation.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/generic_struct_instantiation.snow [0, 1, 1]
file testdata/generic_struct_instantiation.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [2]
      let= g1 [let: struct G[int]]


@@ 11,7 11,7 @@ file testdata/generic_struct_instantiation.snow [0, 1, 1]
        generic inst [1] [type: struct G[string]]
          ident G [type: struct G]
          ident string [type: string]
  struct G [1, 0, 0, $1] [type: struct G]
  struct G [1, 0, 0, 0, $1] [type: struct G]
    generic type $T [type: $T]
    var: x [var: $T]
      ident $T [type: $T]

M pkg/semantic/testdata/types/guard_else.snow.want => pkg/semantic/testdata/types/guard_else.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/guard_else.snow [0, 1, 0]
file testdata/guard_else.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      var= x [var: bool]

M pkg/semantic/testdata/types/if_else_if.snow.want => pkg/semantic/testdata/types/if_else_if.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/if_else_if.snow [0, 1, 0]
file testdata/if_else_if.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [3]
      var= x [var: bool]

M pkg/semantic/testdata/types/if_non_bool.snow.want => pkg/semantic/testdata/types/if_non_bool.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/if_non_bool.snow [0, 1, 0]
file testdata/if_non_bool.snow [0, 1, 0, 0]
  fn test [let: () -> void]
    block [2]
      var= x [var: int]

M pkg/semantic/testdata/types/interface.snow.want => pkg/semantic/testdata/types/interface.snow.want +1 -1
@@ 1,3 1,3 @@
file testdata/interface.snow [0, 0, 0]
file testdata/interface.snow [0, 0, 0, 1]
  interface I [1] [type: interface I]
    fn foo [let: () -> void]

M pkg/semantic/testdata/types/invalid_binary_op.snow.want => pkg/semantic/testdata/types/invalid_binary_op.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/invalid_binary_op.snow [3, 0, 0]
file testdata/invalid_binary_op.snow [3, 0, 0, 0]
  var= x [var: int]
    int [3] [const: int]
  var= y [var: string]

M pkg/semantic/testdata/types/let.snow.want => pkg/semantic/testdata/types/let.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/let.snow [1, 0, 0]
file testdata/let.snow [1, 0, 0, 0]
  let:= y [let: string]
    ident string [type: string]
    string ["abc"] [const: string]

M pkg/semantic/testdata/types/let_invalid_tuple_type.snow.want => pkg/semantic/testdata/types/let_invalid_tuple_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/let_invalid_tuple_type.snow [1, 0, 0]
file testdata/let_invalid_tuple_type.snow [1, 0, 0, 0]
  let: x [let: (int, bool)]
    tuple type [2] [type: (int, bool)]
      ident int [type: int]

M pkg/semantic/testdata/types/let_invalid_unary.snow.want => pkg/semantic/testdata/types/let_invalid_unary.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/let_invalid_unary.snow [1, 0, 0]
file testdata/let_invalid_unary.snow [1, 0, 0, 0]
  let= x [let: unresolved]
    unary [!] [value: unresolved]
      string ["a"] [const: string]

M pkg/semantic/testdata/types/let_unary.snow.want => pkg/semantic/testdata/types/let_unary.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/let_unary.snow [1, 0, 0]
file testdata/let_unary.snow [1, 0, 0, 0]
  let= x [let: int]
    unary [-] [value: int]
      int [1] [const: int]

M pkg/semantic/testdata/types/paren_type.snow.want => pkg/semantic/testdata/types/paren_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/paren_type.snow [1, 0, 0]
file testdata/paren_type.snow [1, 0, 0, 0]
  var:= x [var: int]
    paren [type: int]
      ident int [type: int]

M pkg/semantic/testdata/types/struct_complex_generic.snow.want => pkg/semantic/testdata/types/struct_complex_generic.snow.want +3 -3
@@ 1,4 1,4 @@
file testdata/struct_complex_generic.snow [0, 3, 1]
file testdata/struct_complex_generic.snow [0, 3, 1, 0]
  fn str [let: (string) -> string]
    let: s [let: string]
      ident string [type: string]


@@ 29,7 29,7 @@ file testdata/struct_complex_generic.snow [0, 3, 1]
                ident string [type: string]
            ident str [let: (string) -> string]
          ident integer [let: (int) -> int]
  struct A [2, 0, 1, $2] [type: struct A]
  struct A [2, 0, 1, 0, $2] [type: struct A]
    generic type $T [type: $T]
    generic type $U [type: $U]
    var: bb [var: struct B[$U]]


@@ 40,7 40,7 @@ file testdata/struct_complex_generic.snow [0, 3, 1]
      sig [1->1] [type: ($T) -> $T]
        ident $T [type: $T]
        ident $T [type: $T]
    struct B [1, 0, 0, $1] [type: struct B]
    struct B [1, 0, 0, 0, $1] [type: struct B]
      generic type $V [type: $V]
      var: ffb [var: ($V) -> $V]
        sig [1->1] [type: ($V) -> $V]

M pkg/semantic/testdata/types/struct_generic.snow.want => pkg/semantic/testdata/types/struct_generic.snow.want +5 -5
@@ 1,5 1,5 @@
file testdata/struct_generic.snow [0, 0, 4]
  struct A [2, 1, 0] [type: struct A]
file testdata/struct_generic.snow [0, 0, 4, 0]
  struct A [2, 1, 0, 0] [type: struct A]
    var: x [var: unresolved]
      ident $T [invalid: unresolved]
    let: y [let: unresolved]


@@ 14,7 14,7 @@ file testdata/struct_generic.snow [0, 0, 4]
          block [1]
            let: c [let: unresolved]
              ident $W [invalid: unresolved]
  struct B [1, 1, 0, $3] [type: struct B]
  struct B [1, 1, 0, 0, $3] [type: struct B]
    generic type $T [type: $T]
    generic type $U [type: $U]
    generic type $V [type: $V]


@@ 26,7 26,7 @@ file testdata/struct_generic.snow [0, 0, 4]
      block [1]
        var: z [var: $U]
          ident $U [type: $U]
  struct C [2, 0, 0, $3] [type: struct C]
  struct C [2, 0, 0, 0, $3] [type: struct C]
    generic type $T [type: $T]
    generic type $U [type: $U]
    generic type $T [type: $T]


@@ 34,7 34,7 @@ file testdata/struct_generic.snow [0, 0, 4]
      ident $T [type: $T]
    let: y [let: $U]
      ident $U [type: $U]
  struct D [3, 0, 0, $2] [type: struct D]
  struct D [3, 0, 0, 0, $2] [type: struct D]
    generic type $T [type: $T]
    generic type $U [type: $U]
    var: v [var: $T]

M pkg/semantic/testdata/types/struct_simple_generic.snow.want => pkg/semantic/testdata/types/struct_simple_generic.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/struct_simple_generic.snow [0, 2, 1]
file testdata/struct_simple_generic.snow [0, 2, 1, 0]
  fn main [let: () -> void]
    block [2]
      let= a [let: struct A[int]]


@@ 20,7 20,7 @@ file testdata/struct_simple_generic.snow [0, 2, 1]
      string ["Println"] [const: string]
    let: i [let: int]
      ident int [type: int]
  struct A [1, 0, 0, $1] [type: struct A]
  struct A [1, 0, 0, 0, $1] [type: struct A]
    generic type $T [type: $T]
    var: x [var: $T]
      ident $T [type: $T]

M pkg/semantic/testdata/types/struct_var_expr_call_method.snow.want => pkg/semantic/testdata/types/struct_var_expr_call_method.snow.want +2 -2
@@ 1,7 1,7 @@
file testdata/struct_var_expr_call_method.snow [0, 1, 1]
file testdata/struct_var_expr_call_method.snow [0, 1, 1, 0]
  fn main [let: () -> void]
    block [0]
  struct S [3, 2, 0] [type: struct S]
  struct S [3, 2, 0, 0] [type: struct S]
    var:= x [var: int]
      ident int [type: int]
      call [0] [value: int]

M pkg/semantic/testdata/types/top_level_fn_init_order.snow.want => pkg/semantic/testdata/types/top_level_fn_init_order.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/top_level_fn_init_order.snow [0, 2, 0]
file testdata/top_level_fn_init_order.snow [0, 2, 0, 0]
  fn A [let: () -> void]
    block [1]
      expr

M pkg/semantic/testdata/types/top_level_init_order.snow.want => pkg/semantic/testdata/types/top_level_init_order.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/top_level_init_order.snow [2, 0, 0]
file testdata/top_level_init_order.snow [2, 0, 0, 0]
  var= A [var: int]
    ident B [let: int]
  let= B [let: int]

M pkg/semantic/testdata/types/tuple_as_struct_generic.snow.want => pkg/semantic/testdata/types/tuple_as_struct_generic.snow.want +2 -2
@@ 1,4 1,4 @@
file testdata/tuple_as_struct_generic.snow [0, 2, 1]
file testdata/tuple_as_struct_generic.snow [0, 2, 1, 0]
  fn main [let: () -> void]
    block [2]
      let:= s [let: struct S[(int, bool, string)]]


@@ 34,7 34,7 @@ file testdata/tuple_as_struct_generic.snow [0, 2, 1]
      string ["Println"] [const: string]
    let: v [let: string]
      ident string [type: string]
  struct S [1, 0, 0, $1] [type: struct S]
  struct S [1, 0, 0, 0, $1] [type: struct S]
    generic type $T [type: $T]
    let: t [let: $T]
      ident $T [type: $T]

M pkg/semantic/testdata/types/var.snow.want => pkg/semantic/testdata/types/var.snow.want +1 -1
@@ 1,3 1,3 @@
file testdata/var.snow [1, 0, 0]
file testdata/var.snow [1, 0, 0, 0]
  var: x [var: int]
    ident int [type: int]

M pkg/semantic/testdata/types/var_auto_ref.snow.want => pkg/semantic/testdata/types/var_auto_ref.snow.want +1 -1
@@ 1,3 1,3 @@
file testdata/var_auto_ref.snow [1, 0, 0]
file testdata/var_auto_ref.snow [1, 0, 0, 0]
  var= x [var: unresolved]
    ident x [var: unresolved]

M pkg/semantic/testdata/types/var_bool.snow.want => pkg/semantic/testdata/types/var_bool.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/var_bool.snow [2, 0, 0]
file testdata/var_bool.snow [2, 0, 0, 0]
  var= t [var: bool]
    ident true [let: bool]
  var= f [var: bool]

M pkg/semantic/testdata/types/var_duplicate_symbol.snow.want => pkg/semantic/testdata/types/var_duplicate_symbol.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/var_duplicate_symbol.snow [2, 0, 0]
file testdata/var_duplicate_symbol.snow [2, 0, 0, 0]
  var: x [var: int]
    ident int [type: int]
  var: x [var: string]

M pkg/semantic/testdata/types/var_tuple_type.snow.want => pkg/semantic/testdata/types/var_tuple_type.snow.want +1 -1
@@ 1,4 1,4 @@
file testdata/var_tuple_type.snow [1, 0, 0]
file testdata/var_tuple_type.snow [1, 0, 0, 0]
  var: x [var: (int, string, bool)]
    tuple type [3] [type: (int, string, bool)]
      ident int [type: int]