mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-01-25 02:28:18 +00:00
cefafc4999
Summary: SExprBuilder::translateDeclRefExpr was only looking at FunctionDecl and not also looking at ObjCMethodDecl. It should consider both because the attributes can be used on Objective-C as well. <rdar://problem/48941331> Reviewers: dexonsmith, erik.pilkington Subscribers: jkorous, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D59523 llvm-svn: 356940
16 lines
342 B
Plaintext
16 lines
342 B
Plaintext
// RUN: %clang_cc1 -fsyntax-only -Wthread-safety -Wno-objc-root-class %s
|
|
|
|
// Thread safety analysis used to crash when used with ObjC methods.
|
|
|
|
#include "thread-safety-analysis.h"
|
|
|
|
@interface MyInterface
|
|
- (void)doIt:(class Lock *)myLock;
|
|
@end
|
|
|
|
@implementation MyInterface
|
|
- (void)doIt:(class Lock *)myLock {
|
|
AutoLock lock(*myLock);
|
|
}
|
|
@end
|