Skip to content

Commit cad1963

Browse files
type correctness
1 parent 3321207 commit cad1963

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

include/basic/context.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
#pragma once
66
#include <stdint.h>
77
#include <stdbool.h>
8+
#include "tokenizer.h"
89
#include "buddy_allocator.h"
910

1011
typedef struct {
@@ -42,10 +43,9 @@ typedef struct basic_ctx {
4243
/**
4344
* @brief Current token type.
4445
*
45-
* A numeric representation of the token between `ptr` and `nextptr`. The value
46-
* should always be within the `token_t` enum.
46+
* A numeric representation of the token between `ptr` and `nextptr`.
4747
*/
48-
int current_token;
48+
enum token_t current_token;
4949

5050
/**
5151
* @brief Current line number in the program.
@@ -119,7 +119,7 @@ typedef struct basic_ctx {
119119
char string[MAX_STRINGLEN];
120120

121121
/**
122-
* Return types of the call stack
122+
* @brief Return types of the call stack
123123
*/
124124
ub_return_type fn_type_stack[MAX_CALL_STACK_DEPTH];
125125

@@ -174,7 +174,7 @@ typedef struct basic_ctx {
174174
uint64_t while_stack[MAX_LOOP_STACK_DEPTH];
175175

176176
/**
177-
* @brief Pointer indicating the current position in the repeat stack.
177+
* @brief Pointer indicating the current position in the while stack.
178178
*/
179179
uint64_t while_stack_ptr;
180180

0 commit comments

Comments
 (0)