Skip to content

Commit

Permalink
make room for reference counter
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew-johnson-4 committed Jan 1, 2024
1 parent 375b027 commit 72251b0
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions stdlib/untyped.lm
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,19 @@
# etc.

# struct S {
# $0 atom : *char
# $1 head : *S
# $2 tail : *S
# $3 misc : bool[64]
# $0 ref_counter : u64
# $1 atom : *char
# $2 head : *S
# $3 tail : *S
# $4 misc : bool[64]
# }

::yield-nil := λ_. (
\t mov $0, %rdi \n
\t mov $0, %rsi \n
\t mov $0, %rdx \n
\t mov $0, %r10 \n
# $_.$0 ref_counter is unnecessary when open
\t mov $0, %rdi \n # $_.$1 = 0
\t mov $0, %rsi \n # $_.$2 = 0
\t mov $0, %rdx \n # $_.$3 = 0
\t mov $0, %r10 \n # $_.$4 = 0
);

::print-$_ := λ_. (
Expand Down

0 comments on commit 72251b0

Please sign in to comment.