@@ -8489,7 +8489,8 @@ bool ClangASTContext::AddObjCClassProperty(
8489
8489
? class_interface_decl->lookupInstanceMethod (getter_sel)
8490
8490
: class_interface_decl->lookupClassMethod (getter_sel))) {
8491
8491
const bool isVariadic = false ;
8492
- const bool isSynthesized = false ;
8492
+ const bool isPropertyAccessor = false ;
8493
+ const bool isSynthesizedAccessorStub = false ;
8493
8494
const bool isImplicitlyDeclared = true ;
8494
8495
const bool isDefined = false ;
8495
8496
const clang::ObjCMethodDecl::ImplementationControl impControl =
@@ -8500,7 +8501,8 @@ bool ClangASTContext::AddObjCClassProperty(
8500
8501
*clang_ast, clang::SourceLocation (), clang::SourceLocation (),
8501
8502
getter_sel, ClangUtil::GetQualType (property_clang_type_to_access),
8502
8503
nullptr , class_interface_decl, isInstance, isVariadic,
8503
- isSynthesized, isImplicitlyDeclared, isDefined, impControl,
8504
+ isPropertyAccessor, isSynthesizedAccessorStub,
8505
+ isImplicitlyDeclared, isDefined, impControl,
8504
8506
HasRelatedResultType);
8505
8507
8506
8508
if (getter && metadata)
@@ -8521,7 +8523,8 @@ bool ClangASTContext::AddObjCClassProperty(
8521
8523
: class_interface_decl->lookupClassMethod (setter_sel))) {
8522
8524
clang::QualType result_type = clang_ast->VoidTy ;
8523
8525
const bool isVariadic = false ;
8524
- const bool isSynthesized = false ;
8526
+ const bool isPropertyAccessor = true ;
8527
+ const bool isSynthesizedAccessorStub = false ;
8525
8528
const bool isImplicitlyDeclared = true ;
8526
8529
const bool isDefined = false ;
8527
8530
const clang::ObjCMethodDecl::ImplementationControl impControl =
@@ -8531,8 +8534,9 @@ bool ClangASTContext::AddObjCClassProperty(
8531
8534
clang::ObjCMethodDecl *setter = clang::ObjCMethodDecl::Create (
8532
8535
*clang_ast, clang::SourceLocation (), clang::SourceLocation (),
8533
8536
setter_sel, result_type, nullptr , class_interface_decl,
8534
- isInstance, isVariadic, isSynthesized, isImplicitlyDeclared,
8535
- isDefined, impControl, HasRelatedResultType);
8537
+ isInstance, isVariadic, isPropertyAccessor,
8538
+ isSynthesizedAccessorStub, isImplicitlyDeclared, isDefined,
8539
+ impControl, HasRelatedResultType);
8536
8540
8537
8541
if (setter && metadata)
8538
8542
ClangASTContext::SetMetadata (clang_ast, setter, *metadata);
@@ -8634,10 +8638,16 @@ clang::ObjCMethodDecl *ClangASTContext::AddMethodToObjCObjectType(
8634
8638
if (!method_function_prototype)
8635
8639
return nullptr ;
8636
8640
8637
- bool is_synthesized = false ;
8638
- bool is_defined = false ;
8639
- clang::ObjCMethodDecl::ImplementationControl imp_control =
8641
+ const bool isInstance = (name[0 ] == ' -' );
8642
+ const bool isVariadic = false ;
8643
+ const bool isPropertyAccessor = false ;
8644
+ const bool isSynthesizedAccessorStub = false ;
8645
+ // / Force this to true because we don't have source locations.
8646
+ const bool isImplicitlyDeclared = true ;
8647
+ const bool isDefined = false ;
8648
+ const clang::ObjCMethodDecl::ImplementationControl impControl =
8640
8649
clang::ObjCMethodDecl::None;
8650
+ const bool HasRelatedResultType = false ;
8641
8651
8642
8652
const unsigned num_args = method_function_prototype->getNumParams ();
8643
8653
@@ -8653,10 +8663,8 @@ clang::ObjCMethodDecl *ClangASTContext::AddMethodToObjCObjectType(
8653
8663
nullptr , // TypeSourceInfo *ResultTInfo,
8654
8664
ClangASTContext::GetASTContext (ast)->GetDeclContextForType (
8655
8665
ClangUtil::GetQualType (type)),
8656
- name[0 ] == ' -' , is_variadic, is_synthesized,
8657
- true , // is_implicitly_declared; we force this to true because we don't
8658
- // have source locations
8659
- is_defined, imp_control, false /* has_related_result_type*/ );
8666
+ isInstance, isVariadic, isPropertyAccessor, isSynthesizedAccessorStub,
8667
+ isImplicitlyDeclared, isDefined, impControl, HasRelatedResultType);
8660
8668
8661
8669
if (objc_method_decl == nullptr )
8662
8670
return nullptr ;
0 commit comments