Index: src/compiler.cc |
diff --git a/src/compiler.cc b/src/compiler.cc |
index 39a199424b56b406accd3a1cce97a884a53333ca..39a3e042689c6fe28905c9f51f3653a20b134d8a 100644 |
--- a/src/compiler.cc |
+++ b/src/compiler.cc |
@@ -521,7 +521,9 @@ Handle<SharedFunctionInfo> Compiler::Compile(Handle<String> source, |
info.MarkAsGlobal(); |
info.SetExtension(extension); |
info.SetPreParseData(pre_data); |
- if (FLAG_use_strict) info.SetLanguageMode(STRICT_MODE); |
+ if (FLAG_use_strict) { |
+ info.SetLanguageMode(FLAG_harmony_scoping ? EXTENDED_MODE : STRICT_MODE); |
+ } |
result = MakeFunctionInfo(&info); |
if (extension == NULL && !result.is_null()) { |
compilation_cache->PutScript(source, result); |