the compiler predefines buffer. These are essentially part of
the Objective-C language.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@158690
91177308-0d34-0410-b5e6-
96231b3b80d8
if (LangOpts.NeXTRuntime)
Builder.defineMacro("__NEXT_RUNTIME__");
+
+ Builder.defineMacro("IBOutlet", "__attribute__((iboutlet))");
+ Builder.defineMacro("IBOutletCollection(ClassName)",
+ "__attribute__((iboutletcollection(ClassName)))");
+ Builder.defineMacro("IBAction", "void)__attribute__((ibaction)");
}
// darwin_constant_cfstrings controls this. This is also dependent
-// RUN: %clang_cc1 -analyze -analyzer-checker=experimental.osx.cocoa.Dealloc '-DIBOutlet=__attribute__((iboutlet))' %s -verify
+// RUN: %clang_cc1 -analyze -analyzer-checker=experimental.osx.cocoa.Dealloc %s -verify
typedef signed char BOOL;
@protocol NSObject
- (BOOL)isEqual:(id)object;
//===------------------------------------------------------------------------===
// Don't warn about iVars that are IBOutlets.
-#ifndef IBOutlet
-#define IBOutlet
-#endif
-
@class NSWindow;
@interface HasOutlet : NSObject {
}
else {
$Cmd = $Clang;
- if ($Lang eq "objective-c" || $Lang eq "objective-c++") {
- push @Args,'-DIBOutlet=__attribute__((iboutlet))';
- push @Args,'-DIBOutletCollection(ClassName)=__attribute__((iboutletcollection)))';
- push @Args,'-DIBAction=void)__attribute__((ibaction)';
- }
# Create arguments for doing regular parsing.
my $SyntaxArgs = GetCCArgs("-fsyntax-only", \@Args);