-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The implementation erroneously treated the trees as having only two child nodes, while they actually have three (type, operand a, operand b).
- Loading branch information
Showing
5 changed files
with
50 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
.type t0 (Int) | ||
.type t1 (Proc t0) | ||
.start t1 p0 | ||
LdImmInt 16 | ||
LdImmInt 48 | ||
BitAnd | ||
Ret | ||
.end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
discard """ | ||
output: "(Done 16)" | ||
""" | ||
(TypeDefs | ||
(Int 8) | ||
(ProcTy (Type 0))) | ||
(GlobalDefs) | ||
(ProcDefs | ||
(ProcDef (Type 1) (Locals) | ||
(Continuations | ||
(Continuation (Params) 0 | ||
(Continue 1 | ||
(BitAnd (Type 0) (IntVal 16) (IntVal 48)))) | ||
(Continuation (Params (Type 0)))))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
.type t0 (Int) | ||
.type t1 (Proc t0) | ||
.start t1 p0 | ||
LdImmInt 48 | ||
LdImmInt 40 | ||
BitOr | ||
Ret | ||
.end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
discard """ | ||
output: "(Done 56)" | ||
""" | ||
(TypeDefs | ||
(Int 8) | ||
(ProcTy (Type 0))) | ||
(GlobalDefs) | ||
(ProcDefs | ||
(ProcDef (Type 1) (Locals) | ||
(Continuations | ||
(Continuation (Params) 0 | ||
(Continue 1 | ||
(BitOr (Type 0) (IntVal 48) (IntVal 40)))) | ||
(Continuation (Params (Type 0)))))) |