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

Unified Diff: src/full-codegen.h

Issue 8417035: Introduce extended mode. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased version. Created 9 years, 1 month 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
Index: src/full-codegen.h
diff --git a/src/full-codegen.h b/src/full-codegen.h
index 799f96d08816398815d276665f0ba3d1df5e72cc..81203f6f21620cb2f1c24bbaed2916017614e39b 100644
--- a/src/full-codegen.h
+++ b/src/full-codegen.h
@@ -527,11 +527,14 @@ class FullCodeGenerator: public AstVisitor {
Handle<Script> script() { return info_->script(); }
bool is_eval() { return info_->is_eval(); }
bool is_native() { return info_->is_native(); }
- bool is_strict_mode() {
- return strict_mode_flag() == kStrictMode;
+ bool is_strict_or_extended_mode() {
rossberg 2011/11/08 15:02:46 As before.
Steven 2011/11/08 16:13:49 Done.
+ return language_mode() != CLASSIC_MODE;
}
- StrictModeFlag strict_mode_flag() {
- return function()->strict_mode_flag();
+ bool is_classic_mode() {
+ return language_mode() == CLASSIC_MODE;
+ }
+ LanguageMode language_mode() {
+ return function()->language_mode();
}
FunctionLiteral* function() { return info_->function(); }
Scope* scope() { return scope_; }

Powered by Google App Engine
This is Rietveld 408576698