diff --git a/clang/lib/ExtractAPI/DeclarationFragments.cpp b/clang/lib/ExtractAPI/DeclarationFragments.cpp --- a/clang/lib/ExtractAPI/DeclarationFragments.cpp +++ b/clang/lib/ExtractAPI/DeclarationFragments.cpp @@ -692,6 +692,7 @@ return Fragments.appendSpace() .append(getFragmentsForType(Property->getType(), Property->getASTContext(), After)) + .appendSpace() .append(Property->getName(), DeclarationFragments::FragmentKind::Identifier) .append(std::move(After)); diff --git a/clang/test/ExtractAPI/objc_category.m b/clang/test/ExtractAPI/objc_category.m --- a/clang/test/ExtractAPI/objc_category.m +++ b/clang/test/ExtractAPI/objc_category.m @@ -317,6 +317,10 @@ "preciseIdentifier": "c:I", "spelling": "int" }, + { + "kind": "text", + "spelling": " " + }, { "kind": "identifier", "spelling": "Property" diff --git a/clang/test/ExtractAPI/objc_interface.m b/clang/test/ExtractAPI/objc_interface.m --- a/clang/test/ExtractAPI/objc_interface.m +++ b/clang/test/ExtractAPI/objc_interface.m @@ -462,6 +462,10 @@ "preciseIdentifier": "c:i", "spelling": "unsigned int" }, + { + "kind": "text", + "spelling": " " + }, { "kind": "identifier", "spelling": "Property"