Skip to content

Commit

Permalink
[clang][ExtractAPI] Add a space between type and name in property dec…
Browse files Browse the repository at this point in the history
…laration fragments

Differential Revision: https://reviews.llvm.org/D130583
  • Loading branch information
daniel-grumberg committed Jul 27, 2022
1 parent 529bd4f commit 7f0387d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions clang/lib/ExtractAPI/DeclarationFragments.cpp
Expand Up @@ -692,6 +692,7 @@ DeclarationFragments DeclarationFragmentsBuilder::getFragmentsForObjCProperty(
return Fragments.appendSpace()
.append(getFragmentsForType(Property->getType(),
Property->getASTContext(), After))
.appendSpace()
.append(Property->getName(),
DeclarationFragments::FragmentKind::Identifier)
.append(std::move(After));
Expand Down
4 changes: 4 additions & 0 deletions clang/test/ExtractAPI/objc_category.m
Expand Up @@ -317,6 +317,10 @@ + (void)ClassMethod;
"preciseIdentifier": "c:I",
"spelling": "int"
},
{
"kind": "text",
"spelling": " "
},
{
"kind": "identifier",
"spelling": "Property"
Expand Down
4 changes: 4 additions & 0 deletions clang/test/ExtractAPI/objc_interface.m
Expand Up @@ -462,6 +462,10 @@ - (char)getIvar;
"preciseIdentifier": "c:i",
"spelling": "unsigned int"
},
{
"kind": "text",
"spelling": " "
},
{
"kind": "identifier",
"spelling": "Property"
Expand Down

0 comments on commit 7f0387d

Please sign in to comment.