diff options
author | Clyne Sullivan <clyne@bitgloo.com> | 2024-06-15 08:04:15 -0400 |
---|---|---|
committer | Clyne Sullivan <clyne@bitgloo.com> | 2024-06-15 08:04:15 -0400 |
commit | 0ad40ced64ba5b2b83f7c9274efea1aa3677a534 (patch) | |
tree | d019d32a7919f52e4aa6897bfa279ed57ef7038f /parser.hpp | |
parent | 47d7c964d075f92b9ce657f1b946f5bd6895439b (diff) |
break code into separate files
Diffstat (limited to 'parser.hpp')
-rw-r--r-- | parser.hpp | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/parser.hpp b/parser.hpp new file mode 100644 index 0000000..962c984 --- /dev/null +++ b/parser.hpp @@ -0,0 +1,25 @@ +#ifndef FORSPLL_PARSER_HPP +#define FORSPLL_PARSER_HPP + +#include <string> +#include <string_view> +#include <tuple> + +enum class Token { + none, + ThunkOpen, + ThunkClose, + Quote, + PopVar, + PushVar, + Var, + Number +}; + +extern std::string name; + +std::pair<std::string_view, Token> nextToken(std::string_view sv); +void printToken(Token tok); + +#endif // FORSPLL_PARSER_HPP + |