Type check errors

This commit is contained in:
Scarlett
2025-04-16 16:30:58 -04:00
parent 5a23ef2756
commit c72e7a2a28
6 changed files with 128 additions and 89 deletions

View File

@ -28,7 +28,7 @@ entry (arg) := {
w := reserve w; (* see types.alpha reserve returns a value of type address, which can be assigned to array and record variables*)
w.x := 5;
w.y := 7;
result := bar1(w); (* pass w (a rec type value) to bar1 *)
ressult := bar1(w); (* pass w (a rec type value) to bar1 *)
result := bar2(5,7); (* implicitly build a rec type value, assign 5 and 7 to fields x and y, but call them r and s *)
return 0;
}