Parser
- Added a TODO about a possible refactor to make things split out more - Implemented `setCursor(ulong)` so that we can update the position of the token pointer
This commit is contained in:
parent
03a998bae8
commit
37225c8484
|
@ -19,6 +19,7 @@ import tlang.compiler.parsing.exceptions;
|
|||
|
||||
bool isUnitTest;
|
||||
|
||||
// TODO: Technically we could make a core parser etc
|
||||
public final class Parser
|
||||
{
|
||||
/**
|
||||
|
@ -103,6 +104,11 @@ public final class Parser
|
|||
tokenPtr--;
|
||||
}
|
||||
|
||||
private void setCursor(ulong newPosition)
|
||||
{
|
||||
tokenPtr = newPosition;
|
||||
}
|
||||
|
||||
/**
|
||||
* Parses if statements
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue