diff --git a/dep.cc b/dep.cc
index 45f9584..920ba26 100644
--- a/dep.cc
+++ b/dep.cc
@@ -116,7 +116,7 @@
 class DepBuilder {
  public:
   DepBuilder(Evaluator* ev,
-             const vector<shared_ptr<Rule>>& rules,
+             const vector<const Rule*>& rules,
              const unordered_map<Symbol, Vars*>& rule_vars)
       : ev_(ev),
         rule_vars_(rule_vars),
@@ -226,8 +226,8 @@
     return ::Exists(target.str());
   }
 
-  void PopulateRules(const vector<shared_ptr<Rule>>& rules) {
-    for (shared_ptr<Rule> rule : rules) {
+  void PopulateRules(const vector<const Rule*>& rules) {
+    for (const Rule* rule : rules) {
       if (rule->outputs.empty()) {
         PopulateImplicitRule(rule);
       } else {
@@ -239,7 +239,7 @@
     }
   }
 
-  bool PopulateSuffixRule(shared_ptr<Rule> rule, Symbol output) {
+  bool PopulateSuffixRule(const Rule* rule, Symbol output) {
     if (output.empty() || output.str()[0] != '.')
       return false;
 
@@ -337,7 +337,7 @@
     return r;
   }
 
-  void PopulateExplicitRule(shared_ptr<Rule> orig_rule) {
+  void PopulateExplicitRule(const Rule* orig_rule) {
     for (Symbol output : orig_rule->outputs) {
       const bool is_suffix_rule = PopulateSuffixRule(orig_rule, output);
 
@@ -358,9 +358,9 @@
     }
   }
 
-  void PopulateImplicitRule(shared_ptr<Rule> rule) {
+  void PopulateImplicitRule(const Rule* rule) {
     for (Symbol output_pattern : rule->output_patterns) {
-      implicit_rules_->Add(output_pattern.str(), rule.get());
+      implicit_rules_->Add(output_pattern.str(), rule);
     }
   }
 
@@ -619,7 +619,7 @@
 };
 
 void MakeDep(Evaluator* ev,
-             const vector<shared_ptr<Rule>>& rules,
+             const vector<const Rule*>& rules,
              const unordered_map<Symbol, Vars*>& rule_vars,
              const vector<Symbol>& targets,
              vector<DepNode*>* nodes) {
diff --git a/dep.h b/dep.h
index bb70eb3..05d10d0 100644
--- a/dep.h
+++ b/dep.h
@@ -15,7 +15,6 @@
 #ifndef DEP_H_
 #define DEP_H_
 
-#include <memory>
 #include <string>
 #include <unordered_map>
 #include <vector>
@@ -53,7 +52,7 @@
 void QuitDepNodePool();
 
 void MakeDep(Evaluator* ev,
-             const vector<shared_ptr<Rule>>& rules,
+             const vector<const Rule*>& rules,
              const unordered_map<Symbol, Vars*>& rule_vars,
              const vector<Symbol>& targets,
              vector<DepNode*>* nodes);
diff --git a/eval.cc b/eval.cc
index d4392b3..550f5eb 100644
--- a/eval.cc
+++ b/eval.cc
@@ -124,7 +124,7 @@
     }
 
     LOG("Rule: %s", rule->DebugString().c_str());
-    rules_.push_back(shared_ptr<Rule>(rule));
+    rules_.push_back(rule);
     last_rule_ = rule;
     return;
   }
diff --git a/eval.h b/eval.h
index c25edff..cb03d5d 100644
--- a/eval.h
+++ b/eval.h
@@ -15,7 +15,6 @@
 #ifndef EVAL_H_
 #define EVAL_H_
 
-#include <memory>
 #include <unordered_map>
 #include <unordered_set>
 #include <vector>
@@ -53,7 +52,7 @@
   const Loc& loc() const { return loc_; }
   void set_loc(const Loc& loc) { loc_ = loc; }
 
-  const vector<shared_ptr<Rule>>& rules() const { return rules_; }
+  const vector<const Rule*>& rules() const { return rules_; }
   const unordered_map<Symbol, Vars*>& rule_vars() const {
     return rule_vars_;
   }
@@ -100,7 +99,7 @@
 
   Vars* vars_;
   unordered_map<Symbol, Vars*> rule_vars_;
-  vector<shared_ptr<Rule>> rules_;
+  vector<const Rule*> rules_;
   unordered_map<Symbol, bool> exports_;
 
   Rule* last_rule_;
