aboutsummaryrefslogtreecommitdiffstats
path: root/parser.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'parser.hpp')
-rw-r--r--parser.hpp25
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
+