Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(46)

Unified Diff: src/ast.h

Issue 553134: Add a pass for the fast compiler to label expression nodes.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/SConscript ('k') | src/compiler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ast.h
===================================================================
--- src/ast.h (revision 3736)
+++ src/ast.h (working copy)
@@ -180,6 +180,10 @@
kTestValue
};
+ static const int kNoLabel = -1;
+
+ Expression() : num_(kNoLabel) {}
+
virtual Expression* AsExpression() { return this; }
virtual bool IsValidJSON() { return false; }
@@ -198,8 +202,14 @@
// Static type information for this expression.
StaticType* type() { return &type_; }
+ int num() { return num_; }
+
+ // AST node numbering ordered by evaluation order.
+ void set_num(int n) { num_ = n; }
+
private:
StaticType type_;
+ int num_;
};
« no previous file with comments | « src/SConscript ('k') | src/compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698