| Index: src/parser.cc
|
| diff --git a/src/parser.cc b/src/parser.cc
|
| index a2900b51ae3821b8218395df5f4701bc542ab802..80cbb2daa3d8705298296300b0f16e91f181a6d6 100644
|
| --- a/src/parser.cc
|
| +++ b/src/parser.cc
|
| @@ -453,10 +453,11 @@ void ParserTraits::CheckPossibleEvalCall(Expression* expression,
|
| }
|
|
|
|
|
| -Expression* ParserTraits::MarkExpressionAsAssigned(Expression* expression) {
|
| - VariableProxy* proxy =
|
| - expression != NULL ? expression->AsVariableProxy() : NULL;
|
| - if (proxy != NULL) proxy->set_is_assigned();
|
| +Expression* ParserTraits::MarkExpressionAsLValue(Expression* expression) {
|
| + VariableProxy* proxy = expression != NULL
|
| + ? expression->AsVariableProxy()
|
| + : NULL;
|
| + if (proxy != NULL) proxy->MarkAsLValue();
|
| return expression;
|
| }
|
|
|
| @@ -592,7 +593,8 @@ Expression* ParserTraits::NewThrowError(
|
| Zone* zone = parser_->zone();
|
| int argc = arg != NULL ? 1 : 0;
|
| const AstRawString* type =
|
| - parser_->ast_value_factory_->GetOneByteString(message);
|
| + parser_->ast_value_factory_->GetOneByteString(Vector<const uint8_t>(
|
| + reinterpret_cast<const uint8_t*>(message), StrLength(message)));
|
| ZoneList<const AstRawString*>* array =
|
| new (zone) ZoneList<const AstRawString*>(argc, zone);
|
| if (arg != NULL) {
|
| @@ -1720,8 +1722,6 @@ void Parser::Declare(Declaration* declaration, bool resolve, bool* ok) {
|
| Expression* expression = NewThrowTypeError(
|
| "var_redeclaration", name, declaration->position());
|
| declaration_scope->SetIllegalRedeclaration(expression);
|
| - } else if (mode == VAR) {
|
| - var->set_maybe_assigned();
|
| }
|
| }
|
|
|
| @@ -3888,8 +3888,6 @@ void Parser::ThrowPendingError() {
|
| .ToHandleChecked();
|
| elements->set(0, *arg_string);
|
| }
|
| - isolate()->debug()->OnCompileError(script_);
|
| -
|
| Handle<JSArray> array = factory->NewJSArrayWithElements(elements);
|
| Handle<Object> result = pending_error_is_reference_error_
|
| ? factory->NewReferenceError(pending_error_message_, array)
|
|
|