Home | History | Annotate | Download | only in Basic
      1 //==--- DiagnosticGroups.td - Diagnostic Group Definitions ----------------===//
      2 //
      3 //                     The LLVM Compiler Infrastructure
      4 //
      5 // This file is distributed under the University of Illinois Open Source
      6 // License. See LICENSE.TXT for details.
      7 //
      8 //===----------------------------------------------------------------------===//
      9 
     10 def ImplicitFunctionDeclare : DiagGroup<"implicit-function-declaration">;
     11 def ImplicitInt : DiagGroup<"implicit-int">;
     12 
     13 // Aggregation warning settings.
     14 def Implicit : DiagGroup<"implicit", [
     15     ImplicitFunctionDeclare,
     16     ImplicitInt
     17 ]>;
     18 
     19 // Empty DiagGroups are recognized by clang but ignored.
     20 def : DiagGroup<"abi">;
     21 def AbsoluteValue : DiagGroup<"absolute-value">;
     22 def AddressOfTemporary : DiagGroup<"address-of-temporary">;
     23 def : DiagGroup<"aggregate-return">;
     24 def GNUAlignofExpression : DiagGroup<"gnu-alignof-expression">;
     25 def AmbigMemberTemplate : DiagGroup<"ambiguous-member-template">;
     26 def GNUAnonymousStruct : DiagGroup<"gnu-anonymous-struct">;
     27 def GNUAutoType : DiagGroup<"gnu-auto-type">;
     28 def ArrayBounds : DiagGroup<"array-bounds">;
     29 def ArrayBoundsPointerArithmetic : DiagGroup<"array-bounds-pointer-arithmetic">;
     30 def Availability : DiagGroup<"availability">;
     31 def Section : DiagGroup<"section">;
     32 def AutoImport : DiagGroup<"auto-import">;
     33 def CXX14BinaryLiteral : DiagGroup<"c++14-binary-literal">;
     34 def GNUBinaryLiteral : DiagGroup<"gnu-binary-literal">;
     35 def GNUCompoundLiteralInitializer : DiagGroup<"gnu-compound-literal-initializer">;
     36 def BitFieldConstantConversion : DiagGroup<"bitfield-constant-conversion">;
     37 def BitFieldWidth : DiagGroup<"bitfield-width">;
     38 def ConstantConversion :
     39   DiagGroup<"constant-conversion", [ BitFieldConstantConversion ] >;
     40 def LiteralConversion : DiagGroup<"literal-conversion">;
     41 def StringConversion : DiagGroup<"string-conversion">;
     42 def SignConversion : DiagGroup<"sign-conversion">;
     43 def PointerBoolConversion : DiagGroup<"pointer-bool-conversion">;
     44 def UndefinedBoolConversion : DiagGroup<"undefined-bool-conversion">;
     45 def BoolConversion : DiagGroup<"bool-conversion", [PointerBoolConversion,
     46                                                    UndefinedBoolConversion]>;
     47 def IntConversion : DiagGroup<"int-conversion">;
     48 def EnumConversion : DiagGroup<"enum-conversion">;
     49 
     50 def FloatOverflowConversion : DiagGroup<"float-overflow-conversion">;
     51 def FloatZeroConversion : DiagGroup<"float-zero-conversion">;
     52 def FloatConversion :
     53   DiagGroup<"float-conversion", [FloatOverflowConversion,
     54                                  FloatZeroConversion]>;
     55 
     56 def DoublePromotion : DiagGroup<"double-promotion">;
     57 def EnumTooLarge : DiagGroup<"enum-too-large">;
     58 def UnsupportedNan : DiagGroup<"unsupported-nan">;
     59 def UnsupportedCB : DiagGroup<"unsupported-cb">;
     60 def NonLiteralNullConversion : DiagGroup<"non-literal-null-conversion">;
     61 def NullConversion : DiagGroup<"null-conversion">;
     62 def ImplicitConversionFloatingPointToBool :
     63   DiagGroup<"implicit-conversion-floating-point-to-bool">;
     64 def ObjCLiteralConversion : DiagGroup<"objc-literal-conversion">;
     65 def BadArrayNewLength : DiagGroup<"bad-array-new-length">;
     66 def MacroRedefined : DiagGroup<"macro-redefined">;
     67 def BuiltinMacroRedefined : DiagGroup<"builtin-macro-redefined">;
     68 def BuiltinRequiresHeader : DiagGroup<"builtin-requires-header">;
     69 def C99Compat : DiagGroup<"c99-compat">;
     70 def CXXCompat: DiagGroup<"c++-compat">;
     71 def ExternCCompat : DiagGroup<"extern-c-compat">;
     72 def KeywordCompat : DiagGroup<"keyword-compat">;
     73 def GNUCaseRange : DiagGroup<"gnu-case-range">;
     74 def CastAlign : DiagGroup<"cast-align">;
     75 def CastQual : DiagGroup<"cast-qual">;
     76 def : DiagGroup<"char-align">;
     77 def Comment : DiagGroup<"comment">;
     78 def GNUComplexInteger : DiagGroup<"gnu-complex-integer">;
     79 def GNUConditionalOmittedOperand : DiagGroup<"gnu-conditional-omitted-operand">;
     80 def ConfigMacros : DiagGroup<"config-macros">;
     81 def : DiagGroup<"ctor-dtor-privacy">;
     82 def GNUDesignator : DiagGroup<"gnu-designator">;
     83 def GNUStringLiteralOperatorTemplate :
     84   DiagGroup<"gnu-string-literal-operator-template">;
     85 def UndefinedVarTemplate : DiagGroup<"undefined-var-template">;
     86 def UndefinedFuncTemplate : DiagGroup<"undefined-func-template">;
     87 
     88 def DeleteIncomplete : DiagGroup<"delete-incomplete">;
     89 def DeleteNonVirtualDtor : DiagGroup<"delete-non-virtual-dtor">;
     90 def AbstractFinalClass : DiagGroup<"abstract-final-class">;
     91 
     92 def CXX11CompatDeprecatedWritableStr :
     93   DiagGroup<"c++11-compat-deprecated-writable-strings">;
     94 
     95 def DeprecatedAttributes : DiagGroup<"deprecated-attributes">;
     96 def DeprecatedDeclarations : DiagGroup<"deprecated-declarations">;
     97 def UnavailableDeclarations : DiagGroup<"unavailable-declarations">;
     98 def PartialAvailability : DiagGroup<"partial-availability">;
     99 def DeprecatedImplementations :DiagGroup<"deprecated-implementations">;
    100 def DeprecatedIncrementBool : DiagGroup<"deprecated-increment-bool">;
    101 def DeprecatedRegister : DiagGroup<"deprecated-register">;
    102 def DeprecatedWritableStr : DiagGroup<"deprecated-writable-strings",
    103                                       [CXX11CompatDeprecatedWritableStr]>;
    104 // FIXME: Why is DeprecatedImplementations not in this group?
    105 def Deprecated : DiagGroup<"deprecated", [DeprecatedAttributes,
    106                                           DeprecatedDeclarations,
    107                                           DeprecatedIncrementBool,
    108                                           DeprecatedRegister,
    109                                           DeprecatedWritableStr]>,
    110                  DiagCategory<"Deprecations">;
    111 
    112 def LibLTO : DiagGroup<"liblto">;
    113 def : DiagGroup<"disabled-optimization">;
    114 def : DiagGroup<"discard-qual">;
    115 def : DiagGroup<"div-by-zero">;
    116 
    117 def DocumentationHTML : DiagGroup<"documentation-html">;
    118 def DocumentationUnknownCommand : DiagGroup<"documentation-unknown-command">;
    119 def DocumentationPedantic : DiagGroup<"documentation-pedantic",
    120                                       [DocumentationUnknownCommand]>;
    121 def DocumentationDeprecatedSync : DiagGroup<"documentation-deprecated-sync">;
    122 def Documentation : DiagGroup<"documentation",
    123                               [DocumentationHTML,
    124                                DocumentationDeprecatedSync]>;
    125 
    126 def EmptyBody : DiagGroup<"empty-body">;
    127 def Exceptions : DiagGroup<"exceptions">;
    128 
    129 def GNUEmptyInitializer : DiagGroup<"gnu-empty-initializer">;
    130 def GNUEmptyStruct : DiagGroup<"gnu-empty-struct">;
    131 def ExtraTokens : DiagGroup<"extra-tokens">;
    132 def CXX11ExtraSemi : DiagGroup<"c++11-extra-semi">;
    133 def ExtraSemi : DiagGroup<"extra-semi", [CXX11ExtraSemi]>;
    134 
    135 def GNUFlexibleArrayInitializer : DiagGroup<"gnu-flexible-array-initializer">;
    136 def GNUFlexibleArrayUnionMember : DiagGroup<"gnu-flexible-array-union-member">;
    137 def GNUFoldingConstant : DiagGroup<"gnu-folding-constant">;
    138 def FormatExtraArgs : DiagGroup<"format-extra-args">;
    139 def FormatZeroLength : DiagGroup<"format-zero-length">;
    140 
    141 // Warnings for C++1y code which is not compatible with prior C++ standards.
    142 def CXXPre14Compat : DiagGroup<"c++98-c++11-compat">;
    143 def CXXPre14CompatPedantic : DiagGroup<"c++98-c++11-compat-pedantic",
    144                                        [CXXPre14Compat]>;
    145 def CXXPre1zCompat : DiagGroup<"c++98-c++11-c++14-compat">;
    146 def CXXPre1zCompatPedantic : DiagGroup<"c++98-c++11-c++14-compat-pedantic",
    147                                        [CXXPre1zCompat]>;
    148 
    149 def CXX98CompatBindToTemporaryCopy :
    150   DiagGroup<"c++98-compat-bind-to-temporary-copy">;
    151 def CXX98CompatLocalTypeTemplateArgs :
    152   DiagGroup<"c++98-compat-local-type-template-args">;
    153 def CXX98CompatUnnamedTypeTemplateArgs :
    154   DiagGroup<"c++98-compat-unnamed-type-template-args">;
    155 
    156 def CXX98Compat : DiagGroup<"c++98-compat",
    157                             [CXX98CompatLocalTypeTemplateArgs,
    158                              CXX98CompatUnnamedTypeTemplateArgs,
    159                              CXXPre14Compat,
    160                              CXXPre1zCompat]>;
    161 // Warnings for C++11 features which are Extensions in C++98 mode.
    162 def CXX98CompatPedantic : DiagGroup<"c++98-compat-pedantic",
    163                                     [CXX98Compat,
    164                                      CXX98CompatBindToTemporaryCopy,
    165                                      CXXPre14CompatPedantic,
    166                                      CXXPre1zCompatPedantic]>;
    167 
    168 def CXX11Narrowing : DiagGroup<"c++11-narrowing">;
    169 
    170 def CXX11WarnOverrideMethod : DiagGroup<"inconsistent-missing-override">;
    171 
    172 // Original name of this warning in Clang
    173 def : DiagGroup<"c++0x-narrowing", [CXX11Narrowing]>;
    174 
    175 // Name of this warning in GCC
    176 def : DiagGroup<"narrowing", [CXX11Narrowing]>;
    177 
    178 def CXX11CompatReservedUserDefinedLiteral :
    179   DiagGroup<"c++11-compat-reserved-user-defined-literal">;
    180 def ReservedUserDefinedLiteral :
    181   DiagGroup<"reserved-user-defined-literal",
    182             [CXX11CompatReservedUserDefinedLiteral]>;
    183 
    184 def CXX11Compat : DiagGroup<"c++11-compat",
    185                             [CXX11Narrowing,
    186                              CXX11CompatReservedUserDefinedLiteral,
    187                              CXX11CompatDeprecatedWritableStr,
    188                              CXXPre14Compat,
    189                              CXXPre1zCompat]>;
    190 def : DiagGroup<"c++0x-compat", [CXX11Compat]>;
    191 def CXX11CompatPedantic : DiagGroup<"c++11-compat-pedantic",
    192                                     [CXXPre14CompatPedantic,
    193                                      CXXPre1zCompatPedantic]>;
    194 
    195 def CXX14Compat : DiagGroup<"c++14-compat", [CXXPre1zCompat]>;
    196 def CXX14CompatPedantic : DiagGroup<"c++14-compat-pedantic",
    197                                     [CXXPre1zCompatPedantic]>;
    198 
    199 def CXX1zCompat : DiagGroup<"c++1z-compat", [DeprecatedRegister,
    200                                              DeprecatedIncrementBool]>;
    201 
    202 def : DiagGroup<"effc++">;
    203 def DivZero : DiagGroup<"division-by-zero">;
    204 def ExitTimeDestructors : DiagGroup<"exit-time-destructors">;
    205 def FlexibleArrayExtensions : DiagGroup<"flexible-array-extensions">;
    206 def FourByteMultiChar : DiagGroup<"four-char-constants">;
    207 def GlobalConstructors : DiagGroup<"global-constructors">;
    208 def BitwiseOpParentheses: DiagGroup<"bitwise-op-parentheses">;
    209 def LogicalOpParentheses: DiagGroup<"logical-op-parentheses">;
    210 def LogicalNotParentheses: DiagGroup<"logical-not-parentheses">;
    211 def ShiftOpParentheses: DiagGroup<"shift-op-parentheses">;
    212 def OverloadedShiftOpParentheses: DiagGroup<"overloaded-shift-op-parentheses">;
    213 def DanglingElse: DiagGroup<"dangling-else">;
    214 def DanglingField : DiagGroup<"dangling-field">;
    215 def DistributedObjectModifiers : DiagGroup<"distributed-object-modifiers">;
    216 def ExpansionToDefined : DiagGroup<"expansion-to-defined">;
    217 def FlagEnum : DiagGroup<"flag-enum">;
    218 def IncrementBool : DiagGroup<"increment-bool", [DeprecatedIncrementBool]>;
    219 def InfiniteRecursion : DiagGroup<"infinite-recursion">;
    220 def GNUImaginaryConstant : DiagGroup<"gnu-imaginary-constant">;
    221 def IgnoredQualifiers : DiagGroup<"ignored-qualifiers">;
    222 def : DiagGroup<"import">;
    223 def GNUIncludeNext : DiagGroup<"gnu-include-next">;
    224 def IncompatibleMSStruct : DiagGroup<"incompatible-ms-struct">;
    225 def IncompatiblePointerTypesDiscardsQualifiers 
    226   : DiagGroup<"incompatible-pointer-types-discards-qualifiers">;
    227 def IncompatiblePointerTypes
    228   : DiagGroup<"incompatible-pointer-types",
    229     [IncompatiblePointerTypesDiscardsQualifiers]>;
    230 def IncompleteUmbrella : DiagGroup<"incomplete-umbrella">;
    231 def NonModularIncludeInFrameworkModule
    232   : DiagGroup<"non-modular-include-in-framework-module">;
    233 def NonModularIncludeInModule : DiagGroup<"non-modular-include-in-module",
    234                                           [NonModularIncludeInFrameworkModule]>;
    235 def IncompleteModule : DiagGroup<"incomplete-module",
    236     [IncompleteUmbrella, NonModularIncludeInModule]>;
    237 
    238 def CXX11InlineNamespace : DiagGroup<"c++11-inline-namespace">;
    239 def InvalidNoreturn : DiagGroup<"invalid-noreturn">;
    240 def InvalidSourceEncoding : DiagGroup<"invalid-source-encoding">;
    241 def KNRPromotedParameter : DiagGroup<"knr-promoted-parameter">;
    242 def : DiagGroup<"init-self">;
    243 def : DiagGroup<"inline">;
    244 def : DiagGroup<"invalid-pch">;
    245 def GNULabelsAsValue : DiagGroup<"gnu-label-as-value">;
    246 def LiteralRange : DiagGroup<"literal-range">;
    247 def LocalTypeTemplateArgs : DiagGroup<"local-type-template-args",
    248                                       [CXX98CompatLocalTypeTemplateArgs]>;
    249 def RangeLoopAnalysis : DiagGroup<"range-loop-analysis">;
    250 def ForLoopAnalysis : DiagGroup<"for-loop-analysis">;
    251 def LoopAnalysis : DiagGroup<"loop-analysis", [ForLoopAnalysis,
    252                                                RangeLoopAnalysis]>;
    253 def MalformedWarningCheck : DiagGroup<"malformed-warning-check">;
    254 def Main : DiagGroup<"main">;
    255 def MainReturnType : DiagGroup<"main-return-type">;
    256 def MissingBraces : DiagGroup<"missing-braces">;
    257 def MissingDeclarations: DiagGroup<"missing-declarations">;
    258 def : DiagGroup<"missing-format-attribute">;
    259 def : DiagGroup<"missing-include-dirs">;
    260 def MissingNoreturn : DiagGroup<"missing-noreturn">;
    261 def MultiChar : DiagGroup<"multichar">;
    262 def : DiagGroup<"nested-externs">;
    263 def CXX11LongLong : DiagGroup<"c++11-long-long">;
    264 def LongLong : DiagGroup<"long-long", [CXX11LongLong]>;
    265 def ImplicitlyUnsignedLiteral : DiagGroup<"implicitly-unsigned-literal">;
    266 def MethodSignatures : DiagGroup<"method-signatures">;
    267 def MismatchedParameterTypes : DiagGroup<"mismatched-parameter-types">;
    268 def MismatchedReturnTypes : DiagGroup<"mismatched-return-types">;
    269 def MismatchedTags : DiagGroup<"mismatched-tags">;
    270 def MissingFieldInitializers : DiagGroup<"missing-field-initializers">;
    271 def ModuleBuild : DiagGroup<"module-build">;
    272 def ModuleConflict : DiagGroup<"module-conflict">;
    273 def ModuleFileExtension : DiagGroup<"module-file-extension">;
    274 def NewlineEOF : DiagGroup<"newline-eof">;
    275 def Nullability : DiagGroup<"nullability">;
    276 def NullabilityDeclSpec : DiagGroup<"nullability-declspec">;
    277 def NullableToNonNullConversion : DiagGroup<"nullable-to-nonnull-conversion">;
    278 def NullabilityCompleteness : DiagGroup<"nullability-completeness">;
    279 def NullArithmetic : DiagGroup<"null-arithmetic">;
    280 def NullCharacter : DiagGroup<"null-character">;
    281 def NullDereference : DiagGroup<"null-dereference">;
    282 def InitializerOverrides : DiagGroup<"initializer-overrides">;
    283 def NonNull : DiagGroup<"nonnull">;
    284 def NonPODVarargs : DiagGroup<"non-pod-varargs">;
    285 def ClassVarargs : DiagGroup<"class-varargs", [NonPODVarargs]>;
    286 def : DiagGroup<"nonportable-cfstrings">;
    287 def NonVirtualDtor : DiagGroup<"non-virtual-dtor">;
    288 def OveralignedType : DiagGroup<"over-aligned">;
    289 def OldStyleCast : DiagGroup<"old-style-cast">;
    290 def : DiagGroup<"old-style-definition">;
    291 def OutOfLineDeclaration : DiagGroup<"out-of-line-declaration">;
    292 def : DiagGroup<"overflow">;
    293 def ForwardClassReceiver : DiagGroup<"receiver-forward-class">;
    294 def MethodAccess : DiagGroup<"objc-method-access">;
    295 def ObjCReceiver : DiagGroup<"receiver-expr">;
    296 def OperatorNewReturnsNull : DiagGroup<"new-returns-null">;
    297 def OverlengthStrings : DiagGroup<"overlength-strings">;
    298 def OverloadedVirtual : DiagGroup<"overloaded-virtual">;
    299 def PrivateExtern : DiagGroup<"private-extern">;
    300 def SelTypeCast : DiagGroup<"cast-of-sel-type">;
    301 def FunctionDefInObjCContainer : DiagGroup<"function-def-in-objc-container">;
    302 def BadFunctionCast : DiagGroup<"bad-function-cast">;
    303 def ObjCPropertyImpl : DiagGroup<"objc-property-implementation">;
    304 def ObjCPropertyNoAttribute : DiagGroup<"objc-property-no-attribute">;
    305 def ObjCProtocolQualifiers : DiagGroup<"objc-protocol-qualifiers">;
    306 def ObjCMissingSuperCalls : DiagGroup<"objc-missing-super-calls">;
    307 def ObjCDesignatedInit : DiagGroup<"objc-designated-initializers">;
    308 def ObjCRetainBlockProperty : DiagGroup<"objc-noncopy-retain-block-property">;
    309 def ObjCReadonlyPropertyHasSetter : DiagGroup<"objc-readonly-with-setter-property">;
    310 def ObjCInvalidIBOutletProperty : DiagGroup<"invalid-iboutlet">;
    311 def ObjCRootClass : DiagGroup<"objc-root-class">;
    312 def ObjCPointerIntrospectPerformSelector : DiagGroup<"deprecated-objc-pointer-introspection-performSelector">;
    313 def ObjCPointerIntrospect : DiagGroup<"deprecated-objc-pointer-introspection", [ObjCPointerIntrospectPerformSelector]>;
    314 def ObjCMultipleMethodNames : DiagGroup<"objc-multiple-method-names">;
    315 def OpenCLUnsupportedRGBA: DiagGroup<"opencl-unsupported-rgba">;
    316 def DeprecatedObjCIsaUsage : DiagGroup<"deprecated-objc-isa-usage">;
    317 def ExplicitInitializeCall : DiagGroup<"explicit-initialize-call">;
    318 def Packed : DiagGroup<"packed">;
    319 def Padded : DiagGroup<"padded">;
    320 def PessimizingMove : DiagGroup<"pessimizing-move">;
    321 def PointerArith : DiagGroup<"pointer-arith">;
    322 def PoundWarning : DiagGroup<"#warnings">;
    323 def PoundPragmaMessage : DiagGroup<"#pragma-messages">,
    324                          DiagCategory<"#pragma message Directive">;
    325 def : DiagGroup<"pointer-to-int-cast">;
    326 def : DiagGroup<"redundant-decls">;
    327 def RedeclaredClassMember : DiagGroup<"redeclared-class-member">;
    328 def GNURedeclaredEnum : DiagGroup<"gnu-redeclared-enum">;
    329 def RedundantMove : DiagGroup<"redundant-move">;
    330 def Register : DiagGroup<"register", [DeprecatedRegister]>;
    331 def ReturnStackAddress : DiagGroup<"return-stack-address">;
    332 def ReturnTypeCLinkage : DiagGroup<"return-type-c-linkage">;
    333 def ReturnType : DiagGroup<"return-type", [ReturnTypeCLinkage]>;
    334 def BindToTemporaryCopy : DiagGroup<"bind-to-temporary-copy",
    335                                     [CXX98CompatBindToTemporaryCopy]>;
    336 def SelfAssignmentField : DiagGroup<"self-assign-field">;
    337 def SelfAssignment : DiagGroup<"self-assign", [SelfAssignmentField]>;
    338 def SelfMove : DiagGroup<"self-move">;
    339 def SemiBeforeMethodBody : DiagGroup<"semicolon-before-method-body">;
    340 def Sentinel : DiagGroup<"sentinel">;
    341 def MissingMethodReturnType : DiagGroup<"missing-method-return-type">;
    342 
    343 def ShadowFieldInConstructorModified : DiagGroup<"shadow-field-in-constructor-modified">;
    344 def ShadowFieldInConstructor : DiagGroup<"shadow-field-in-constructor",
    345                                          [ShadowFieldInConstructorModified]>;
    346 
    347 // -Wshadow-all is a catch-all for all shadowing. -Wshadow is just the
    348 // shadowing that we think is unsafe.
    349 def Shadow : DiagGroup<"shadow", [ShadowFieldInConstructorModified]>;
    350 def ShadowAll : DiagGroup<"shadow-all", [Shadow, ShadowFieldInConstructor]>;
    351 
    352 def Shorten64To32 : DiagGroup<"shorten-64-to-32">;
    353 def : DiagGroup<"sign-promo">;
    354 def SignCompare : DiagGroup<"sign-compare">;
    355 def : DiagGroup<"stack-protector">;
    356 def : DiagGroup<"switch-default">;
    357 def : DiagGroup<"synth">;
    358 def SizeofArrayArgument : DiagGroup<"sizeof-array-argument">;
    359 def SizeofArrayDecay : DiagGroup<"sizeof-array-decay">;
    360 def SizeofPointerMemaccess : DiagGroup<"sizeof-pointer-memaccess">;
    361 def StaticInInline : DiagGroup<"static-in-inline">;
    362 def StaticLocalInInline : DiagGroup<"static-local-in-inline">;
    363 def GNUStaticFloatInit : DiagGroup<"gnu-static-float-init">;
    364 def StaticFloatInit : DiagGroup<"static-float-init", [GNUStaticFloatInit]>;
    365 def GNUStatementExpression : DiagGroup<"gnu-statement-expression">;
    366 def StringCompare : DiagGroup<"string-compare">;
    367 def StringPlusInt : DiagGroup<"string-plus-int">;
    368 def StringPlusChar : DiagGroup<"string-plus-char">;
    369 def StrncatSize : DiagGroup<"strncat-size">;
    370 def TautologicalOutOfRangeCompare : DiagGroup<"tautological-constant-out-of-range-compare">;
    371 def TautologicalPointerCompare : DiagGroup<"tautological-pointer-compare">;
    372 def TautologicalOverlapCompare : DiagGroup<"tautological-overlap-compare">;
    373 def TautologicalUndefinedCompare : DiagGroup<"tautological-undefined-compare">;
    374 def TautologicalCompare : DiagGroup<"tautological-compare",
    375                                     [TautologicalOutOfRangeCompare,
    376                                      TautologicalPointerCompare,
    377                                      TautologicalOverlapCompare,
    378                                      TautologicalUndefinedCompare]>;
    379 def HeaderHygiene : DiagGroup<"header-hygiene">;
    380 def DuplicateDeclSpecifier : DiagGroup<"duplicate-decl-specifier">;
    381 def CompareDistinctPointerType : DiagGroup<"compare-distinct-pointer-types">;
    382 def GNUUnionCast : DiagGroup<"gnu-union-cast">;
    383 def GNUVariableSizedTypeNotAtEnd : DiagGroup<"gnu-variable-sized-type-not-at-end">;
    384 def Varargs : DiagGroup<"varargs">;
    385 
    386 def Unsequenced : DiagGroup<"unsequenced">;
    387 // GCC name for -Wunsequenced
    388 def : DiagGroup<"sequence-point", [Unsequenced]>;
    389 
    390 // Preprocessor warnings.
    391 def AmbiguousMacro : DiagGroup<"ambiguous-macro">;
    392 def KeywordAsMacro : DiagGroup<"keyword-macro">;
    393 def ReservedIdAsMacro : DiagGroup<"reserved-id-macro">;
    394 
    395 // Just silence warnings about -Wstrict-aliasing for now.
    396 def : DiagGroup<"strict-aliasing=0">;
    397 def : DiagGroup<"strict-aliasing=1">;
    398 def : DiagGroup<"strict-aliasing=2">;
    399 def : DiagGroup<"strict-aliasing">;
    400 
    401 // Just silence warnings about -Wstrict-overflow for now.
    402 def : DiagGroup<"strict-overflow=0">;
    403 def : DiagGroup<"strict-overflow=1">;
    404 def : DiagGroup<"strict-overflow=2">;
    405 def : DiagGroup<"strict-overflow=3">;
    406 def : DiagGroup<"strict-overflow=4">;
    407 def : DiagGroup<"strict-overflow=5">;
    408 def : DiagGroup<"strict-overflow">;
    409 
    410 def InvalidOffsetof : DiagGroup<"invalid-offsetof">;
    411 def : DiagGroup<"strict-prototypes">;
    412 def StrictSelector : DiagGroup<"strict-selector-match">;
    413 def MethodDuplicate : DiagGroup<"duplicate-method-match">;
    414 def ObjCCStringFormat : DiagGroup<"cstring-format-directive">;
    415 def CoveredSwitchDefault : DiagGroup<"covered-switch-default">;
    416 def SwitchBool     : DiagGroup<"switch-bool">;
    417 def SwitchEnum     : DiagGroup<"switch-enum">;
    418 def Switch         : DiagGroup<"switch">;
    419 def ImplicitFallthroughPerFunction :
    420   DiagGroup<"implicit-fallthrough-per-function">;
    421 def ImplicitFallthrough  : DiagGroup<"implicit-fallthrough",
    422                                      [ImplicitFallthroughPerFunction]>;
    423 def InvalidPPToken : DiagGroup<"invalid-pp-token">;
    424 def Trigraphs      : DiagGroup<"trigraphs">;
    425 
    426 def : DiagGroup<"type-limits">;
    427 def UndefinedReinterpretCast : DiagGroup<"undefined-reinterpret-cast">;
    428 def ReinterpretBaseClass : DiagGroup<"reinterpret-base-class">;
    429 def Unicode  : DiagGroup<"unicode">;
    430 def UninitializedMaybe : DiagGroup<"conditional-uninitialized">;
    431 def UninitializedSometimes : DiagGroup<"sometimes-uninitialized">;
    432 def UninitializedStaticSelfInit : DiagGroup<"static-self-init">;
    433 def Uninitialized  : DiagGroup<"uninitialized", [UninitializedSometimes,
    434                                                  UninitializedStaticSelfInit]>;
    435 def UnknownPragmas : DiagGroup<"unknown-pragmas">;
    436 def IgnoredPragmas : DiagGroup<"ignored-pragmas">;
    437 def Pragmas : DiagGroup<"pragmas", [UnknownPragmas, IgnoredPragmas]>;
    438 def UnknownWarningOption : DiagGroup<"unknown-warning-option">;
    439 def NSobjectAttribute : DiagGroup<"NSObject-attribute">;
    440 def IndependentClassAttribute : DiagGroup<"IndependentClass-attribute">;
    441 def UnknownAttributes : DiagGroup<"unknown-attributes">;
    442 def IgnoredAttributes : DiagGroup<"ignored-attributes">;
    443 def Attributes : DiagGroup<"attributes", [UnknownAttributes,
    444                                           IgnoredAttributes]>;
    445 def UnknownSanitizers : DiagGroup<"unknown-sanitizers">;
    446 def UnnamedTypeTemplateArgs : DiagGroup<"unnamed-type-template-args",
    447                                         [CXX98CompatUnnamedTypeTemplateArgs]>;
    448 def UnsupportedFriend : DiagGroup<"unsupported-friend">;
    449 def UnusedArgument : DiagGroup<"unused-argument">;
    450 def UnusedCommandLineArgument : DiagGroup<"unused-command-line-argument">;
    451 def IgnoredOptimizationArgument : DiagGroup<"ignored-optimization-argument">;
    452 def InvalidCommandLineArgument : DiagGroup<"invalid-command-line-argument",
    453                                            [IgnoredOptimizationArgument]>;
    454 def UnusedComparison : DiagGroup<"unused-comparison">;
    455 def UnusedExceptionParameter : DiagGroup<"unused-exception-parameter">;
    456 def UnneededInternalDecl : DiagGroup<"unneeded-internal-declaration">;
    457 def UnneededMemberFunction : DiagGroup<"unneeded-member-function">;
    458 def UnusedPrivateField : DiagGroup<"unused-private-field">;
    459 def UnusedFunction : DiagGroup<"unused-function", [UnneededInternalDecl]>;
    460 def UnusedMemberFunction : DiagGroup<"unused-member-function",
    461                                      [UnneededMemberFunction]>;
    462 def UnusedLabel : DiagGroup<"unused-label">;
    463 def UnusedParameter : DiagGroup<"unused-parameter">;
    464 def UnusedResult : DiagGroup<"unused-result">;
    465 def PotentiallyEvaluatedExpression : DiagGroup<"potentially-evaluated-expression">;
    466 def UnevaluatedExpression : DiagGroup<"unevaluated-expression",
    467                                       [PotentiallyEvaluatedExpression]>;
    468 def UnusedValue : DiagGroup<"unused-value", [UnusedComparison, UnusedResult,
    469                                              UnevaluatedExpression]>;
    470 def UnusedConstVariable : DiagGroup<"unused-const-variable">;
    471 def UnusedVariable : DiagGroup<"unused-variable",
    472                                [UnusedConstVariable]>;
    473 def UnusedLocalTypedef : DiagGroup<"unused-local-typedef">;
    474 def UnusedPropertyIvar :  DiagGroup<"unused-property-ivar">;
    475 def UnusedGetterReturnValue : DiagGroup<"unused-getter-return-value">;
    476 def UsedButMarkedUnused : DiagGroup<"used-but-marked-unused">;
    477 def UserDefinedLiterals : DiagGroup<"user-defined-literals">;
    478 def Reorder : DiagGroup<"reorder">;
    479 def UndeclaredSelector : DiagGroup<"undeclared-selector">;
    480 def ImplicitAtomic : DiagGroup<"implicit-atomic-properties">;
    481 def CustomAtomic : DiagGroup<"custom-atomic-properties">;
    482 def AtomicProperties : DiagGroup<"atomic-properties",
    483                                  [ImplicitAtomic, CustomAtomic]>;
    484 def ARCUnsafeRetainedAssign : DiagGroup<"arc-unsafe-retained-assign">;
    485 def ARCRetainCycles : DiagGroup<"arc-retain-cycles">;
    486 def ARCNonPodMemAccess : DiagGroup<"arc-non-pod-memaccess">;
    487 def AutomaticReferenceCounting : DiagGroup<"arc",
    488                                            [ARCUnsafeRetainedAssign,
    489                                             ARCRetainCycles,
    490                                             ARCNonPodMemAccess]>;
    491 def ARCRepeatedUseOfWeakMaybe : DiagGroup<"arc-maybe-repeated-use-of-weak">;
    492 def ARCRepeatedUseOfWeak : DiagGroup<"arc-repeated-use-of-weak",
    493                                      [ARCRepeatedUseOfWeakMaybe]>;
    494 def ObjCBridge : DiagGroup<"bridge-cast">;
    495 
    496 def DeallocInCategory:DiagGroup<"dealloc-in-category">;
    497 def SelectorTypeMismatch : DiagGroup<"selector-type-mismatch">;
    498 def Selector : DiagGroup<"selector", [SelectorTypeMismatch]>;
    499 def Protocol : DiagGroup<"protocol">;
    500 def AtProtocol : DiagGroup<"at-protocol">;
    501 def PropertyAccessDotSyntax: DiagGroup<"property-access-dot-syntax">;
    502 def PropertyAttr : DiagGroup<"property-attribute-mismatch">;
    503 def SuperSubClassMismatch : DiagGroup<"super-class-method-mismatch">;
    504 def OverridingMethodMismatch : DiagGroup<"overriding-method-mismatch">;
    505 def VariadicMacros : DiagGroup<"variadic-macros">;
    506 def VectorConversion : DiagGroup<"vector-conversion">;      // clang specific
    507 def VexingParse : DiagGroup<"vexing-parse">;
    508 def VLA : DiagGroup<"vla">;
    509 def VLAExtension : DiagGroup<"vla-extension">;
    510 def VolatileRegisterVar : DiagGroup<"volatile-register-var">;
    511 def Visibility : DiagGroup<"visibility">;
    512 def ZeroLengthArray : DiagGroup<"zero-length-array">;
    513 def GNUZeroLineDirective : DiagGroup<"gnu-zero-line-directive">;
    514 def GNUZeroVariadicMacroArguments : DiagGroup<"gnu-zero-variadic-macro-arguments">;
    515 def Fallback : DiagGroup<"fallback">;
    516 
    517 // This covers both the deprecated case (in C++98)
    518 // and the extension case (in C++11 onwards).
    519 def WritableStrings : DiagGroup<"writable-strings", [DeprecatedWritableStr]>;
    520 
    521 // GCC calls -Wdeprecated-writable-strings -Wwrite-strings.
    522 //
    523 // Bizarrely, this warning flag enables -fconst-strings in C. This is
    524 // GCC-compatible, but really weird.
    525 //
    526 // FIXME: Should this affect C++11 (where this is an error,
    527 //        not just deprecated) or not?
    528 def GCCWriteStrings : DiagGroup<"write-strings" , [WritableStrings]>;
    529 
    530 def CharSubscript : DiagGroup<"char-subscripts">;
    531 def LargeByValueCopy : DiagGroup<"large-by-value-copy">;
    532 def DuplicateArgDecl : DiagGroup<"duplicate-method-arg">;
    533 
    534 // Unreachable code warning groups.
    535 //
    536 //  The goal is make -Wunreachable-code on by default, in -Wall, or at
    537 //  least actively used, with more noisy versions of the warning covered
    538 //  under separate flags.
    539 //
    540 def UnreachableCodeLoopIncrement : DiagGroup<"unreachable-code-loop-increment">;
    541 def UnreachableCode : DiagGroup<"unreachable-code",
    542                                 [UnreachableCodeLoopIncrement]>;
    543 def UnreachableCodeBreak : DiagGroup<"unreachable-code-break">;
    544 def UnreachableCodeReturn : DiagGroup<"unreachable-code-return">;
    545 def UnreachableCodeAggressive : DiagGroup<"unreachable-code-aggressive",
    546                                     [UnreachableCode,
    547                                      UnreachableCodeBreak,
    548                                      UnreachableCodeReturn]>;
    549 
    550 // Aggregation warning settings.
    551 
    552 // Populate -Waddress with warnings from other groups.
    553 def : DiagGroup<"address", [PointerBoolConversion,
    554                             StringCompare,
    555                             TautologicalPointerCompare]>;
    556 
    557 // -Widiomatic-parentheses contains warnings about 'idiomatic'
    558 // missing parentheses;  it is off by default.  We do not include it
    559 // in -Wparentheses because most users who use -Wparentheses explicitly
    560 // do not want these warnings.
    561 def ParenthesesOnEquality : DiagGroup<"parentheses-equality">;
    562 def Parentheses : DiagGroup<"parentheses",
    563                             [LogicalOpParentheses,
    564                              LogicalNotParentheses,
    565                              BitwiseOpParentheses,
    566                              ShiftOpParentheses,
    567                              OverloadedShiftOpParentheses,
    568                              ParenthesesOnEquality,
    569                              DanglingElse]>;
    570 
    571 // -Wconversion has its own warnings, but we split a few out for
    572 // legacy reasons:
    573 //   - some people want just 64-to-32 warnings
    574 //   - conversion warnings with constant sources are on by default
    575 //   - conversion warnings for literals are on by default
    576 //   - bool-to-pointer conversion warnings are on by default
    577 //   - __null-to-integer conversion warnings are on by default
    578 def Conversion : DiagGroup<"conversion",
    579                            [BoolConversion,
    580                             ConstantConversion,
    581                             EnumConversion,
    582                             FloatConversion,
    583                             Shorten64To32,
    584                             IntConversion,
    585                             LiteralConversion,
    586                             NonLiteralNullConversion, // (1-1)->pointer (etc)
    587                             NullConversion, // NULL->non-pointer
    588                             ObjCLiteralConversion,
    589                             SignConversion,
    590                             StringConversion]>,
    591                  DiagCategory<"Value Conversion Issue">;
    592 
    593 def Unused : DiagGroup<"unused",
    594                        [UnusedArgument, UnusedFunction, UnusedLabel,
    595                         // UnusedParameter, (matches GCC's behavior)
    596                         // UnusedMemberFunction, (clean-up llvm before enabling)
    597                         UnusedPrivateField, UnusedLocalTypedef,
    598                         UnusedValue, UnusedVariable, UnusedPropertyIvar]>,
    599                         DiagCategory<"Unused Entity Issue">;
    600 
    601 // Format settings.
    602 def FormatInvalidSpecifier : DiagGroup<"format-invalid-specifier">;
    603 def FormatSecurity : DiagGroup<"format-security">;
    604 def FormatNonStandard : DiagGroup<"format-non-iso">;
    605 def FormatY2K : DiagGroup<"format-y2k">;
    606 def FormatPedantic : DiagGroup<"format-pedantic">;
    607 def Format : DiagGroup<"format",
    608                        [FormatExtraArgs, FormatZeroLength, NonNull,
    609                         FormatSecurity, FormatY2K, FormatInvalidSpecifier]>,
    610              DiagCategory<"Format String Issue">;
    611 def FormatNonLiteral : DiagGroup<"format-nonliteral">;
    612 def Format2 : DiagGroup<"format=2",
    613                         [FormatNonLiteral, FormatSecurity, FormatY2K]>;
    614 
    615 def TypeSafety : DiagGroup<"type-safety">;
    616 
    617 def IntToVoidPointerCast : DiagGroup<"int-to-void-pointer-cast">;
    618 def IntToPointerCast : DiagGroup<"int-to-pointer-cast",
    619                                  [IntToVoidPointerCast]>;
    620 
    621 def Move : DiagGroup<"move", [PessimizingMove, RedundantMove, SelfMove]>;
    622 
    623 def Extra : DiagGroup<"extra", [
    624     MissingFieldInitializers,
    625     IgnoredQualifiers,
    626     InitializerOverrides,
    627     SemiBeforeMethodBody,
    628     MissingMethodReturnType,
    629     SignCompare,
    630     UnusedParameter
    631   ]>;
    632 
    633 def Most : DiagGroup<"most", [
    634     CharSubscript,
    635     Comment,
    636     DeleteNonVirtualDtor,
    637     ForLoopAnalysis,
    638     Format,
    639     Implicit,
    640     InfiniteRecursion,
    641     MismatchedTags,
    642     MissingBraces,
    643     Move,
    644     MultiChar,
    645     Reorder,
    646     ReturnType,
    647     SelfAssignment,
    648     SelfMove,
    649     SizeofArrayArgument,
    650     SizeofArrayDecay,
    651     StringPlusInt,
    652     Trigraphs,
    653     Uninitialized,
    654     UnknownPragmas,
    655     Unused,
    656     VolatileRegisterVar,
    657     ObjCMissingSuperCalls,
    658     ObjCDesignatedInit,
    659     OverloadedVirtual,
    660     PrivateExtern,
    661     SelTypeCast,
    662     ExternCCompat
    663  ]>;
    664 
    665 // Thread Safety warnings 
    666 def ThreadSafetyAttributes : DiagGroup<"thread-safety-attributes">;
    667 def ThreadSafetyAnalysis   : DiagGroup<"thread-safety-analysis">;
    668 def ThreadSafetyPrecise    : DiagGroup<"thread-safety-precise">;
    669 def ThreadSafetyReference  : DiagGroup<"thread-safety-reference">;
    670 def ThreadSafetyNegative   : DiagGroup<"thread-safety-negative">;
    671 def ThreadSafety : DiagGroup<"thread-safety",
    672                              [ThreadSafetyAttributes, 
    673                               ThreadSafetyAnalysis,
    674                               ThreadSafetyPrecise,
    675                               ThreadSafetyReference]>;
    676 def ThreadSafetyVerbose : DiagGroup<"thread-safety-verbose">;
    677 def ThreadSafetyBeta : DiagGroup<"thread-safety-beta">;
    678 
    679 // Uniqueness Analysis warnings
    680 def Consumed       : DiagGroup<"consumed">;
    681 
    682 // Note that putting warnings in -Wall will not disable them by default. If a
    683 // warning should be active _only_ when -Wall is passed in, mark it as
    684 // DefaultIgnore in addition to putting it here.
    685 def All : DiagGroup<"all", [Most, Parentheses, Switch, SwitchBool]>;
    686 
    687 // Warnings that should be in clang-cl /w4.
    688 def : DiagGroup<"CL4", [All, Extra]>;
    689 
    690 // Warnings enabled by -pedantic.  This is magically filled in by TableGen.
    691 def Pedantic : DiagGroup<"pedantic">;
    692 
    693 // Aliases.
    694 def : DiagGroup<"", [Extra]>;                   // -W = -Wextra
    695 def : DiagGroup<"endif-labels", [ExtraTokens]>; // -Wendif-labels=-Wextra-tokens
    696 def : DiagGroup<"comments", [Comment]>;         // -Wcomments = -Wcomment
    697 def : DiagGroup<"conversion-null",
    698                 [NullConversion]>; // -Wconversion-null = -Wnull-conversion
    699 def : DiagGroup<"bool-conversions",
    700                 [BoolConversion]>; // -Wbool-conversions  = -Wbool-conversion
    701 def : DiagGroup<"int-conversions",
    702                 [IntConversion]>; // -Wint-conversions = -Wint-conversion
    703 def : DiagGroup<"vector-conversions",
    704                 [VectorConversion]>; // -Wvector-conversions = -Wvector-conversion
    705 def : DiagGroup<"unused-local-typedefs", [UnusedLocalTypedef]>;
    706                 // -Wunused-local-typedefs = -Wunused-local-typedef
    707 
    708 // A warning group for warnings that we want to have on by default in clang,
    709 // but which aren't on by default in GCC.
    710 def NonGCC : DiagGroup<"non-gcc",
    711     [SignCompare, Conversion, LiteralRange]>;
    712 
    713 // A warning group for warnings about using C++11 features as extensions in
    714 // earlier C++ versions.
    715 def CXX11 : DiagGroup<"c++11-extensions", [CXX11ExtraSemi, CXX11InlineNamespace,
    716                                            CXX11LongLong]>;
    717 
    718 // A warning group for warnings about using C++14 features as extensions in
    719 // earlier C++ versions.
    720 def CXX14 : DiagGroup<"c++14-extensions", [CXX14BinaryLiteral]>;
    721 
    722 // A warning group for warnings about using C++1z features as extensions in
    723 // earlier C++ versions.
    724 def CXX1z : DiagGroup<"c++1z-extensions">;
    725 
    726 def : DiagGroup<"c++0x-extensions", [CXX11]>;
    727 def : DiagGroup<"c++1y-extensions", [CXX14]>;
    728 
    729 def DelegatingCtorCycles :
    730   DiagGroup<"delegating-ctor-cycles">;
    731 
    732 // A warning group for warnings about using C11 features as extensions.
    733 def C11 : DiagGroup<"c11-extensions">;
    734 
    735 // A warning group for warnings about using C99 features as extensions.
    736 def C99 : DiagGroup<"c99-extensions">;
    737 
    738 // A warning group for warnings about GCC extensions.
    739 def GNU : DiagGroup<"gnu", [GNUAlignofExpression, GNUAnonymousStruct,
    740                             GNUAutoType,
    741                             GNUBinaryLiteral, GNUCaseRange,
    742                             GNUComplexInteger, GNUCompoundLiteralInitializer,
    743                             GNUConditionalOmittedOperand, GNUDesignator,
    744                             GNUEmptyInitializer, GNUEmptyStruct,
    745                             VLAExtension, GNUFlexibleArrayInitializer,
    746                             GNUFlexibleArrayUnionMember, GNUFoldingConstant,
    747                             GNUImaginaryConstant, GNUIncludeNext,
    748                             GNULabelsAsValue,
    749                             RedeclaredClassMember, GNURedeclaredEnum,
    750                             GNUStatementExpression, GNUStaticFloatInit,
    751                             GNUStringLiteralOperatorTemplate,
    752                             GNUUnionCast, GNUVariableSizedTypeNotAtEnd,
    753                             ZeroLengthArray, GNUZeroLineDirective,
    754                             GNUZeroVariadicMacroArguments]>;
    755 // A warning group for warnings about code that clang accepts but gcc doesn't.
    756 def GccCompat : DiagGroup<"gcc-compat">;
    757 
    758 // Warnings for Microsoft extensions.
    759 def MicrosoftCharize : DiagGroup<"microsoft-charize">;
    760 def MicrosoftInclude : DiagGroup<"microsoft-include">;
    761 def MicrosoftCppMacro : DiagGroup<"microsoft-cpp-macro">;
    762 def MicrosoftFixedEnum : DiagGroup<"microsoft-fixed-enum">;
    763 def MicrosoftSealed : DiagGroup<"microsoft-sealed">;
    764 def MicrosoftUnqualifiedFriend : DiagGroup<"microsoft-unqualified-friend">;
    765 def MicrosoftExceptionSpec : DiagGroup<"microsoft-exception-spec">;
    766 def MicrosoftUsingDecl : DiagGroup<"microsoft-using-decl">;
    767 def MicrosoftMutableReference : DiagGroup<"microsoft-mutable-reference">;
    768 def MicrosoftPureDefinition : DiagGroup<"microsoft-pure-definition">;
    769 def MicrosoftUnionMemberReference : DiagGroup<
    770     "microsoft-union-member-reference">;
    771 def MicrosoftExplicitConstructorCall : DiagGroup<
    772     "microsoft-explicit-constructor-call">;
    773 def MicrosoftEnumValue : DiagGroup<"microsoft-enum-value">;
    774 def MicrosoftDefaultArgRedefinition :
    775     DiagGroup<"microsoft-default-arg-redefinition">;
    776 def MicrosoftTemplate : DiagGroup<"microsoft-template">;
    777 def MicrosoftInconsistentDllImport : DiagGroup<"inconsistent-dllimport">;
    778 def MicrosoftRedeclareStatic : DiagGroup<"microsoft-redeclare-static">;
    779 def MicrosoftEnumForwardReference :
    780     DiagGroup<"microsoft-enum-forward-reference">;
    781 def MicrosoftGoto : DiagGroup<"microsoft-goto">;
    782 def MicrosoftFlexibleArray : DiagGroup<"microsoft-flexible-array">;
    783 def MicrosoftExtraQualification : DiagGroup<"microsoft-extra-qualification">;
    784 def MicrosoftCast : DiagGroup<"microsoft-cast">;
    785 def MicrosoftConstInit : DiagGroup<"microsoft-const-init">;
    786 def MicrosoftVoidPseudoDtor : DiagGroup<"microsoft-void-pseudo-dtor">;
    787 def MicrosoftAnonTag : DiagGroup<"microsoft-anon-tag">;
    788 def MicrosoftCommentPaste : DiagGroup<"microsoft-comment-paste">;
    789 def MicrosoftEndOfFile : DiagGroup<"microsoft-end-of-file">;
    790 // Aliases.
    791 def : DiagGroup<"msvc-include", [MicrosoftInclude]>;
    792                 // -Wmsvc-include = -Wmicrosoft-include
    793 
    794 // Warnings group for warnings about Microsoft extensions.
    795 def Microsoft : DiagGroup<"microsoft",
    796     [MicrosoftCharize, MicrosoftInclude, MicrosoftCppMacro, MicrosoftFixedEnum,
    797      MicrosoftSealed, MicrosoftUnqualifiedFriend, MicrosoftExceptionSpec,
    798      MicrosoftUsingDecl, MicrosoftMutableReference, MicrosoftPureDefinition,
    799      MicrosoftUnionMemberReference, MicrosoftExplicitConstructorCall,
    800      MicrosoftEnumValue, MicrosoftDefaultArgRedefinition, MicrosoftTemplate,
    801      MicrosoftRedeclareStatic, MicrosoftEnumForwardReference, MicrosoftGoto,
    802      MicrosoftFlexibleArray, MicrosoftExtraQualification, MicrosoftCast,
    803      MicrosoftConstInit, MicrosoftVoidPseudoDtor, MicrosoftAnonTag,
    804      MicrosoftCommentPaste, MicrosoftEndOfFile,
    805      MicrosoftInconsistentDllImport]>;
    806 
    807 def ClangClPch : DiagGroup<"clang-cl-pch">;
    808 
    809 def ObjCNonUnifiedException : DiagGroup<"objc-nonunified-exceptions">;
    810 
    811 def ObjCProtocolMethodImpl : DiagGroup<"objc-protocol-method-implementation">;
    812 
    813 def ObjCNoPropertyAutoSynthesis : DiagGroup<"objc-property-synthesis">;
    814 
    815 // ObjC API warning groups.
    816 def ObjCRedundantLiteralUse : DiagGroup<"objc-redundant-literal-use">;
    817 def ObjCRedundantAPIUse : DiagGroup<"objc-redundant-api-use", [
    818     ObjCRedundantLiteralUse
    819   ]>;
    820 
    821 def ObjCCocoaAPI : DiagGroup<"objc-cocoa-api", [
    822     ObjCRedundantAPIUse
    823   ]>;
    824 
    825 def ObjCStringComparison : DiagGroup<"objc-string-compare">;
    826 def ObjCStringConcatenation : DiagGroup<"objc-string-concatenation">;
    827 def ObjCLiteralComparison : DiagGroup<"objc-literal-compare", [
    828     ObjCStringComparison
    829   ]>;
    830 
    831 // Inline ASM warnings.
    832 def ASMOperandWidths : DiagGroup<"asm-operand-widths">;
    833 def ASM : DiagGroup<"asm", [
    834     ASMOperandWidths
    835   ]>;
    836 
    837 // OpenMP warnings.
    838 def SourceUsesOpenMP : DiagGroup<"source-uses-openmp">;
    839 def OpenMPClauses : DiagGroup<"openmp-clauses">;
    840 def OpenMPLoopForm : DiagGroup<"openmp-loop-form">;
    841 def OpenMPTarget : DiagGroup<"openmp-target">;
    842 
    843 // Backend warnings.
    844 def BackendInlineAsm : DiagGroup<"inline-asm">;
    845 def BackendFrameLargerThanEQ : DiagGroup<"frame-larger-than=">;
    846 def BackendPlugin : DiagGroup<"backend-plugin">;
    847 def RemarkBackendPlugin : DiagGroup<"remark-backend-plugin">;
    848 def BackendOptimizationRemark : DiagGroup<"pass">;
    849 def BackendOptimizationRemarkMissed : DiagGroup<"pass-missed">;
    850 def BackendOptimizationRemarkAnalysis : DiagGroup<"pass-analysis">;
    851 def BackendOptimizationFailure : DiagGroup<"pass-failed">;
    852 
    853 // Instrumentation based profiling warnings.
    854 def ProfileInstrOutOfDate : DiagGroup<"profile-instr-out-of-date">;
    855 def ProfileInstrUnprofiled : DiagGroup<"profile-instr-unprofiled">;
    856 
    857 // AddressSanitizer frontent instrumentation remarks.
    858 def SanitizeAddressRemarks : DiagGroup<"sanitize-address">;
    859 
    860 // Issues with serialized diagnostics.
    861 def SerializedDiagnostics : DiagGroup<"serialized-diagnostics">;
    862 
    863 // A warning group for warnings about code that clang accepts when
    864 // compiling CUDA C/C++ but which is not compatible with the CUDA spec.
    865 def CudaCompat : DiagGroup<"cuda-compat">;
    866 
    867 // A warning group for things that will change semantics in the future.
    868 def FutureCompat : DiagGroup<"future-compat">;
    869 
    870 def InvalidOrNonExistentDirectory : DiagGroup<"invalid-or-nonexistent-directory">;
    871 
    872 def OptionIgnored : DiagGroup<"option-ignored">;
    873 
    874 def UnknownArgument : DiagGroup<"unknown-argument">;
    875