From 2ee29b3426d2d79872fba35adbeb8d768983ffec Mon Sep 17 00:00:00 2001 From: Carlo Zancanaro Date: Thu, 19 Apr 2012 16:21:26 +1000 Subject: Add presentation; start a different implementation --- impl/Variable.h | 24 ------------------------ 1 file changed, 24 deletions(-) delete mode 100644 impl/Variable.h (limited to 'impl/Variable.h') diff --git a/impl/Variable.h b/impl/Variable.h deleted file mode 100644 index 7433426..0000000 --- a/impl/Variable.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef VARIABLE_H -#define VARIABLE_H - -#include -#include "Expression.h" - -template -struct Variable : public Expression { - Variable(const std::string& name) - : _name(name) { } - - std::string name() const { - return this->_name; - } - - T eval(const std::map& values) const { - return values.find(_name)->second; - } - - private: - const std::string _name; -}; - -#endif -- cgit v1.2.3