aboutsummaryrefslogtreecommitdiff
path: root/eval.h
diff options
context:
space:
mode:
authorShinichiro Hamaji <shinichiro.hamaji@gmail.com>2015-06-23 14:29:32 +0900
committerShinichiro Hamaji <shinichiro.hamaji@gmail.com>2015-06-23 14:29:32 +0900
commit784b99578e2a0b160721bebcbd0706bbf5e99f4c (patch)
treeaad31d5e728ab27838976d95a037a585059bd49e /eval.h
parentb74b890feb1a0248b6c3e421c656247741efba05 (diff)
downloadkati-784b99578e2a0b160721bebcbd0706bbf5e99f4c.tar.gz
[C++] Implement target specific variables
Diffstat (limited to 'eval.h')
-rw-r--r--eval.h9
1 files changed, 3 insertions, 6 deletions
diff --git a/eval.h b/eval.h
index 7461d73..cf911f6 100644
--- a/eval.h
+++ b/eval.h
@@ -5,19 +5,14 @@
#include <unordered_map>
#include <vector>
+#include "ast.h"
#include "loc.h"
#include "string_piece.h"
using namespace std;
-class AssignAST;
-class CommandAST;
-class ExportAST;
-class IfAST;
-class IncludeAST;
class Makefile;
class Rule;
-class RuleAST;
class Var;
class Vars;
@@ -57,6 +52,7 @@ class Evaluator {
void set_is_bootstrap(bool b) { is_bootstrap_ = b; }
private:
+ void DoAssign(StringPiece lhs, Value* rhs, StringPiece orig_rhs, AssignOp op);
void DoInclude(const char* fname, bool should_exist);
const Vars* in_vars_;
@@ -64,6 +60,7 @@ class Evaluator {
unordered_map<StringPiece, Vars*> rule_vars_;
vector<shared_ptr<Rule>> rules_;
Rule* last_rule_;
+ Vars* current_scope_;
Loc loc_;
bool is_bootstrap_;