def AlwaysInline : InheritableAttr {
let Spellings = [GNU<"always_inline">, CXX11<"gnu", "always_inline">];
+ let Subjects = [Function];
}
def TLSModel : InheritableAttr {
.Default(llvm::StringRef());
} }];
let HasCustomParsing = 1;
+ let Subjects = [Named];
}
def Blocks : InheritableAttr {
def Cleanup : InheritableAttr {
let Spellings = [GNU<"cleanup">, CXX11<"gnu", "cleanup">];
let Args = [FunctionArgument<"FunctionDecl">];
+ let Subjects = [Var];
}
def Cold : InheritableAttr {
let Spellings = [GNU<"cold">, CXX11<"gnu", "cold">];
+ let Subjects = [Function];
}
def Common : InheritableAttr {
let Spellings = [GNU<"common">, CXX11<"gnu", "common">];
+ let Subjects = [Var];
}
def Const : InheritableAttr {
def Constructor : InheritableAttr {
let Spellings = [GNU<"constructor">, CXX11<"gnu", "constructor">];
let Args = [DefaultIntArgument<"Priority", 65535>];
+ let Subjects = [Function];
}
def CUDAConstant : InheritableAttr {
let Spellings = [GNU<"constant">];
+ let Subjects = [Var];
}
def CUDADevice : InheritableAttr {
let Spellings = [GNU<"device">];
+ let Subjects = [Function, Var];
}
def CUDAGlobal : InheritableAttr {
let Spellings = [GNU<"global">];
+ let Subjects = [Function];
}
def CUDAHost : InheritableAttr {
let Spellings = [GNU<"host">];
+ let Subjects = [Function];
}
def CUDALaunchBounds : InheritableAttr {
def CUDAShared : InheritableAttr {
let Spellings = [GNU<"shared">];
+ let Subjects = [Var];
}
def C11NoReturn : InheritableAttr {
def Destructor : InheritableAttr {
let Spellings = [GNU<"destructor">, CXX11<"gnu", "destructor">];
let Args = [DefaultIntArgument<"Priority", 65535>];
+ let Subjects = [Function];
}
def ExtVectorType : Attr {
let Spellings = [GNU<"ext_vector_type">];
+ let Subjects = [TypedefName];
let Args = [ExprArgument<"NumElements">];
let ASTNode = 0;
}
def MinSize : InheritableAttr {
let Spellings = [GNU<"minsize">];
- let Subjects = [Function];
+ let Subjects = [Function, ObjCMethod];
}
def Format : InheritableAttr {
def GNUInline : InheritableAttr {
let Spellings = [GNU<"gnu_inline">, CXX11<"gnu", "gnu_inline">];
+ let Subjects = [Function];
}
def Hot : InheritableAttr {
let Spellings = [GNU<"hot">, CXX11<"gnu", "hot">];
+ let Subjects = [Function];
}
def IBAction : InheritableAttr {
let Spellings = [GNU<"ibaction">];
+ let Subjects = [ObjCMethod];
}
def IBOutlet : InheritableAttr {
let Spellings = [GNU<"iboutlet">];
+ let Subjects = [ObjCIvar, ObjCProperty];
}
def IBOutletCollection : InheritableAttr {
let Spellings = [GNU<"iboutletcollection">];
let Args = [TypeArgument<"Interface", 1>];
+ let Subjects = [ObjCIvar, ObjCProperty];
}
def Malloc : InheritableAttr {
let Spellings = [GNU<"malloc">, CXX11<"gnu", "malloc">];
+ let Subjects = [Function];
}
def MaxFieldAlignment : InheritableAttr {
def Naked : InheritableAttr {
let Spellings = [GNU<"naked">, CXX11<"gnu", "naked">];
+ let Subjects = [Function];
}
def NeonPolyVectorType : TypeAttr {
def ReturnsTwice : InheritableAttr {
let Spellings = [GNU<"returns_twice">, CXX11<"gnu", "returns_twice">];
+ let Subjects = [Function];
}
def NoCommon : InheritableAttr {
let Spellings = [GNU<"nocommon">, CXX11<"gnu", "nocommon">];
+ let Subjects = [Var];
}
def NoDebug : InheritableAttr {
def NoInline : InheritableAttr {
let Spellings = [GNU<"noinline">, CXX11<"gnu", "noinline">];
+ let Subjects = [Function];
}
def NoMips16 : InheritableAttr, TargetSpecificAttr {
def NoReturn : InheritableAttr {
let Spellings = [GNU<"noreturn">, CXX11<"gnu", "noreturn">];
// FIXME: Does GCC allow this on the function instead?
- let Subjects = [Function];
}
def NoInstrumentFunction : InheritableAttr {
def ObjCException : InheritableAttr {
let Spellings = [GNU<"objc_exception">];
+ let Subjects = [ObjCInterface];
}
def ObjCMethodFamily : InheritableAttr {
def Overloadable : Attr {
let Spellings = [GNU<"overloadable">];
+ let Subjects = [Function];
}
def Override : InheritableAttr {
def Packed : InheritableAttr {
let Spellings = [GNU<"packed">, CXX11<"gnu", "packed">];
+ let Subjects = [Tag, Field];
}
def PnaclCall : InheritableAttr {
def InitPriority : InheritableAttr {
let Spellings = [GNU<"init_priority">];
let Args = [UnsignedArgument<"Priority">];
+ let Subjects = [Var];
}
def Section : InheritableAttr {
let Spellings = [GNU<"sentinel">, CXX11<"gnu", "sentinel">];
let Args = [DefaultIntArgument<"Sentinel", 0>,
DefaultIntArgument<"NullPos", 0>];
+ let Subjects = [Function, ObjCMethod, Block, Var];
}
def StdCall : InheritableAttr {
def TransparentUnion : InheritableAttr {
let Spellings = [GNU<"transparent_union">, CXX11<"gnu", "transparent_union">];
+ let Subjects = [Record, TypedefName];
}
def Unavailable : InheritableAttr {
let Args = [EnumArgument<"Visibility", "VisibilityType",
["default", "hidden", "internal", "protected"],
["Default", "Hidden", "Hidden", "Protected"]>];
+ let Subjects = [Tag, ObjCInterface, Namespace];
}
def VecReturn : InheritableAttr {
def Weak : InheritableAttr {
let Spellings = [GNU<"weak">, CXX11<"gnu", "weak">];
+ let Subjects = [Var, Function, CXXRecord];
}
def WeakImport : InheritableAttr {
let Spellings = [GNU<"weakref">, CXX11<"gnu", "weakref">];
// A WeakRef that has an argument is treated as being an AliasAttr
let Args = [StringArgument<"Aliasee", 1>];
+ let Subjects = [Var, Function];
}
def X86ForceAlignArgPointer : InheritableAttr, TargetSpecificAttr {
GNU<"no_sanitize_address">,
CXX11<"gnu", "no_address_safety_analysis">,
CXX11<"gnu", "no_sanitize_address">];
+ let Subjects = [Function, FunctionTemplate];
}
// Attribute to disable ThreadSanitizer checks.
def NoSanitizeThread : InheritableAttr {
let Spellings = [GNU<"no_sanitize_thread">];
+ let Subjects = [Function, FunctionTemplate];
}
// Attribute to disable MemorySanitizer checks.
def NoSanitizeMemory : InheritableAttr {
let Spellings = [GNU<"no_sanitize_memory">];
+ let Subjects = [Function, FunctionTemplate];
}
// C/C++ Thread safety attributes (e.g. for deadlock, data race checking)
UnsignedArgument<"ArgumentIdx">,
UnsignedArgument<"TypeTagIdx">,
BoolArgument<"IsPointer">];
- let Subjects = [Function];
let HasCustomParsing = 1;
}