From d27c0ff07c915db6b2c1c86a2e0b139bbb5fa85e Mon Sep 17 00:00:00 2001 From: Sasha Koshka Date: Mon, 15 Aug 2022 14:32:59 -0400 Subject: [PATCH] Added single digit zero and eight to lexer number test --- lexer/lexer_test.go | 4 ++++ tests/lexer/numbers.arf | 1 + 2 files changed, 5 insertions(+) diff --git a/lexer/lexer_test.go b/lexer/lexer_test.go index 1d1b175..4a6fc96 100644 --- a/lexer/lexer_test.go +++ b/lexer/lexer_test.go @@ -91,6 +91,10 @@ func TestTokenizeAll (test *testing.T) { func TestTokenizeNumbers (test *testing.T) { checkTokenSlice("../tests/lexer/numbers.arf", []Token { + Token { kind: TokenKindUInt, value: uint64(0) }, + Token { kind: TokenKindNewline }, + Token { kind: TokenKindUInt, value: uint64(5) }, + Token { kind: TokenKindNewline }, Token { kind: TokenKindUInt, value: uint64(83628266) }, Token { kind: TokenKindNewline }, Token { kind: TokenKindUInt, value: uint64(83628266) }, diff --git a/tests/lexer/numbers.arf b/tests/lexer/numbers.arf index 9e512ca..e0da9bb 100644 --- a/tests/lexer/numbers.arf +++ b/tests/lexer/numbers.arf @@ -1,4 +1,5 @@ :arf +0 83628266 0b100111111000001000011101010 0x4Fc10Ea