Commit 0aa6414a authored by adamk's avatar adamk Committed by Commit bot

[cleanup] Remove redundant block_scope argument from DeclareClassVariable

R=neis@chromium.org

Review-Url: https://codereview.chromium.org/2690723002
Cr-Commit-Position: refs/heads/master@{#43144}
parent 165b411f
......@@ -4351,8 +4351,7 @@ typename ParserBase<Impl>::ExpressionT ParserBase<Impl>::ParseClassLiteral(
RaiseLanguageMode(STRICT);
ClassInfo class_info(this);
impl()->DeclareClassVariable(name, block_state.scope(), &class_info,
class_token_pos, CHECK_OK);
impl()->DeclareClassVariable(name, &class_info, class_token_pos, CHECK_OK);
if (Check(Token::EXTENDS)) {
block_state.set_start_position(scanner()->location().end_pos);
......
......@@ -3155,7 +3155,7 @@ ZoneList<Statement*>* Parser::ParseFunction(
return body;
}
void Parser::DeclareClassVariable(const AstRawString* name, Scope* block_scope,
void Parser::DeclareClassVariable(const AstRawString* name,
ClassInfo* class_info, int class_token_pos,
bool* ok) {
#ifdef DEBUG
......@@ -3165,7 +3165,7 @@ void Parser::DeclareClassVariable(const AstRawString* name, Scope* block_scope,
if (name != nullptr) {
class_info->proxy = factory()->NewVariableProxy(name, NORMAL_VARIABLE);
Declaration* declaration = factory()->NewVariableDeclaration(
class_info->proxy, block_scope, class_token_pos);
class_info->proxy, scope(), class_token_pos);
Declare(declaration, DeclarationDescriptor::NORMAL, CONST,
Variable::DefaultInitializationFlag(CONST), ok);
}
......
......@@ -359,7 +359,7 @@ class V8_EXPORT_PRIVATE Parser : public NON_EXPORTED_BASE(ParserBase<Parser>) {
ZoneList<const AstRawString*>* names,
int class_token_pos, int end_pos, bool* ok);
V8_INLINE void DeclareClassVariable(const AstRawString* name,
Scope* block_scope, ClassInfo* class_info,
ClassInfo* class_info,
int class_token_pos, bool* ok);
V8_INLINE void DeclareClassProperty(const AstRawString* class_name,
ClassLiteralProperty* property,
......
......@@ -1138,7 +1138,7 @@ class PreParser : public ParserBase<PreParser> {
return PreParserStatement::Default();
}
V8_INLINE void DeclareClassVariable(PreParserIdentifier name,
Scope* block_scope, ClassInfo* class_info,
ClassInfo* class_info,
int class_token_pos, bool* ok) {}
V8_INLINE void DeclareClassProperty(PreParserIdentifier class_name,
PreParserExpression property,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment