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

Unified Diff: src/variables.h

Issue 943543002: [strong] Declaration-after-use errors. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: computed prop names comment fix Created 5 years, 10 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/scopes.cc ('k') | test/mjsunit/strong/declaration-after-use.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/variables.h
diff --git a/src/variables.h b/src/variables.h
index 1adeb1f0f417cc0d8bcdf6a19a2f688f1195e477..4696e0543d30a0d3315495de19ec7fd1ae5d3e62 100644
--- a/src/variables.h
+++ b/src/variables.h
@@ -18,7 +18,7 @@ namespace internal {
class Variable: public ZoneObject {
public:
- enum Kind { NORMAL, THIS, NEW_TARGET, ARGUMENTS };
+ enum Kind { NORMAL, FUNCTION, THIS, NEW_TARGET, ARGUMENTS };
enum Location {
// Before and during variable allocation, a variable whose location is
@@ -98,6 +98,7 @@ class Variable: public ZoneObject {
return initialization_flag_ == kNeedsInitialization;
}
+ bool is_function() const { return kind_ == FUNCTION; }
bool is_this() const { return kind_ == THIS; }
bool is_new_target() const { return kind_ == NEW_TARGET; }
bool is_arguments() const { return kind_ == ARGUMENTS; }
« no previous file with comments | « src/scopes.cc ('k') | test/mjsunit/strong/declaration-after-use.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698