aboutsummaryrefslogtreecommitdiff
path: root/asm/lexer.hpp
AgeCommit message (Collapse)Author
2024-04-15lexer now produces a vector of heap allocated tokensAryadev Chavali
This removes the problem of possibly expensive copies occurring due to working with tokens produced from the lexer (that C++ just... does): now we hold pointers where the copy operator is a lot easier to use. I want expensive stuff to be done by me and for a reason: I want to be holding the shotgun.
2024-04-14enum -> enum class in lexerAryadev Chavali
This makes enum elements scoped which is actually quite useful as I prefer the namespacing that enum's give in C++.
2024-04-14Implemented tokenise_bufferAryadev Chavali
Note that this is basically the same as the previous version, excluding the fact that it uses C++ idioms more and does a bit better in error checking.
2024-04-14Wrote a new lexer API in C++Aryadev Chavali
Essentially a refactor of the C formed lexer into C++ style. I can already see some benefits from doing this, in particular speed of prototyping.