Skip to content

Commit

Permalink
Merge pull request #761 from herd/asl-xor
Browse files Browse the repository at this point in the history
Added new XOR token to reflect change in LRM
  • Loading branch information
Roman-Manevich authored Jan 22, 2024
2 parents c366840 + 0496017 commit 5586dfe
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion asllib/Lexer.mll
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ let tr_name s = match s with
| "elsif" -> ELSIF
| "end" -> END
| "enumeration" -> ENUMERATION
| "EOR" -> EOR
| "EOR" | "XOR" -> EOR
| "exception" -> EXCEPTION
| "FALSE" -> BOOL_LIT false
| "for" -> FOR
Expand Down
7 changes: 7 additions & 0 deletions asllib/tests/ASLTypingReference.t/TypingRule.CheckBinOp.asl
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
func main() => integer
begin
var a: bits(10);
var b: bits(10);
var c: bits(10) = a XOR b; // Check that XOR operator is recognized by the lexer.
return 0;
end
1 change: 1 addition & 0 deletions asllib/tests/ASLTypingReference.t/run.t
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,4 @@ ASL Typing Reference:
0 arguments expected and 1 provided
[1]
// $ aslref TypingRule.EConcatUnresolvableToInteger.asl
$ aslref TypingRule.CheckBinOp.asl

0 comments on commit 5586dfe

Please sign in to comment.