Index: src/parser.cc |
diff --git a/src/parser.cc b/src/parser.cc |
index a45a4b15e60c906256719822d08ae8f2b16921b1..bf12fa4135b4dafd6d0028ce3dcf79eb7469ec7d 100644 |
--- a/src/parser.cc |
+++ b/src/parser.cc |
@@ -1062,6 +1062,8 @@ FunctionLiteral* Parser::DoParseProgram(ParseInfo* info) { |
if (ok && is_strict(language_mode())) { |
CheckStrictOctalLiteral(beg_pos, scanner()->location().end_pos, &ok); |
+ } |
+ if (ok && (is_strict(language_mode()) || allow_harmony_sloppy())) { |
CheckConflictingVarDeclarations(scope_, &ok); |
} |
@@ -4141,6 +4143,8 @@ FunctionLiteral* Parser::ParseFunctionLiteral( |
if (is_strict(language_mode())) { |
CheckStrictOctalLiteral(scope->start_position(), scope->end_position(), |
CHECK_OK); |
+ } |
+ if (is_strict(language_mode()) || allow_harmony_sloppy()) { |
CheckConflictingVarDeclarations(scope, CHECK_OK); |
} |
} |