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

Unified Diff: src/ast.h

Issue 39339: Assert in debug mode that we do not try to compile a function literal... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 9 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 | « no previous file | src/codegen.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 1452)
+++ src/ast.h (working copy)
@@ -1197,6 +1197,9 @@
is_expression_(is_expression),
loop_nesting_(0),
function_token_position_(RelocInfo::kNoPosition) {
+#ifdef DEBUG
+ already_compiled_ = false;
+#endif
}
virtual void Accept(AstVisitor* v);
@@ -1223,6 +1226,11 @@
bool loop_nesting() const { return loop_nesting_; }
void set_loop_nesting(int nesting) { loop_nesting_ = nesting; }
+#ifdef DEBUG
+ bool already_compiled() const { return already_compiled_; }
+ void mark_as_compiled() { already_compiled_ = true; }
+#endif
+
private:
Handle<String> name_;
Scope* scope_;
@@ -1236,6 +1244,9 @@
bool is_expression_;
int loop_nesting_;
int function_token_position_;
+#ifdef DEBUG
+ bool already_compiled_;
+#endif
};
« no previous file with comments | « no previous file | src/codegen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698