summaryrefslogtreecommitdiff
path: root/parse/preproc.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'parse/preproc.hpp')
-rw-r--r--parse/preproc.hpp24
1 files changed, 24 insertions, 0 deletions
diff --git a/parse/preproc.hpp b/parse/preproc.hpp
new file mode 100644
index 00000000..827ce249
--- /dev/null
+++ b/parse/preproc.hpp
@@ -0,0 +1,24 @@
+#ifndef PREPROC_H
+#define PREPROC_H
+
+#include "lex.hpp"
+
+class Preproc:
+ public TokenStream
+{
+ Lexer m_lex;
+
+ bool m_cache_valid;
+ Token m_cache;
+
+public:
+ Preproc(::std::string path);
+ ~Preproc();
+
+ virtual Token getToken();
+ virtual void putback(Token tok);
+private:
+ Token getTokenInt();
+};
+
+#endif // PREPROC_H