summaryrefslogtreecommitdiff
path: root/Rakefile
diff options
context:
space:
mode:
authorEugen Wissner <belka@caraus.de>2026-05-13 22:52:07 +0200
committerEugen Wissner <belka@caraus.de>2026-05-13 22:52:07 +0200
commit1802aa21d8bdc3a363c6641a209bce263e8a63b0 (patch)
tree160664a2838364ef51fcd36a95061861e17ba2d1 /Rakefile
parenteaa7fc2ca250747e2a83858929d35320b6b054bc (diff)
downloadelna-1802aa21d8bdc3a363c6641a209bce263e8a63b0.tar.gz
Implement cast expressions
Diffstat (limited to 'Rakefile')
-rw-r--r--Rakefile15
1 files changed, 4 insertions, 11 deletions
diff --git a/Rakefile b/Rakefile
index 8b18106..499a70b 100644
--- a/Rakefile
+++ b/Rakefile
@@ -46,18 +46,11 @@ task :convert do
current_stage << <<~FUN
proc f();
var
- x: ElnaLocation;
- y: ElnaPosition;
+ x: ^ElnaLocation;
begin
- x.line := 5;
- x.column := 3;
- y.end_location := x;
-
- (* y.end_location.line := 5;
- y.end_location.column := 3;
- x := y.end_location; *)
-
- printf("# %i %i %i %i\\n\\0", x.line, x.column, y.end_location.line, y.end_location.column)
+ x := malloc(#size(ElnaLocation));
+ x^.line := 5;
+ x^.column := cast(3: Word)
end;
begin