diff options
Diffstat (limited to 'libjulia/optimiser/Substitution.h')
-rw-r--r-- | libjulia/optimiser/Substitution.h | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/libjulia/optimiser/Substitution.h b/libjulia/optimiser/Substitution.h index 10bdf32e..313a08d7 100644 --- a/libjulia/optimiser/Substitution.h +++ b/libjulia/optimiser/Substitution.h @@ -33,18 +33,17 @@ namespace julia /** * Specific AST copier that replaces certain identifiers with expressions. - * Only works on ASTs that are expressions. */ class Substitution: public ASTCopier { public: - Substitution(std::map<std::string, Statement const*> const& _substitutions): + Substitution(std::map<std::string, Expression const*> const& _substitutions): m_substitutions(_substitutions) {} - virtual Statement translate(Statement const& _statement) override; + virtual Expression translate(Expression const& _expression) override; private: - std::map<std::string, Statement const*> const& m_substitutions; + std::map<std::string, Expression const*> const& m_substitutions; }; } |