Skip to content

Commit 3feb18b

Browse files
committed
Plumb through EnterScope
1 parent e832062 commit 3feb18b

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

clang/include/clang/Parse/Parser.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1650,7 +1650,7 @@ class Parser : public CodeCompletionHandler {
16501650
ParsedAttributes *OutAttrs = nullptr);
16511651
void ParseLexedAttribute(LateParsedAttribute &LA,
16521652
bool EnterScope, bool OnDefinition);
1653-
void ParseLexedCAttribute(LateParsedAttribute &LA,
1653+
void ParseLexedCAttribute(LateParsedAttribute &LA, bool EnterScope,
16541654
ParsedAttributes *OutAttrs = nullptr);
16551655
void ParseLexedMethodDeclarations(ParsingClass &Class);
16561656
void ParseLexedMethodDeclaration(LateParsedMethodDeclaration &LM);

clang/lib/Parse/ParseDecl.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4958,7 +4958,7 @@ void Parser::ParseLexedCAttributeList(LateParsedAttrList &LAs, bool EnterScope,
49584958
}
49594959
#endif
49604960
for (auto *LA : LAs) {
4961-
ParseLexedCAttribute(*LA, OutAttrs);
4961+
ParseLexedCAttribute(*LA, EnterScope, OutAttrs);
49624962
delete LA;
49634963
}
49644964
LAs.clear();
@@ -4969,7 +4969,7 @@ void Parser::ParseLexedCAttributeList(LateParsedAttrList &LAs, bool EnterScope,
49694969
/// for each LateParsedAttribute. We consume the saved tokens and
49704970
/// create an attribute with the arguments filled in. We add this
49714971
/// to the Attribute list for the decl.
4972-
void Parser::ParseLexedCAttribute(LateParsedAttribute &LA,
4972+
void Parser::ParseLexedCAttribute(LateParsedAttribute &LA, bool EnterScope,
49734973
ParsedAttributes *OutAttrs) {
49744974
// Create a fake EOF so that attribute parsing won't go off the end of the
49754975
// attribute.
@@ -4989,6 +4989,9 @@ void Parser::ParseLexedCAttribute(LateParsedAttribute &LA,
49894989
// as when we entered this function.
49904990
ConsumeAnyToken(/*ConsumeCodeCompletionTok=*/true);
49914991

4992+
// TODO: Use `EnterScope`
4993+
(void)EnterScope;
4994+
49924995
ParsedAttributes Attrs(AttrFactory);
49934996

49944997
assert(LA.Decls.size() <= 1 &&

0 commit comments

Comments
 (0)