diff options
Diffstat (limited to 'cpp.h')
-rw-r--r-- | cpp.h | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -3,6 +3,9 @@ #include "grammer.h" #include "minicc.h" +#include <any> +#include <deque> +#include <memory> #include <vector> struct CPPContext { @@ -43,8 +46,6 @@ private: std::vector<Token> m_tokens; // result of phase 7.a std::vector<Gram::TreeNode> m_nodes; // result of phase 7.b - CPPContext m_cpp_context; - std::string valueOfNode(index_t node_index) const; std::string typeOfNode(index_t node_index) const; std::string locationOfNode(index_t node_index) const; ///< Empty if no location available @@ -52,7 +53,9 @@ private: std::string typeOfChild(int32_t child_id) const; bool childTypesOfNodeMatch(index_t, const std::vector<std::string>& pattern) const; ///< returns true iff specified type list matches; "" -> don't care - void trTranslationUnit(index_t node_id); - void trDeclaration(index_t node_id); + std::deque<std::shared_ptr<std::any>> mValues; + void getValueOfToken(index_t index); + void getValueOfNode(index_t index); + void visitRecursive(index_t node_id); }; |