#ifndef roza_STATICPASS_HPP #define roza_STATICPASS_HPP #include "commons.hpp" #include "StatusLog.hpp" #include "Node.hpp" #include "Type.hpp" #include "SymTable.hpp" namespace roza { class StaticPass { public: explicit StaticPass(StatusLog& log); explicit StaticPass(StatusLog& log, SymTable const& sym_table); virtual ~StaticPass(); void check(std::shared_ptr root); void check_children(std::shared_ptr root); private: StatusLog& m_log; SymTable m_sym; std::shared_ptr m_outer_fun_ret; void check_types(std::shared_ptr root, std::shared_ptr lhs, std::shared_ptr rhs); void check_types(std::shared_ptr root, std::shared_ptr lhs, std::vector> const& rhs); }; } #endif