fix: tests and implementation of lexer
Just a few details here and there, nothing wrong, everything else is going well.
This commit is contained in:
@@ -13,10 +13,8 @@ static void test_basic_evaluation(void** state) {
|
||||
(void) state;
|
||||
|
||||
char expr[256] = "2 + 4 * 40 / 2";
|
||||
ASTNodeArray context;
|
||||
|
||||
tokenize(expr, &context);
|
||||
ParseResult result = parse(&context);
|
||||
TokenizeResult tokens = tokenize(expr);
|
||||
ParseResult result = parse(tokens);
|
||||
int64_t value = evaluate(result);
|
||||
|
||||
assert_int_equal(value, 82);
|
||||
|
||||
Reference in New Issue
Block a user