Module:ClangDiags/DiagsLongData0
Jump to navigation
Jump to search
Documentation for this module may be created at Module:ClangDiags/DiagsLongData0/doc
local a=""; local b="commit"; local c="id_hist"; local d="message_hist"; local e="hierarchical_hist"; local f="regex1"; local g="regex2"; local h="regex3"; local i="category_hist"; local j="source"; local k="(?:error|fatal error)\\: "; local l="tests2"; local m="Semantic Issue"; local n="clang/lib/Sema/SemaDeclAttr.cpp"; local o="clang/lib/Sema/SemaDecl.cpp"; local p="clang/lib/Sema/SemaType.cpp"; local q="11.0"; local r="12.0"; local s="10.0"; local t="clang/lib/Sema/SemaChecking.cpp"; local u="Update tablegen diagnostic files to be in sync with the def files.\n\nllvm-svn: 67004"; local v="5a8987ca5113"; local w="Update tablegen diagnostic files to be in sync with the def files."; local x="14.0"; local y="13.0"; local z="Inline Assembly Issue"; local A="7.0"; local B="8.0"; local C="clang/lib/Sema/SemaStmtAsm.cpp"; local D="clang/lib/Sema/SemaExprCXX.cpp"; local E="15.0"; local F="Automatic Reference Counting.\n\nLanguage-design credit goes to a lot of people, but I particularly want\nto single out Blaine Garst and Patrick Beard for their contributions.\n\nCompiler implementation credit goes to Argyrios, Doug, Fariborz, and myself,\nin no particular order.\n\nllvm-svn: 133103"; local G="31168b077c36"; local H="Automatic Reference Counting."; local I="16.0"; local J="ARC Semantic Issue"; local K="9.0"; local L="clang/lib/Sema/SemaInit.cpp"; local M="clang/lib/Sema/SemaDeclCXX.cpp"; local N="b1c4d5507fad"; local O="The basic representation of diagnostics information in tablegen format, plus (uncommented and incomp..."; local P="The basic representation of diagnostics information in tablegen format, plus (uncommented and incomplete) test conversions of the existing def files to this format.\n\nllvm-svn: 66064"; local Q="private"; local R="protected"; local S="clang/lib/Sema/SemaExprObjC.cpp"; local T="5.0"; local U="clang/test/Sema/asm.c"; local V="Parse Issue"; local W="None"; local X="6.0"; local Y="clang/lib/Sema/SemaExpr.cpp"; local Z="clang/lib/Sema/SemaOverload.cpp"; local ab="clang/lib/Sema/SemaAccess.cpp"; local bb="clang/lib/Frontend/CompilerInvocation.cpp"; local cb="clang/lib/ARCMigrate/TransProperties.cpp"; local db="clang/lib/Parse/ParseDeclCXX.cpp"; local eb="95f50964fbf5"; local fb="Rename objc_lifetime -> objc_ownership, and modify diagnostics to talk about \'ownership\', not \'lifet..."; local gb="Implement P2361 Unevaluated string literals"; local hb="Implement P2361 Unevaluated string literals\n\nThis patch proposes to handle in an uniform fashion\nthe parsing of strings that are never evaluated,\nin asm statement, static assert, attrributes, extern,\netc.\n\nUnevaluated strings are UTF-8 internally and so currently\nbehave as narrow strings, but these things will diverge with\nD93031.\n\nThe big question both for this patch and the P2361 paper\nis whether we risk breaking code by disallowing\nencoding prefixes in this context.\nI hope this patch may allow to gather some data on that.\n\nFuture work:\nImprove the rendering of unicode characters, line break\nand so forth in static-assert messages\n\nReviewed By: aaron.ballman, shafik\n\nDifferential Revision: https://reviews.llvm.org/D105759"; local ib="clang/lib/Sema/SemaDeclObjC.cpp"; local jb="cff00d9c127c"; local kb="Rename objc_lifetime -> objc_ownership, and modify diagnostics to talk about \'ownership\', not \'lifetime\'.\n\nrdar://9477613.\n\nllvm-svn: 133779"; local lb="clang/lib/ARCMigrate/TransUnbridgedCasts.cpp"; local mb="clang/lib/Sema/SemaObjCProperty.cpp"; local nb="clang/test/SemaObjC/arc.m"; local ob="ARC Restrictions"; local pb="clang/lib/AST/Stmt.cpp"; local qb="atomic "; local rb=" destructor"; local sb="14f6bfcb52e7"; local tb="1064d7ef2992"; local ub="Perform access control for the implicit base and member destructor calls"; local vb="Perform access control for the implicit base and member destructor calls\nrequired when emitting a destructor definition.\n\nllvm-svn: 98609"; local wb="ARC Weak References"; local xb="[clang] Implement objc_non_runtime_protocol to remove protocol metadata\n\nSummary:\nMotivated by the new objc_direct attribute, this change adds a new\nattribute that remotes metadata from Protocols that the programmer knows\nisn\'t going to be used at runtime. We simply have the frontend skip\ngenerating any protocol metadata entries (e.g. OBJC_CLASS_NAME,\n_OBJC_$_PROTOCOL_INSTANCE_METHDOS, _OBJC_PROTOCOL, etc) for a protocol\nmarked with `__attribute__((objc_non_runtime_protocol))`.\n\nThere are a few APIs used to retrieve a protocol at runtime.\n`@protocol(SomeProtocol)` will now error out of the requested protocol\nis marked with attribute. `objc_getProtocol` will return `NULL` which\nis consistent with the behavior of a non-existing protocol.\n\nSubscribers: cfe-commits\n\nTags: #clang\n\nDifferential Revision: https://reviews.llvm.org/D75574"; local yb="union"; local zb="struct"; local Ab="[clang] Implement objc_non_runtime_protocol to remove protocol metadata"; local Bb="clang/lib/Parse/ParseDecl.cpp"; local Cb="C"; local Db="clang/test/ARCMT/checking.m"; local Eb="4593e4131aff"; local Fb="931fcd3ba011"; local Gb="[WebAssembly] Improve clang diagnostics for wasm attributes"; local Hb="[WebAssembly] Improve clang diagnostics for wasm attributes\n\nThis patch addresses the review comments on r352930:\n\n - Removes redundant diagnostic checking code\n - Removes errnoneous use of diag::err_alias_is_definition, which\n turned out to be ineffective anyway since functions can be defined later\n in the translation unit and avoid detection.\n - Adds a test for various invalid cases for import_name and import_module.\n\nDifferential Revision: https://reviews.llvm.org/D59520"; local Ib="AMDGPU: Teach toolchain to link rocm device libs\n\nCurrently the library is separately linked, but this isn\'t correct to\nimplement fast math flags correctly. Each module should get the\nversion of the library appropriate for its combination of fast math\nand related flags, with the attributes propagated into its functions\nand internalized.\n\nHIP already maintains the list of libraries, but this is not used for\nOpenCL. Unfortunately, HIP uses a separate --hip-device-lib argument,\ndespite both languages using the same bitcode library. Eventually\nthese two searches need to be merged.\n\nAn additional problem is there are 3 different locations the libraries\nare installed, depending on which build is used. This also needs to be\nconsolidated (or at least the search logic needs to deal with this\nunnecessary complexity)."; local Jb="Objective-C"; local Kb="clang/lib/Lex/Pragma.cpp"; local Lb="block"; local Mb="AMDGPU: Teach toolchain to link rocm device libs"; return { ["backslash_newline_space"]={ ["groups"]={"backslash-newline-escape"}, ["maingroup"]="backslash-newline-escape", [c]="backslash_newline_space", [d]="backslash and newline separated by space", [e]="backslash and newline separated by space", [f]="(?:warning|error|fatal error)\\: ", [g]="backslash and newline separated by space", [h]=" \\[(?:\\-Werror,)?\\-Wbackslash\\-newline\\-escape[^\\]]*\\]", [i]="Lexical or Preprocessor Issue", [b]={N,1236199783,O,P}, [j]={{"clang/lib/Lex/Lexer.cpp",1359,"/// getCharAndSizeSlow - Peek a single \'character\' from the specified buffer,\n/// get its size, and return it. This is tricky in several cases:\n/// 1. If currently at the start of a trigraph, we warn about the trigraph,\n/// then either return the trigraph (skipping 3 chars) or the \'?\',\n/// depending on whether trigraphs are enabled or not.\n/// 2. If this is an escaped newline (potentially with whitespace between\n/// the backslash and newline), implicitly skip the newline and return\n/// the char after it.\n///\n/// This handles the slow/uncommon case of the getCharAndSize method. Here we\n/// know that we can accumulate into Size, and that we have already incremented\n/// Ptr by Size bytes.\n///\n/// NOTE: When this method is updated, getCharAndSizeSlowNoWarn (below) should\n/// be updated to match.\nchar Lexer::getCharAndSizeSlow(const char *Ptr, unsigned &Size, Token *Tok) {\n // ...\n Slash:\n // ...\n // See if we have optional whitespace characters between the slash and\n // newline.\n if (unsigned EscapedNewLineSize = getEscapedNewLineSize(Ptr)) {\n // ...\n // Warn if there was whitespace between the backslash and newline.\n if (Ptr[0] != \'\\n\' && Ptr[0] != \'\\r\' && Tok && !isLexingRawMode())\n Diag(Ptr, diag::backslash_newline_space);"},{"clang/lib/Lex/Lexer.cpp",2511,"/// We have just read the // characters from input. Skip until we find the\n/// newline character that terminates the comment. Then update BufferPtr and\n/// return.\n///\n/// If we\'re in KeepCommentMode or any CommentHandler has inserted\n/// some tokens, this will store the first token and return true.\nbool Lexer::SkipLineComment(Token &Result, const char *CurPtr, bool &TokAtPhysicalStartOfLine) {\n // ...\n while (true) {\n // ...\n if (C != 0) {\n // ...\n // If there was space between the backslash and newline, warn about it.\n if (HasSpace && !isLexingRawMode())\n Diag(EscapePtr, diag::backslash_newline_space);"},{"clang/lib/Lex/Lexer.cpp",2699,"/// isBlockCommentEndOfEscapedNewLine - Return true if the specified newline\n/// character (either \\\\n or \\\\r) is part of an escaped newline sequence. Issue\n/// a diagnostic if so. We know that the newline is inside of a block comment.\nstatic bool isEndOfBlockCommentWithEscapedNewLine(const char *CurPtr, Lexer *L, bool Trigraphs) {\n // ...\n // If there was space between the backslash and newline, warn about it.\n if (SpacePos && !L->isLexingRawMode())\n L->Diag(SpacePos, diag::backslash_newline_space);"}}, [l]={ ["clang/test/Preprocessor/c99-6_10_3_4_p6.c"]={"clang/test/Preprocessor/c99-6_10_3_4_p6.c:7:57: warning: backslash and newline separated by space [-Wbackslash-newline-escape]"} } }, ["err_32_bit_builtin_64_bit_tgt"]={ [c]={{nil,A,"err_32_bit_builtin_64_bit_tgt"}}, [d]={{nil,A,"this builtin is only available on 32-bit targets"}}, [e]={{nil,A,"this builtin is only available on 32-bit targets"}}, [f]=k, [g]="this builtin is only available on 32\\-bit targets", [h]=a, [i]={{nil,A,m}}, [b]={"51738f834ed9",1524773686,"[X86] Make __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32 only available on 32-bit...","[X86] Make __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32 only available on 32-bit targets.\n\nThese builtins can\'t be handled by the backend on 64-bit targets. So error up front instead of throwing an isel error.\n\nFixes PR37225\n\nDifferential Revision: https://reviews.llvm.org/D46132\n\nllvm-svn: 330987"}, [j]={{t,5982,"bool Sema::CheckX86BuiltinFunctionCall(const TargetInfo &TI, unsigned BuiltinID, CallExpr *TheCall) {\n // ...\n if (TT.getArch() != llvm::Triple::x86 && isX86_32Builtin(BuiltinID))\n return Diag(TheCall->getCallee()->getBeginLoc(), diag::err_32_bit_builtin_64_bit_tgt);"}}, [l]={ ["clang/test/Sema/builtins-x86.c"]={"clang/test/Sema/builtins-x86.c:20:9: error: this builtin is only available on 32-bit targets","clang/test/Sema/builtins-x86.c:21:9: error: this builtin is only available on 32-bit targets"} } }, ["err_64_bit_builtin_32_bit_tgt"]={ [c]="err_64_bit_builtin_32_bit_tgt", [d]="this builtin is only available on 64-bit targets", [e]="this builtin is only available on 64-bit targets", [f]=k, [g]="this builtin is only available on 64\\-bit targets", [h]=a, [i]=m, [b]={"239eec732ebf",1428623896,"Add Clang support for remaining integer divide and permute instructions from ISA 2.06","Add Clang support for remaining integer divide and permute instructions from ISA 2.06\n\nThis patch corresponds to review:\nhttp://reviews.llvm.org/D8398\n\nIt adds some builtin functions to access the extended divide and bit permute instructions.\n\nllvm-svn: 234547"}, [j]={{t,4249,"bool Sema::CheckPPCBuiltinFunctionCall(const TargetInfo &TI, unsigned BuiltinID, CallExpr *TheCall) {\n // ...\n if (isPPC_64Builtin(BuiltinID) && !IsTarget64Bit)\n return Diag(TheCall->getBeginLoc(), diag::err_64_bit_builtin_32_bit_tgt) << TheCall->getSourceRange();"}}, [l]={ ["clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c"]={"clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:87:10: error: this builtin is only available on 64-bit targets","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:91:10: error: this builtin is only available on 64-bit targets","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:95:10: error: this builtin is only available on 64-bit targets","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:99:10: error: this builtin is only available on 64-bit targets","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:103:10: error: this builtin is only available on 64-bit targets","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:107:10: error: this builtin is only available on 64-bit targets","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:111:3: error: this builtin is only available on 64-bit targets","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:115:3: error: this builtin is only available on 64-bit targets","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:118:3: error: this builtin is only available on 64-bit targets","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:122:3: error: this builtin is only available on 64-bit targets"} } }, ["err__Pragma_malformed"]={ [c]="err__Pragma_malformed", [d]="_Pragma takes a parenthesized string literal", [e]="_Pragma takes a parenthesized string literal", [f]=k, [g]="_Pragma takes a parenthesized string literal", [h]=a, [i]="Lexical or Preprocessor Issue", [b]={N,1236199783,O,P}, [j]={{Kb,219,"/// Handle_Pragma - Read a _Pragma directive, slice it up, process it, then\n/// return the first token after the directive. The _Pragma token has just\n/// been read into \'Tok\'.\nvoid Preprocessor::Handle_Pragma(Token &Tok) {\n // ...\n if (Tok.isNot(tok::l_paren)) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"},{Kb,226,"/// Handle_Pragma - Read a _Pragma directive, slice it up, process it, then\n/// return the first token after the directive. The _Pragma token has just\n/// been read into \'Tok\'.\nvoid Preprocessor::Handle_Pragma(Token &Tok) {\n // ...\n if (!tok::isStringLiteral(Tok.getKind())) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"},{Kb,254,"/// Handle_Pragma - Read a _Pragma directive, slice it up, process it, then\n/// return the first token after the directive. The _Pragma token has just\n/// been read into \'Tok\'.\nvoid Preprocessor::Handle_Pragma(Token &Tok) {\n // ...\n if (Tok.isNot(tok::r_paren)) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"},{Kb,270,"/// Handle_Pragma - Read a _Pragma directive, slice it up, process it, then\n/// return the first token after the directive. The _Pragma token has just\n/// been read into \'Tok\'.\nvoid Preprocessor::Handle_Pragma(Token &Tok) {\n // ...\n if (Invalid) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"},{Kb,370,"/// HandleMicrosoft__pragma - Like Handle_Pragma except the pragma text\n/// is not enclosed within a string literal.\nvoid Preprocessor::HandleMicrosoft__pragma(Token &Tok) {\n // ...\n if (Tok.isNot(tok::l_paren)) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"}}, [l]={ ["clang/test/Preprocessor/_Pragma.c"]={"clang/test/Preprocessor/_Pragma.c:15:1: error: _Pragma takes a parenthesized string literal","clang/test/Preprocessor/_Pragma.c:17:1: error: _Pragma takes a parenthesized string literal","clang/test/Preprocessor/_Pragma.c:19:1: error: _Pragma takes a parenthesized string literal"} } }, ["err_abi_tag_on_redeclaration"]={ [c]="err_abi_tag_on_redeclaration", [d]="cannot add \'abi_tag\' attribute in a redeclaration", [e]="cannot add \'abi_tag\' attribute in a redeclaration", [f]=k, [g]="cannot add \'abi_tag\' attribute in a redeclaration", [h]=a, [i]=m, [b]={"bf17ecf59a9b",1457537453,"[GCC] PR23529 Sema part of attrbute abi_tag support","[GCC] PR23529 Sema part of attrbute abi_tag support\n\nOriginal patch by Stefan Bühler http://reviews.llvm.org/D12834\n\nDifference between original and this one:\n- fixed all comments in original code review\n- added more tests, all new diagnostics now covered by tests\n- moved abi_tag on re-declaration checks to Sema::mergeDeclAttributes\n where they actually may work as designed\n- clang-format + other stylistic changes\n\nMangle part will be sent for review as a separate patch.\n\nDifferential Revision: http://reviews.llvm.org/D17567\n\nllvm-svn: 263015"}, [j]={{o,3263,"/// mergeDeclAttributes - Copy attributes from the Old decl to the New one.\nvoid Sema::mergeDeclAttributes(NamedDecl *New, Decl *Old, AvailabilityMergeKind AMK) {\n // ...\n // Re-declaration cannot add abi_tag\'s.\n if (const auto *NewAbiTagAttr = New->getAttr<AbiTagAttr>()) {\n if (const auto *OldAbiTagAttr = Old->getAttr<AbiTagAttr>()) {\n // ...\n } else {\n Diag(NewAbiTagAttr->getLocation(), diag::err_abi_tag_on_redeclaration);"}}, [l]={ ["clang/test/SemaCXX/attr-abi-tag-syntax.cpp"]={"clang/test/SemaCXX/attr-abi-tag-syntax.cpp:32:16: error: cannot add \'abi_tag\' attribute in a redeclaration"} } }, ["err_abstract_type_in_decl"]={ [c]="err_abstract_type_in_decl", [d]="%select{return|parameter|variable|field|instance variable|synthesized instance variable}0 type %1 is an abstract class", [e]={{nil,nil,{{"return","parameter","variable","field","instance variable","synthesized instance variable"}," type B is an abstract class"}}}, [f]=k, [g]="(?:return|parameter|variable|field|instance variable|synthesized instance variable) type (.*?) is an abstract class", [h]=a, [i]=m, [b]={"576cc6f725a8",1237753097,"Disallow abstract types where appropriate.","Disallow abstract types where appropriate.\n\nllvm-svn: 67476"}, [j]={{t,16642,"/// CheckParmsForFunctionDef - Check that the parameters of the given\n/// function are appropriate for the definition of a function. This\n/// takes care of any checks that cannot be performed on the\n/// declaration itself, e.g., that the types of each of the function\n/// parameters are complete.\nbool Sema::CheckParmsForFunctionDef(ArrayRef<ParmVarDecl *> Parameters, bool CheckParameterNames) {\n // ...\n for (ParmVarDecl *Param : Parameters) {\n // ...\n if (!Param->isInvalidDecl() && (RequireCompleteType(Param->getLocation(), Param->getType(), diag::err_typecheck_decl_incomplete_type) || RequireNonAbstractType(Param->getBeginLoc(), Param->getOriginalType(), diag::err_abstract_type_in_decl, AbstractParamType))) {"},{o,13209,"/// AddInitializerToDecl - Adds the initializer Init to the\n/// declaration dcl. If DirectInit is true, this is C++ direct\n/// initialization rather than copy initialization.\nvoid Sema::AddInitializerToDecl(Decl *RealDecl, Expr *Init, bool DirectInit) {\n // ...\n if (!VDecl->getType()->isDependentType()) {\n // ...\n if (RequireNonAbstractType(VDecl->getLocation(), VDecl->getType(), diag::err_abstract_type_in_decl, AbstractVariableType))"},{o,13643,"/// ActOnInitializerError - Given that there was an error parsing an\n/// initializer for the given declaration, try to at least re-establish\n/// invariants such as whether a variable\'s type is either dependent or\n/// complete.\nvoid Sema::ActOnInitializerError(Decl *D) {\n // ...\n if (RequireNonAbstractType(VD->getLocation(), Ty, diag::err_abstract_type_in_decl, AbstractVariableType)) {"},{o,13776,"void Sema::ActOnUninitializedDecl(Decl *RealDecl) {\n // ...\n if (VarDecl *Var = dyn_cast<VarDecl>(RealDecl)) {\n // ...\n case VarDecl::DeclarationOnly:\n // ...\n if (!Type->isDependentType() && !Var->isInvalidDecl() && RequireNonAbstractType(Var->getLocation(), Type, diag::err_abstract_type_in_decl, AbstractVariableType))"},{o,13868,"void Sema::ActOnUninitializedDecl(Decl *RealDecl) {\n // ...\n if (VarDecl *Var = dyn_cast<VarDecl>(RealDecl)) {\n // ...\n if (RequireNonAbstractType(Var->getLocation(), Type, diag::err_abstract_type_in_decl, AbstractVariableType)) {"},{o,15350,"Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D, SkipBodyInfo *SkipBody, FnBodyKind BodyKind) {\n // ...\n if (!ResultType->isDependentType() && !ResultType->isVoidType() && !FD->isInvalidDecl() && BodyKind != FnBodyKind::Delete && (RequireCompleteType(FD->getLocation(), ResultType, diag::err_func_def_incomplete_result) || RequireNonAbstractType(FD->getLocation(), FD->getReturnType(), diag::err_abstract_type_in_decl, AbstractReturnType)))"},{o,18166,"/// Build a new FieldDecl and check its well-formedness.\n///\n/// This routine builds a new FieldDecl given the fields name, type,\n/// record, etc. \\p PrevDecl should refer to any previous declaration\n/// with the same name and in the same scope as the field to be\n/// created.\n///\n/// \\returns a new FieldDecl.\n///\n/// \\todo The Declarator argument is a hack. It will be removed once\nFieldDecl *Sema::CheckFieldDecl(DeclarationName Name, QualType T, TypeSourceInfo *TInfo, RecordDecl *Record, SourceLocation Loc, bool Mutable, Expr *BitWidth, InClassInitStyle InitStyle, SourceLocation TSSL, AccessSpecifier AS, NamedDecl *PrevDecl, Declarator *D) {\n // ...\n if (!InvalidDecl && RequireNonAbstractType(Loc, T, diag::err_abstract_type_in_decl, AbstractFieldType))"},{o,18876,"void Sema::ActOnFields(Scope *S, SourceLocation RecLoc, Decl *EnclosingDecl, ArrayRef<Decl *> Fields, SourceLocation LBrac, SourceLocation RBrac, const ParsedAttributesView &Attrs) {\n // ...\n for (ArrayRef<Decl *>::iterator i = Fields.begin(), end = Fields.end(); i != end; ++i) {\n // ...\n if (FDTy->isFunctionType()) {\n // ...\n } else if (FDTy->isIncompleteArrayType() && (Record || isa<ObjCContainerDecl>(EnclosingDecl))) {\n // ...\n } else if (!FDTy->isDependentType() && RequireCompleteSizedType(FD->getLocation(), FD->getType(), diag::err_field_incomplete_or_sizeless)) {\n // ...\n } else if (const RecordType *FDTTy = FDTy->getAs<RecordType>()) {\n // ...\n if (isa<ObjCContainerDecl>(EnclosingDecl) && RequireNonAbstractType(FD->getLocation(), FD->getType(), diag::err_abstract_type_in_decl, AbstractIvarType)) {"},{M,6098,"#include \"clang/AST/TypeLocNodes.def\"\n // ...\n CheckPolymorphic(PointerTypeLoc) CheckPolymorphic(ReferenceTypeLoc) CheckPolymorphic(MemberPointerTypeLoc) CheckPolymorphic(BlockPointerTypeLoc) CheckPolymorphic(AtomicTypeLoc)\n // ...\n // It matched; do some magic.\n // FIXME: These should be at most warnings. See P0929R2, CWG1640, CWG1646.\n if (Sel == Sema::AbstractArrayType) {\n // ...\n } else {\n Info.S.Diag(Ctx->getLocation(), diag::err_abstract_type_in_decl) << Sel << T << TL.getSourceRange();"},{M,16661,"/// Perform semantic analysis for the variable declaration that\n/// occurs within a C++ catch clause, returning the newly-created\n/// variable.\nVarDecl *Sema::BuildExceptionDeclaration(Scope *S, TypeSourceInfo *TInfo, SourceLocation StartLoc, SourceLocation Loc, IdentifierInfo *Name) {\n // ...\n if (!Invalid && !ExDeclType->isDependentType() && RequireNonAbstractType(Loc, ExDeclType, diag::err_abstract_type_in_decl, AbstractVariableType))"},{mb,1326,"/// ActOnPropertyImplDecl - This routine performs semantic checks and\n/// builds the AST node for a property implementation declaration; declared\n/// as \\@synthesize or \\@dynamic.\n///\nDecl *Sema::ActOnPropertyImplDecl(Scope *S, SourceLocation AtLoc, SourceLocation PropertyLoc, bool Synthesize, IdentifierInfo *PropertyId, IdentifierInfo *PropertyIvar, SourceLocation PropertyIvarLoc, ObjCPropertyQueryKind QueryKind) {\n // ...\n // Check that we have a valid, previously declared ivar for @synthesize\n if (Synthesize) {\n // ...\n if (!Ivar) {\n // ...\n if (RequireNonAbstractType(PropertyIvarLoc, PropertyIvarType, diag::err_abstract_type_in_decl, AbstractSynthesizedIvarType)) {"}}, [l]={ ["clang/test/CXX/class.derived/class.abstract/p3.cpp"]={"clang/test/CXX/class.derived/class.abstract/p3.cpp:19:3: error: variable type \'B\' (aka \'SecretlyAbstract<int>\') is an abstract class","clang/test/CXX/class.derived/class.abstract/p3.cpp:20:3: error: variable type \'SecretlyAbstract<char>\' is an abstract class","clang/test/CXX/class.derived/class.abstract/p3.cpp:38:8: error: parameter type \'A\' is an abstract class","clang/test/CXX/class.derived/class.abstract/p3.cpp:40:8: error: parameter type \'B\' (aka \'SecretlyAbstract<int>\') is an abstract class","clang/test/CXX/class.derived/class.abstract/p3.cpp:44:8: error: parameter type \'SecretlyAbstract<char>\' is an abstract class","clang/test/CXX/class.derived/class.abstract/p3.cpp:50:3: error: return type \'A\' is an abstract class","clang/test/CXX/class.derived/class.abstract/p3.cpp:52:3: error: return type \'B\' (aka \'SecretlyAbstract<int>\') is an abstract class"} } }, ["err_access"]={ [c]="err_access", [d]="%1 is a %select{private|protected}0 member of %3", [e]={{nil,nil,{"B is a ",{Q,R}," member of D"}}}, [f]=k, [g]="(.*?) is a (?:private|protected) member of (.*?)", [h]=a, [i]=m, [b]={tb,1268716967,ub,vb}, [j]={{ab,1568,"Sema::AccessResult Sema::CheckUnresolvedLookupAccess(UnresolvedLookupExpr *E, DeclAccessPair Found) {\n // ...\n Entity.setDiag(diag::err_access) << E->getSourceRange();"},{ab,1587,"/// Perform access-control checking on a previously-unresolved member\n/// access which has now been resolved to a member.\nSema::AccessResult Sema::CheckUnresolvedMemberAccess(UnresolvedMemberExpr *E, DeclAccessPair Found) {\n // ...\n Entity.setDiag(diag::err_access) << E->getSourceRange();"},{ab,1741,"/// Checks access to an overloaded operator new or delete.\nSema::AccessResult Sema::CheckAllocationAccess(SourceLocation OpLoc, SourceRange PlacementRange, CXXRecordDecl *NamingClass, DeclAccessPair Found, bool Diagnose) {\n // ...\n if (Diagnose)\n Entity.setDiag(diag::err_access) << PlacementRange;"},{ab,1790,"Sema::AccessResult Sema::CheckMemberOperatorAccess(SourceLocation OpLoc, Expr *ObjectExpr, const SourceRange &Range, DeclAccessPair Found) {\n // ...\n Entity.setDiag(diag::err_access) << ObjectExpr->getSourceRange() << Range;"},{ab,1863,"Sema::AccessResult Sema::CheckAddressOfMemberAccess(Expr *OvlExpr, DeclAccessPair Found) {\n // ...\n Entity.setDiag(diag::err_access) << Ovl->getSourceRange();"},{ab,1920,"/// Checks access to all the declarations in the given result set.\nvoid Sema::CheckLookupAccess(const LookupResult &R) {\n // ...\n for (LookupResult::iterator I = R.begin(), E = R.end(); I != E; ++I) {\n if (I.getAccess() != AS_public) {\n // ...\n Entity.setDiag(diag::err_access);"}}, [l]={ ["clang/test/SemaCXX/access-control-check.cpp"]={"clang/test/SemaCXX/access-control-check.cpp:14:21: error: \'iP\' is a private member of \'P\'","clang/test/SemaCXX/access-control-check.cpp:14:26: error: \'PPR\' is a private member of \'P\'"} } }, ["err_access_base_ctor"]={ [c]="err_access_base_ctor", [d]="%select{base class|inherited virtual base class}0 %1 has %select{private|protected}3 %select{default |copy |move |*ERROR* |*ERROR* |*ERROR*|}2constructor", [e]={{nil,nil,{{"base class","inherited virtual base class"}," B has ",{Q,R}," ",{"default ","copy ","move ",a},"constructor"}}}, [f]=k, [g]="(?:base class|inherited virtual base class) (.*?) has (?:private|protected) (?:default |copy |move |)constructor", [h]=a, [i]=m, [b]={"80f00ff95d3b",1305054494,"Re-do R131114 without breaking code.","Re-do R131114 without breaking code.\n\nI\'ve edited one diagnostic which would print \"copy constructor\" for copy\nconstructors and \"constructor\" for any other constructor. If anyone is\nextremely enamored with this, it can be reinstated with a simple boolean\nflag rather than calling getSpecialMember, which is inappropriate.\n\nllvm-svn: 131143"}, [j]={{ab,1660,"/// Checks access to a constructor.\nSema::AccessResult Sema::CheckConstructorAccess(SourceLocation UseLoc, CXXConstructorDecl *Constructor, DeclAccessPair Found, const InitializedEntity &Entity, bool IsCopyBindingRefToTemp) {\n // ...\n case InitializedEntity::EK_Base:\n PD = PDiag(diag::err_access_base_ctor);"}}, [l]={ ["clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p18.cpp"]={"clang/test/CXX/dcl.dcl/basic.namespace/namespace.udecl/p18.cpp:43:18: error: base class \'B\' has private constructor"} } }, ["err_access_ctor"]={ [c]="err_access_ctor", [d]="calling a %select{private|protected}0 constructor of class %2", [e]={{nil,nil,{"calling a ",{Q,R}," constructor of class C"}}}, [f]=k, [g]="calling a (?:private|protected) constructor of class (.*?)", [h]=a, [i]=m, [b]={tb,1268716967,ub,vb}, [j]={{ab,1655,"/// Checks access to a constructor.\nSema::AccessResult Sema::CheckConstructorAccess(SourceLocation UseLoc, CXXConstructorDecl *Constructor, DeclAccessPair Found, const InitializedEntity &Entity, bool IsCopyBindingRefToTemp) {\n // ...\n default:\n PD = PDiag(IsCopyBindingRefToTemp ? diag::ext_rvalue_to_reference_access_ctor : diag::err_access_ctor);"}}, [l]={ ["clang/test/CXX/expr/expr.unary/expr.new/p17.cpp"]={"clang/test/CXX/expr/expr.unary/expr.new/p17.cpp:12:7: error: calling a private constructor of class \'ctor\'"} } }, ["err_access_decl"]={ [c]="err_access_decl", [d]="ISO C++11 does not allow access declarations; use using declarations instead", [e]="ISO C++11 does not allow access declarations; use using declarations instead", [f]=k, [g]="ISO C\\+\\+11 does not allow access declarations; use using declarations instead", [h]=a, [i]=m, [b]={"f026b600992d",1371089537,"In C++11, promote access declaration diagnostic from warning to error. There","In C++11, promote access declaration diagnostic from warning to error. There\ndoesn\'t seem to be any value in even adding a -W flag for this.\n\nllvm-svn: 183882"}, [j]={{M,12068,"Decl *Sema::ActOnUsingDeclaration(Scope *S, AccessSpecifier AS, SourceLocation UsingLoc, SourceLocation TypenameLoc, CXXScopeSpec &SS, UnqualifiedId &Name, SourceLocation EllipsisLoc, const ParsedAttributesView &AttrList) {\n // ...\n // Warn about access declarations.\n if (UsingLoc.isInvalid()) {\n Diag(Name.getBeginLoc(), getLangOpts().CPlusPlus11 ? diag::err_access_decl : diag::warn_access_decl_deprecated) << FixItHint::CreateInsertion(SS.getRange().getBegin(), \"using \");"}}, [l]={ ["clang/test/CXX/class.access/class.access.dcl/p1.cpp"]={"clang/test/CXX/class.access/class.access.dcl/p1.cpp:29:15: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:36:15: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:43:15: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:50:15: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:71:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:77:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:84:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:91:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:98:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:142:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:149:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:156:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:163:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:170:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:216:11: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:223:11: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:230:11: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:237:11: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:244:11: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:300:14: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:307:11: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:314:16: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:321:8: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:329:15: error: ISO C++11 does not allow access declarations; use using declarations instead","clang/test/CXX/class.access/class.access.dcl/p1.cpp:341:8: error: ISO C++11 does not allow access declarations; use using declarations instead"} } }, ["err_access_dtor"]={ [c]="err_access_dtor", [d]="calling a %select{private|protected}1 destructor of class %0", [e]={{nil,nil,{"calling a ",{Q,R}," destructor of class A"}}}, [f]=k, [g]="calling a (?:private|protected) destructor of class (.*?)", [h]=a, [i]=m, [b]={"fa7781384ebb",1296575411,"Implement access checking for the \"delete\" operator. Fixes PR9050,","Implement access checking for the \"delete\" operator. Fixes PR9050,\nfrom Alex Miller!\n\nllvm-svn: 124663"}, [j]={{D,3775,"/// ActOnCXXDelete - Parsed a C++ \'delete\' expression (C++ 5.3.5), as in:\n/// @code ::delete ptr; @endcode\n/// or\n/// @code delete [] ptr; @endcode\nExprResult Sema::ActOnCXXDelete(SourceLocation StartLoc, bool UseGlobal, bool ArrayForm, Expr *ExE) {\n // ...\n if (!Ex.get()->isTypeDependent()) {\n // ...\n if (PointeeRD) {\n if (CXXDestructorDecl *Dtor = LookupDestructor(PointeeRD)) {\n CheckDestructorAccess(Ex.get()->getExprLoc(), Dtor, PDiag(diag::err_access_dtor) << PointeeElem);"}}, [l]={ ["clang/test/CXX/expr/expr.unary/expr.delete/p5.cpp"]={"clang/test/CXX/expr/expr.unary/expr.delete/p5.cpp:31:12: error: calling a private destructor of class \'T3_A\'"} } }, ["err_access_dtor_base"]={ [c]="err_access_dtor_base", [d]="base class %0 has %select{private|protected}1 destructor", [e]={{nil,nil,{"base class A has ",{Q,R},rb}}}, [f]=k, [g]="base class (.*?) has (?:private|protected) destructor", [h]=a, [i]=m, [b]={tb,1268716967,ub,vb}, [j]={{M,5847,"void Sema::MarkBaseAndMemberDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl) {\n // ...\n // Bases.\n for (const auto &Base : ClassDecl->bases()) {\n // ...\n CheckDestructorAccess(Base.getBeginLoc(), Dtor, PDiag(diag::err_access_dtor_base) << Base.getType() << Base.getSourceRange(), Context.getTypeDeclType(ClassDecl));"}}, [l]={ ["clang/test/SemaObjCXX/ivar-construct.mm"]={"clang/test/SemaObjCXX/ivar-construct.mm:10:12: error: base class \'Y\' has private destructor","clang/test/SemaObjCXX/ivar-construct.mm:10:12: error: base class \'Y\' has private destructor"} } }, ["err_access_dtor_exception"]={ [c]="err_access_dtor_exception", [d]="exception object of type %0 has %select{private|protected}1 destructor", [e]={{nil,nil,{"exception object of type A has ",{Q,R},rb}}}, [f]=k, [g]="exception object of type (.*?) has (?:private|protected) destructor", [h]=a, [i]=m, [b]={"442612c2853f",1278542113,"Do not use CXXZeroValueInitExpr for class types. Instead, use","Do not use CXXZeroValueInitExpr for class types. Instead, use\nCXXConstructExpr/CXXTemporaryObjectExpr/CXXNewExpr as\nappropriate. Fixes PR7556, and provides a slide codegen improvement\nwhen copy-initializing a POD class type from a value-initialized\ntemporary. Previously, we weren\'t eliding the copy.\n\nllvm-svn: 107827"}, [j]={{D,1033,"/// CheckCXXThrowOperand - Validate the operand of a throw.\nbool Sema::CheckCXXThrowOperand(SourceLocation ThrowLoc, QualType ExceptionObjectTy, Expr *E) {\n // ...\n // If the class has a destructor, we must be able to call it.\n if (!RD->hasIrrelevantDestructor()) {\n if (CXXDestructorDecl *Destructor = LookupDestructor(RD)) {\n // ...\n CheckDestructorAccess(E->getExprLoc(), Destructor, PDiag(diag::err_access_dtor_exception) << Ty);"}}, [l]={ ["clang/test/SemaCXX/defaulted-private-dtor.cpp"]={"clang/test/SemaCXX/defaulted-private-dtor.cpp:13:9: error: exception object of type \'BadDtor\' has private destructor"} } }, ["err_access_dtor_field"]={ [c]="err_access_dtor_field", [d]="field of type %1 has %select{private|protected}2 destructor", [e]={{nil,nil,{"field of type B has ",{Q,R},rb}}}, [f]=k, [g]="field of type (.*?) has (?:private|protected) destructor", [h]=a, [i]=m, [b]={tb,1268716967,ub,vb}, [j]={{M,5797,"void Sema::MarkBaseAndMemberDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl) {\n // ...\n // Non-static data members.\n for (auto *Field : ClassDecl->fields()) {\n // ...\n CheckDestructorAccess(Field->getLocation(), Dtor, PDiag(diag::err_access_dtor_field) << Field->getDeclName() << FieldType);"}}, [l]={ ["clang/test/SemaCXX/defaulted-private-dtor.cpp"]={"clang/test/SemaCXX/defaulted-private-dtor.cpp:28:11: error: field of type \'BadDtor\' has private destructor"} } }, ["err_access_dtor_ivar"]={ [c]="err_access_dtor_ivar", [d]="instance variable of type %0 has %select{private|protected}1 destructor", [e]={{nil,nil,{"instance variable of type A has ",{Q,R},rb}}}, [f]=k, [g]="instance variable of type (.*?) has (?:private|protected) destructor", [h]=a, [i]=m, [b]={"527786ea3a6a",1274322262,"Various small fixes for construction/destruction of Objective-C++","Various small fixes for construction/destruction of Objective-C++\ninstance variables:\n - Use isRecordType() rather than isa<RecordType>(), so that we see\n through typedefs in ivar types.\n - Mark the destructor as referenced\n - Perform C++ access control on the destructor\n\nllvm-svn: 104206"}, [j]={{M,18491,"/// SetIvarInitializers - This routine builds initialization ASTs for the\n/// Objective-C implementation whose ivars need be initialized.\nvoid Sema::SetIvarInitializers(ObjCImplementationDecl *ObjCImplementation) {\n // ...\n if (ObjCInterfaceDecl *OID = ObjCImplementation->getClassInterface()) {\n // ...\n for (unsigned i = 0; i < ivars.size(); i++) {\n // ...\n // Be sure that the destructor is accessible and is marked as referenced.\n if (const RecordType *RecordTy = Context.getBaseElementType(Field->getType())->getAs<RecordType>()) {\n // ...\n if (CXXDestructorDecl *Destructor = LookupDestructor(RD)) {\n // ...\n CheckDestructorAccess(Field->getLocation(), Destructor, PDiag(diag::err_access_dtor_ivar) << Context.getBaseElementType(Field->getType()));"}}, [l]={ ["clang/test/SemaObjCXX/ivar-construct.mm"]={"clang/test/SemaObjCXX/ivar-construct.mm:16:5: error: instance variable of type \'Y\' has private destructor"} } }, ["err_access_dtor_temp"]={ [c]="err_access_dtor_temp", [d]="temporary of type %0 has %select{private|protected}1 destructor", [e]={{nil,nil,{"temporary of type A has ",{Q,R},rb}}}, [f]=k, [g]="temporary of type (.*?) has (?:private|protected) destructor", [h]=a, [i]=m, [b]={"8e36d53e34be",1270600906,"Check access for the implicit calls to destructors that occur when we","Check access for the implicit calls to destructors that occur when we\nhave a temporary object in C++.\n\nAlso fix a tag mismatch that Doug noticed.\n\nllvm-svn: 100593"}, [j]={{D,7334,"ExprResult Sema::MaybeBindToTemporary(Expr *E) {\n // ...\n if (Destructor) {\n // ...\n CheckDestructorAccess(E->getExprLoc(), Destructor, PDiag(diag::err_access_dtor_temp) << E->getType());"},{D,7505,"/// Process the expression contained within a decltype. For such expressions,\n/// certain semantic checks on temporaries are delayed until this point, and\n/// are omitted for the \'topmost\' call in the decltype expression. If the\n/// topmost call bound a temporary, strip that temporary off the expression.\nExprResult Sema::ActOnDecltypeExpression(Expr *E) {\n // ...\n // Now all relevant types are complete, check the destructors are accessible\n // and non-deleted, and annotate them on the temporaries.\n for (unsigned I = 0, N = ExprEvalContexts.back().DelayedDecltypeBinds.size(); I != N; ++I) {\n // ...\n CheckDestructorAccess(Bind->getExprLoc(), Destructor, PDiag(diag::err_access_dtor_temp) << Bind->getType());"},{L,1932,"/// Check if the type of a class element has an accessible destructor, and marks\n/// it referenced. Returns true if we shouldn\'t form a reference to the\n/// destructor.\n///\n/// Aggregate initialization requires a class element\'s destructor be\n/// accessible per 11.6.1 [dcl.init.aggr]:\n///\n/// The destructor for each element of class type is potentially invoked\n/// (15.4 [class.dtor]) from the context where the aggregate initialization\n/// occurs.\nstatic bool checkDestructorReference(QualType ElementType, SourceLocation Loc, Sema &SemaRef) {\n // ...\n SemaRef.CheckDestructorAccess(Loc, Destructor, SemaRef.PDiag(diag::err_access_dtor_temp) << ElementType);"},{L,8929,"ExprResult InitializationSequence::Perform(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, MultiExprArg Args, QualType *ResultType) {\n // ...\n for (step_iterator Step = step_begin(), StepEnd = step_end(); Step != StepEnd; ++Step) {\n // ...\n case SK_UserConversion: {\n // ...\n if (shouldBindAsTemporary(Entity))\n // ...\n else if (CreatedObject && shouldDestroyEntity(Entity)) {\n // ...\n if (const RecordType *Record = T->getAs<RecordType>()) {\n // ...\n S.CheckDestructorAccess(CurInit.get()->getBeginLoc(), Destructor, S.PDiag(diag::err_access_dtor_temp) << T);"}}, [l]={ ["clang/test/CXX/expr/expr.unary/expr.new/p17.cpp"]={"clang/test/CXX/expr/expr.unary/expr.new/p17.cpp:13:7: error: temporary of type \'dtor\' has private destructor","clang/test/CXX/expr/expr.unary/expr.new/p17.cpp:14:7: error: temporary of type \'dtor\' has private destructor","clang/test/CXX/expr/expr.unary/expr.new/p17.cpp:15:7: error: temporary of type \'dtor\' has private destructor"} } }, ["err_access_dtor_var"]={ [c]="err_access_dtor_var", [d]="variable of type %1 has %select{private|protected}2 destructor", [e]={{nil,nil,{"variable of type B has ",{Q,R},rb}}}, [f]=k, [g]="variable of type (.*?) has (?:private|protected) destructor", [h]=a, [i]=m, [b]={tb,1268716967,ub,vb}, [j]={{M,15869,"void Sema::FinalizeVarWithDestructor(VarDecl *VD, const RecordType *Record) {\n // ...\n // If this is an array, we\'ll require the destructor during initialization, so\n // we can skip over this. We still want to emit exit-time destructor warnings\n // though.\n if (!VD->getType()->isArrayType()) {\n // ...\n CheckDestructorAccess(VD->getLocation(), Destructor, PDiag(diag::err_access_dtor_var) << VD->getDeclName() << VD->getType());"}}, [l]={ ["clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.type.simple/p5-cxx0x.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.type.simple/p5-cxx0x.cpp:46:11: error: variable of type \'decltype(pd() , pd())\' (aka \'PD\') has private destructor","clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.type.simple/p5-cxx0x.cpp:61:18: error: variable of type \'decltype(pd_ref)\' (aka \'PD\') has private destructor"} } }, ["err_access_dtor_vbase"]={ [c]="err_access_dtor_vbase", [d]="inherited virtual base class %1 has %select{private|protected}2 destructor", [e]={{nil,nil,{"inherited virtual base class B has ",{Q,R},rb}}}, [f]=k, [g]="inherited virtual base class (.*?) has (?:private|protected) destructor", [h]=a, [i]=m, [b]={tb,1268716967,ub,vb}, [j]={{M,5885,"void Sema::MarkVirtualBaseDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl, llvm::SmallPtrSetImpl<const RecordType *> *DirectVirtualBases) {\n // Virtual bases.\n for (const auto &VBase : ClassDecl->vbases()) {\n // ...\n if (CheckDestructorAccess(ClassDecl->getLocation(), Dtor, PDiag(diag::err_access_dtor_vbase) << Context.getTypeDeclType(ClassDecl) << VBase.getType(), Context.getTypeDeclType(ClassDecl)) == AR_accessible) {"},{M,5891,"void Sema::MarkVirtualBaseDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl, llvm::SmallPtrSetImpl<const RecordType *> *DirectVirtualBases) {\n // Virtual bases.\n for (const auto &VBase : ClassDecl->vbases()) {\n // ...\n if (CheckDestructorAccess(ClassDecl->getLocation(), Dtor, PDiag(diag::err_access_dtor_vbase) << Context.getTypeDeclType(ClassDecl) << VBase.getType(), Context.getTypeDeclType(ClassDecl)) == AR_accessible) {\n CheckDerivedToBaseConversion(Context.getTypeDeclType(ClassDecl), VBase.getType(), diag::err_access_dtor_vbase, 0, ClassDecl->getLocation(), SourceRange(), DeclarationName(), nullptr);"}}, [l]={ ["clang/test/SemaCXX/ms-implicit-complete-dtor.cpp"]={"clang/test/SemaCXX/ms-implicit-complete-dtor.cpp:46:8: error: inherited virtual base class \'Base<2>\' has private destructor"} } }, ["err_access_field_ctor"]={ [c]="err_access_field_ctor", [d]="field of type %0 has %select{private|protected}2 %select{default |copy |move |*ERROR* |*ERROR* |*ERROR* |}1constructor", [e]={{nil,nil,{"field of type A has ",{Q,R}," ",{"default ","copy ","move ",a},"constructor"}}}, [f]=k, [g]="field of type (.*?) has (?:private|protected) (?:default |copy |move |)constructor", [h]=a, [i]=m, [b]={"80f00ff95d3b",1305054494,"Re-do R131114 without breaking code.","Re-do R131114 without breaking code.\n\nI\'ve edited one diagnostic which would print \"copy constructor\" for copy\nconstructors and \"constructor\" for any other constructor. If anyone is\nextremely enamored with this, it can be reinstated with a simple boolean\nflag rather than calling getSpecialMember, which is inappropriate.\n\nllvm-svn: 131143"}, [j]={{ab,1668,"/// Checks access to a constructor.\nSema::AccessResult Sema::CheckConstructorAccess(SourceLocation UseLoc, CXXConstructorDecl *Constructor, DeclAccessPair Found, const InitializedEntity &Entity, bool IsCopyBindingRefToTemp) {\n // ...\n case InitializedEntity::EK_Member:\n case InitializedEntity::EK_ParenAggInitMember: {\n // ...\n PD = PDiag(diag::err_access_field_ctor);"}}, [l]={ ["clang/test/CXX/dcl.decl/dcl.init/p14-0x.cpp"]={"clang/test/CXX/dcl.decl/dcl.init/p14-0x.cpp:36:15: error: field of type \'Private\' has private constructor"} } }, ["err_access_friend_function"]={ [c]="err_access_friend_function", [d]="friend function %1 is a %select{private|protected}0 member of %3", [e]={{nil,nil,{"friend function B is a ",{Q,R}," member of D"}}}, [f]=k, [g]="friend function (.*?) is a (?:private|protected) member of (.*?)", [h]=a, [i]=m, [b]={"a0a96895501e",1344568535,"Check access to friend declarations. There\'s a number of different","Check access to friend declarations. There\'s a number of different\nthings going on here that were problematic:\n - We were missing the actual access check, or rather, it was suppressed\n on account of being a redeclaration lookup.\n - The access check would naturally happen during delay, which isn\'t\n appropriate in this case.\n - We weren\'t actually emitting dependent diagnostics associated with\n class templates, which was unfortunate.\n - Access was being propagated incorrectly for friend method declarations\n that couldn\'t be matched at parse-time.\n\nllvm-svn: 161652"}, [j]={{ab,1836,"/// Checks access to the target of a friend declaration.\nSema::AccessResult Sema::CheckFriendAccess(NamedDecl *target) {\n // ...\n entity.setDiag(diag::err_access_friend_function) << (method->getQualifier() ? method->getQualifierLoc().getSourceRange() : method->getNameInfo().getSourceRange());"}}, [l]={ ["clang/test/CXX/class.access/class.friend/p9-cxx0x.cpp"]={"clang/test/CXX/class.access/class.friend/p9-cxx0x.cpp:16:20: error: friend function \'f\' is a private member of \'test0::X\'","clang/test/CXX/class.access/class.friend/p9-cxx0x.cpp:27:20: error: friend function \'f\' is a private member of \'test1::X\'","clang/test/CXX/class.access/class.friend/p9-cxx0x.cpp:57:20: error: friend function \'f\' is a private member of \'test3::X\'","clang/test/CXX/class.access/class.friend/p9-cxx0x.cpp:81:23: error: friend function \'f\' is a private member of \'test5::X<int>\'","clang/test/CXX/class.access/class.friend/p9-cxx0x.cpp:97:23: error: friend function \'f\' is a private member of \'test6::X<int>\'"} } }, ["err_access_lambda_capture"]={ [c]="err_access_lambda_capture", [d]="capture of variable \'%0\' as type %1 calls %select{private|protected}3 %select{default |copy |move |*ERROR* |*ERROR* |*ERROR* |}2constructor", [e]={{nil,nil,{"capture of variable \'A\' as type B calls ",{Q,R}," ",{"default ","copy ","move ",a},"constructor"}}}, [f]=k, [g]="capture of variable \'(.*?)\' as type (.*?) calls (?:private|protected) (?:default |copy |move |)constructor", [h]=a, [i]="Lambda Issue", [b]={"19666fb1aa7d",1329325046,"Introduce a new initialization entity for lambda captures, and","Introduce a new initialization entity for lambda captures, and\nspecialize location information and diagnostics for this entity.\n\nllvm-svn: 150588"}, [j]={{ab,1675,"/// Checks access to a constructor.\nSema::AccessResult Sema::CheckConstructorAccess(SourceLocation UseLoc, CXXConstructorDecl *Constructor, DeclAccessPair Found, const InitializedEntity &Entity, bool IsCopyBindingRefToTemp) {\n // ...\n case InitializedEntity::EK_LambdaCapture: {\n // ...\n PD = PDiag(diag::err_access_lambda_capture);"}}, [l]={ ["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp:17:10: error: capture of variable \'nc\' as type \'NonCopyable\' calls private copy constructor","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp:18:10: error: capture of variable \'ncr\' as type \'NonCopyable\' calls private copy constructor"} } }, ["err_access_specifier_interface"]={ [c]="err_access_specifier_interface", [d]="interface types cannot specify \'%select{private|protected}0\' access", [e]={{nil,nil,{"interface types cannot specify \'",{Q,R},"\' access"}}}, [f]=k, [g]="interface types cannot specify \'(?:private|protected)\' access", [h]=a, [i]=V, [b]={"db632ac004ae",1348558359,"Fix for r163013 regression and further __interface enhancement.","Fix for r163013 regression and further __interface enhancement.\nPatch by Andy Gibbs!\n\nllvm-svn: 164590"}, [j]={{db,3403,"Parser::DeclGroupPtrTy Parser::ParseCXXClassMemberDeclarationWithPragmas(AccessSpecifier &AS, ParsedAttributes &AccessAttrs, DeclSpec::TST TagType, Decl *TagDecl) {\n // ...\n case tok::kw_public:\n case tok::kw_protected: {\n // ...\n // The Microsoft extension __interface does not permit non-public\n // access specifiers.\n if (TagType == DeclSpec::TST_interface && AS != AS_public) {\n Diag(ASLoc, diag::err_access_specifier_interface) << (AS == AS_protected);"}}, [l]={ ["clang/test/SemaCXX/ms-interface.cpp"]={"clang/test/SemaCXX/ms-interface.cpp:18:1: error: interface types cannot specify \'protected\' access","clang/test/SemaCXX/ms-interface.cpp:21:1: error: interface types cannot specify \'private\' access","clang/test/SemaCXX/ms-interface.cpp:30:1: error: interface types cannot specify \'private\' access","clang/test/SemaCXX/ms-interface.cpp:33:1: error: interface types cannot specify \'protected\' access"} } }, ["err_addr_ovl_ambiguous"]={ [c]="err_addr_ovl_ambiguous", [d]="address of overloaded function %0 is ambiguous", [e]="address of overloaded function A is ambiguous", [f]=k, [g]="address of overloaded function (.*?) is ambiguous", [h]=a, [i]=m, [b]={"b257e4fff8a9",1247096032,"Implement the simple form of overload resolution used when taking the","Implement the simple form of overload resolution used when taking the\naddress of an overloaded function (which may involve both functions\nand function templates). \n\nllvm-svn: 75069"}, [j]={{Z,12563,"// A helper class to help with address of function resolution\n// - allows us to avoid passing around all those ugly parameters\nclass AddressOfFunctionResolver {\n // ...\n void EliminateAllExceptMostSpecializedTemplate() {\n // ...\n UnresolvedSetIterator Result = S.getMostSpecialized(MatchesCopy.begin(), MatchesCopy.end(), FailedCandidates, SourceExpr->getBeginLoc(), S.PDiag(), S.PDiag(diag::err_addr_ovl_ambiguous) << Matches[0].second->getDeclName(), S.PDiag(diag::note_ovl_candidate) << (unsigned)oc_function << (unsigned)ocs_described_template, Complain, TargetFunctionType);"},{Z,12651,"// A helper class to help with address of function resolution\n// - allows us to avoid passing around all those ugly parameters\nclass AddressOfFunctionResolver {\n // ...\n void ComplainMultipleMatchesFound() const {\n // ...\n S.Diag(OvlExpr->getBeginLoc(), diag::err_addr_ovl_ambiguous) << OvlExpr->getName() << OvlExpr->getSourceRange();"},{Z,12905,"/// Given an expression that refers to an overloaded function, try to\n/// resolve that overloaded function expression down to a single function.\n///\n/// This routine can only resolve template-ids that refer to a single function\n/// template, where that template-id refers to a single template whose template\n/// arguments are either provided by the template-id or have defaults,\n/// as described in C++0x [temp.arg.explicit]p3.\n///\n/// If no template-ids are found, no diagnostics are emitted and NULL is\n/// returned.\nFunctionDecl *Sema::ResolveSingleFunctionTemplateSpecialization(OverloadExpr *ovl, bool Complain, DeclAccessPair *FoundResult, TemplateSpecCandidateSet *FailedTSC) {\n // ...\n for (UnresolvedSetIterator I = ovl->decls_begin(), E = ovl->decls_end(); I != E; ++I) {\n // ...\n // Multiple matches; we can\'t resolve to a single declaration.\n if (Matched) {\n if (Complain) {\n Diag(ovl->getExprLoc(), diag::err_addr_ovl_ambiguous) << ovl->getName();"}}, [l]={ ["clang/test/CXX/over/over.over/p4.cpp"]={"clang/test/CXX/over/over.over/p4.cpp:18:21: error: address of overloaded function \'f0\' is ambiguous"} } }, ["err_addr_ovl_no_qualifier"]={ [c]="err_addr_ovl_no_qualifier", [d]="cannot form member pointer of type %0 without \'&\' and class name", [e]="cannot form member pointer of type A without \'&\' and class name", [f]=k, [g]="cannot form member pointer of type (.*?) without \'&\' and class name", [h]=a, [i]=m, [b]={"24d189484b44",1282690359,"When trying to resolve the address of an overloaded expression,","When trying to resolve the address of an overloaded expression,\nonly form pointers-to-member if the expression has the appropriate\nform. This avoids assertions later on on invalid code, but also\nallows us to properly resolve mixed-staticity overloads.\n\nllvm-svn: 111987"}, [j]={{Z,12630,"// A helper class to help with address of function resolution\n// - allows us to avoid passing around all those ugly parameters\nclass AddressOfFunctionResolver {\n // ...\n void ComplainIsInvalidFormOfPointerToMemberFunction() const {\n // ...\n S.Diag(OvlExpr->getNameLoc(), diag::err_addr_ovl_no_qualifier) << TargetType << OvlExpr->getSourceRange();"}}, [l]={ ["clang/test/CXX/expr/expr.unary/expr.unary.op/p4.cpp"]={"clang/test/CXX/expr/expr.unary/expr.unary.op/p4.cpp:10:12: error: cannot form member pointer of type \'void (test0::A::*)(int)\' without \'&\' and class name"} } }, ["err_addr_ovl_no_viable"]={ [c]="err_addr_ovl_no_viable", [d]="address of overloaded function %0 does not match required type %1", [e]="address of overloaded function A does not match required type B", [f]=k, [g]="address of overloaded function (.*?) does not match required type (.*?)", [h]=a, [i]=m, [b]={"064fdb2fe844",1271286681,"Always diagnose and complain about problems in","Always diagnose and complain about problems in\nResolveAddressOfOverloadedFunction when asked to complain. Previously,\nwe had some weird handshake where ResolveAddressOfOverloadedFunction\nexpected its caller to handle some of the diagnostics but not others,\nand yet there was no way for the caller to know which case we were\nin. Eliminate this madness, fixing <rdar://problem/7765884>.\n\nllvm-svn: 101312"}, [j]={{Z,12599,"// A helper class to help with address of function resolution\n// - allows us to avoid passing around all those ugly parameters\nclass AddressOfFunctionResolver {\n // ...\n void ComplainNoMatchesFound() const {\n // ...\n S.Diag(OvlExpr->getBeginLoc(), diag::err_addr_ovl_no_viable) << OvlExpr->getName() << TargetFunctionType << OvlExpr->getSourceRange();"}}, [l]={ ["clang/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.type/p5-0x.cpp"]={"clang/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.type/p5-0x.cpp:37:69: error: address of overloaded function \'has_non_trailing_pack_and_more\' does not match required type \'void (float, double, int)\'"} } }, ["err_addr_ovl_not_func_ptrref"]={ [c]="err_addr_ovl_not_func_ptrref", [d]="address of overloaded function %0 cannot be converted to type %1", [e]="address of overloaded function A cannot be converted to type B", [f]=k, [g]="address of overloaded function (.*?) cannot be converted to type (.*?)", [h]=a, [i]=m, [b]={"064fdb2fe844",1271286681,"Always diagnose and complain about problems in","Always diagnose and complain about problems in\nResolveAddressOfOverloadedFunction when asked to complain. Previously,\nwe had some weird handshake where ResolveAddressOfOverloadedFunction\nexpected its caller to handle some of the diagnostics but not others,\nand yet there was no way for the caller to know which case we were\nin. Eliminate this madness, fixing <rdar://problem/7765884>.\n\nllvm-svn: 101312"}, [j]={{Z,12645,"// A helper class to help with address of function resolution\n// - allows us to avoid passing around all those ugly parameters\nclass AddressOfFunctionResolver {\n // ...\n void ComplainOfInvalidConversion() const { S.Diag(OvlExpr->getBeginLoc(), diag::err_addr_ovl_not_func_ptrref) << OvlExpr->getName() << TargetType; }"}} }, ["err_address_of_function_with_pass_object_size_params"]={ [c]="err_address_of_function_with_pass_object_size_params", [d]="cannot take address of function %0 because parameter %1 has pass_object_size attribute", [e]="cannot take address of function A because parameter B has pass_object_size attribute", [f]=k, [g]="cannot take address of function (.*?) because parameter (.*?) has pass_object_size attribute", [h]=a, [i]=m, [b]={"3e3bb95b6951",1449093488,"Add the `pass_object_size` attribute to clang.","Add the `pass_object_size` attribute to clang.\n\n`pass_object_size` is our way of enabling `__builtin_object_size` to\nproduce high quality results without requiring inlining to happen\neverywhere.\n\nA link to the design doc for this attribute is available at the\nDifferential review link below.\n\nDifferential Revision: http://reviews.llvm.org/D13263\n\nllvm-svn: 254554"}, [j]={{Z,10609,"/// Returns true if we can take the address of the function.\n///\n/// \\param Complain - If true, we\'ll emit a diagnostic\n/// \\param InOverloadResolution - For the purposes of emitting a diagnostic, are\n/// we in overload resolution?\n/// \\param Loc - The location of the statement we\'re complaining about. Ignored\n/// if we\'re not complaining, or if we\'re in overload resolution.\nstatic bool checkAddressOfFunctionIsAvailable(Sema &S, const FunctionDecl *FD, bool Complain, bool InOverloadResolution, SourceLocation Loc) {\n // ...\n if (Complain) {\n // ...\n if (InOverloadResolution)\n // ...\n else\n S.Diag(Loc, diag::err_address_of_function_with_pass_object_size_params) << FD << ParamNo;"}}, [l]={ ["clang/test/Sema/pass-object-size.c"]={"clang/test/Sema/pass-object-size.c:44:23: error: cannot take address of function \'NotOverloaded\' because parameter 1 has pass_object_size attribute","clang/test/Sema/pass-object-size.c:45:25: error: cannot take address of function \'NotOverloaded\' because parameter 1 has pass_object_size attribute","clang/test/Sema/pass-object-size.c:53:10: error: cannot take address of function \'NotOverloaded\' because parameter 1 has pass_object_size attribute","clang/test/Sema/pass-object-size.c:54:11: error: cannot take address of function \'NotOverloaded\' because parameter 1 has pass_object_size attribute","clang/test/Sema/pass-object-size.c:56:13: error: cannot take address of function \'NotOverloaded\' because parameter 1 has pass_object_size attribute","clang/test/Sema/pass-object-size.c:57:14: error: cannot take address of function \'NotOverloaded\' because parameter 1 has pass_object_size attribute","clang/test/Sema/pass-object-size.c:60:5: error: cannot take address of function \'NotOverloaded\' because parameter 1 has pass_object_size attribute"} } }, ["err_address_of_label_outside_fn"]={ [c]="err_address_of_label_outside_fn", [d]="use of address-of-label extension outside of a function body", [e]="use of address-of-label extension outside of a function body", [f]=k, [g]="use of address\\-of\\-label extension outside of a function body", [h]=a, [i]=V, [b]={"9ba479bd2c2c",1298063799,"fix rdar://9024687, a crash on invalid that we used to silently ignore.","fix rdar://9024687, a crash on invalid that we used to silently ignore.\n\nllvm-svn: 125962"}, [j]={{"clang/lib/Parse/ParseExpr.cpp",1460,"#include \"clang/Basic/TransformTypeTraits.def\"\n // ...\n case tok::ampamp: { // unary-expression: \'&&\' identifier\n // ...\n if (getCurScope()->getFnParent() == nullptr)\n return ExprError(Diag(Tok, diag::err_address_of_label_outside_fn));"}}, [l]={ ["clang/test/Sema/scope-check.c"]={"clang/test/Sema/scope-check.c:235:26: error: use of address-of-label extension outside of a function body"} } }, ["err_address_space_mismatch_templ_inst"]={ [c]={{nil,B,"err_address_space_mismatch_templ_inst"}}, [d]={{nil,B,"conflicting address space qualifiers are provided between types %0 and %1"}}, [e]={{nil,B,"conflicting address space qualifiers are provided between types A and B"}}, [f]=k, [g]="conflicting address space qualifiers are provided between types (.*?) and (.*?)", [h]=a, [i]={{nil,B,m}}, [b]={"12e3a8af81da",1544029342,"[OpenCL] Diagnose conflicting address spaces in templates.","[OpenCL] Diagnose conflicting address spaces in templates.\n\nAdded new diagnostic when templates are instantiated with\ndifferent address space from the one provided in its definition.\n\nThis also prevents deducing generic address space in pointer\ntype of templates to allow giving them concrete address space\nduring instantiation.\n\nDifferential Revision: https://reviews.llvm.org/D55127\n\nllvm-svn: 348382"}, [l]={ ["clang/test/SemaOpenCLCXX/address-space-templates.clcpp"]={"clang/test/SemaOpenCLCXX/address-space-templates.clcpp:22:13: error: conflicting address space qualifiers are provided between types \'__private T\' and \'__global int\'"} } }, ["err_address_space_qualified_delete"]={ [c]="err_address_space_qualified_delete", [d]="\'delete\' cannot delete objects of type %0 in address space \'%1\'", [e]="\'delete\' cannot delete objects of type A in address space \'B\'", [f]=k, [g]="\'delete\' cannot delete objects of type (.*?) in address space \'(.*?)\'", [h]=a, [i]=m, [b]={"39d1a0973db9",1302896780,"Forbid the use of C++ new/delete to allocate/free objects within an","Forbid the use of C++ new/delete to allocate/free objects within an\naddress space. I could see that this functionality would be useful,\nbut not in its current form (where the address space is ignored):\nrather, we\'d want to encode the address space into the parameter list\npassed to operator new/operator delete somehow, which would require a\nbunch more semantic analysis.\n\nllvm-svn: 129593"}, [j]={{D,3677,"/// ActOnCXXDelete - Parsed a C++ \'delete\' expression (C++ 5.3.5), as in:\n/// @code ::delete ptr; @endcode\n/// or\n/// @code delete [] ptr; @endcode\nExprResult Sema::ActOnCXXDelete(SourceLocation StartLoc, bool UseGlobal, bool ArrayForm, Expr *ExE) {\n // ...\n if (!Ex.get()->isTypeDependent()) {\n // ...\n if (Pointee.getAddressSpace() != LangAS::Default && !getLangOpts().OpenCLCPlusPlus)\n return Diag(Ex.get()->getBeginLoc(), diag::err_address_space_qualified_delete) << Pointee.getUnqualifiedType() << Pointee.getQualifiers().getAddressSpaceAttributePrintValue();"}}, [l]={ ["clang/test/SemaCXX/address-space-newdelete.cpp"]={"clang/test/SemaCXX/address-space-newdelete.cpp:22:10: error: \'delete\' cannot delete objects of type \'int\' in address space \'1\'","clang/test/SemaCXX/address-space-newdelete.cpp:23:13: error: \'delete\' cannot delete objects of type \'int\' in address space \'1\'"} } }, ["err_address_space_qualified_new"]={ [c]="err_address_space_qualified_new", [d]="\'new\' cannot allocate objects of type %0 in address space \'%1\'", [e]="\'new\' cannot allocate objects of type A in address space \'B\'", [f]=k, [g]="\'new\' cannot allocate objects of type (.*?) in address space \'(.*?)\'", [h]=a, [i]=m, [b]={"39d1a0973db9",1302896780,"Forbid the use of C++ new/delete to allocate/free objects within an","Forbid the use of C++ new/delete to allocate/free objects within an\naddress space. I could see that this functionality would be useful,\nbut not in its current form (where the address space is ignored):\nrather, we\'d want to encode the address space into the parameter list\npassed to operator new/operator delete somehow, which would require a\nbunch more semantic analysis.\n\nllvm-svn: 129593"}, [j]={{D,2475,"/// Checks that a type is suitable as the allocated type\n/// in a new-expression.\nbool Sema::CheckAllocatedType(QualType AllocType, SourceLocation Loc, SourceRange R) {\n // C++ 5.3.4p1: \"[The] type shall be a complete object type, but not an\n // abstract class type or array thereof.\n if (AllocType->isFunctionType())\n // ...\n else if (AllocType->isReferenceType())\n // ...\n else if (!AllocType->isDependentType() && RequireCompleteSizedType(Loc, AllocType, diag::err_new_incomplete_or_sizeless_type, R))\n // ...\n else if (RequireNonAbstractType(Loc, AllocType, diag::err_allocation_of_abstract_type))\n // ...\n else if (AllocType->isVariablyModifiedType())\n // ...\n else if (AllocType.getAddressSpace() != LangAS::Default && !getLangOpts().OpenCLCPlusPlus)\n return Diag(Loc, diag::err_address_space_qualified_new) << AllocType.getUnqualifiedType() << AllocType.getQualifiers().getAddressSpaceAttributePrintValue();"}}, [l]={ ["clang/test/SemaCXX/address-space-newdelete.cpp"]={"clang/test/SemaCXX/address-space-newdelete.cpp:9:13: error: \'new\' cannot allocate objects of type \'int\' in address space \'1\'","clang/test/SemaCXX/address-space-newdelete.cpp:10:47: error: \'new\' cannot allocate objects of type \'int\' in address space \'1\'","clang/test/SemaCXX/address-space-newdelete.cpp:11:13: error: \'new\' cannot allocate objects of type \'int\' in address space \'1\'","clang/test/SemaCXX/address-space-newdelete.cpp:12:47: error: \'new\' cannot allocate objects of type \'int\' in address space \'1\'","clang/test/SemaCXX/address-space-newdelete.cpp:15:17: error: \'new\' cannot allocate objects of type \'int\' in address space \'1\'","clang/test/SemaCXX/address-space-newdelete.cpp:16:51: error: \'new\' cannot allocate objects of type \'int\' in address space \'1\'","clang/test/SemaCXX/address-space-newdelete.cpp:17:17: error: \'new\' cannot allocate objects of type \'int\' in address space \'1\'","clang/test/SemaCXX/address-space-newdelete.cpp:18:51: error: \'new\' cannot allocate objects of type \'int\' in address space \'1\'"} } }, ["err_addrof_function_constraints_not_satisfied"]={ [c]={{nil,s,"err_addrof_function_constraints_not_satisfied"}}, [d]={{nil,s,"cannot take address of function %0 because its constraints are not satisfied"}}, [e]={{nil,s,"cannot take address of function A because its constraints are not satisfied"}}, [f]=k, [g]="cannot take address of function (.*?) because its constraints are not satisfied", [h]=a, [i]={{nil,s,m}}, [b]={"349636d2bfc3",1575555459,"Implement VectorType conditional operator GNU extension.","Implement VectorType conditional operator GNU extension.\n\nGCC supports the conditional operator on VectorTypes that acts as a\n\'select\' in C++ mode. This patch implements the support. Types are\nconverted as closely to GCC\'s behavior as possible, though in a few\nplaces consistency with our existing vector type support was preferred.\n\nNote that this implementation is different from the OpenCL version in a\nnumber of ways, so it unfortunately required a different implementation.\n\nFirst, the SEMA rules and promotion rules are significantly different.\n\nSecondly, GCC implements COND[i] != 0 ? LHS[i] : RHS[i] (where i is in\nthe range 0- VectorSize, for each element). In OpenCL, the condition is\nCOND[i] < 0 ? LHS[i]: RHS[i].\n\nIn the process of implementing this, it was also required to make the\nexpression COND ? LHS : RHS type dependent if COND is type dependent,\nsince the type is now dependent on the condition. For example:\n\n T ? 1 : 2;\n\nIs not typically type dependent, since the result can be deduced from\nthe operands. HOWEVER, if T is a VectorType now, it could change this\nto a \'select\' (basically a swizzle with a non-constant mask) with the 1\nand 2 being promoted to vectors themselves.\n\nWhile this is a change, it is NOT a standards incompatible change. Based\non my (and D. Gregor\'s, at the time of writing the code) reading of the\nstandard, the expression is supposed to be type dependent if ANY\nsub-expression is type dependent.\n\nDifferential Revision: https://reviews.llvm.org/D71463"}, [j]={{Z,10587,"/// Returns true if we can take the address of the function.\n///\n/// \\param Complain - If true, we\'ll emit a diagnostic\n/// \\param InOverloadResolution - For the purposes of emitting a diagnostic, are\n/// we in overload resolution?\n/// \\param Loc - The location of the statement we\'re complaining about. Ignored\n/// if we\'re not complaining, or if we\'re in overload resolution.\nstatic bool checkAddressOfFunctionIsAvailable(Sema &S, const FunctionDecl *FD, bool Complain, bool InOverloadResolution, SourceLocation Loc) {\n // ...\n if (FD->getTrailingRequiresClause()) {\n // ...\n if (!Satisfaction.IsSatisfied) {\n if (Complain) {\n if (InOverloadResolution) {\n // ...\n } else\n S.Diag(Loc, diag::err_addrof_function_constraints_not_satisfied) << FD;"}} }, ["err_addrof_function_disabled_by_enable_if_attr"]={ [c]="err_addrof_function_disabled_by_enable_if_attr", [d]="cannot take address of function %0 becuase it has one or more non-tautological enable_if conditions", [e]="cannot take address of function A becuase it has one or more non-tautological enable_if conditions", [f]=k, [g]="cannot take address of function (.*?) because it has one or more non\\-tautological enable_if conditions", [h]=a, [i]=m, [b]={"3e3bb95b6951",1449093488,"Add the `pass_object_size` attribute to clang.","Add the `pass_object_size` attribute to clang.\n\n`pass_object_size` is our way of enabling `__builtin_object_size` to\nproduce high quality results without requiring inlining to happen\neverywhere.\n\nA link to the design doc for this attribute is available at the\nDifferential review link below.\n\nDifferential Revision: http://reviews.llvm.org/D13263\n\nllvm-svn: 254554"}, [j]={{Z,10563,"/// Returns true if we can take the address of the function.\n///\n/// \\param Complain - If true, we\'ll emit a diagnostic\n/// \\param InOverloadResolution - For the purposes of emitting a diagnostic, are\n/// we in overload resolution?\n/// \\param Loc - The location of the statement we\'re complaining about. Ignored\n/// if we\'re not complaining, or if we\'re in overload resolution.\nstatic bool checkAddressOfFunctionIsAvailable(Sema &S, const FunctionDecl *FD, bool Complain, bool InOverloadResolution, SourceLocation Loc) {\n if (!isFunctionAlwaysEnabled(S.Context, FD)) {\n if (Complain) {\n if (InOverloadResolution)\n // ...\n else\n S.Diag(Loc, diag::err_addrof_function_disabled_by_enable_if_attr) << FD;"}}, [l]={ ["clang/test/SemaCXX/unaddressable-functions.cpp"]={"clang/test/SemaCXX/unaddressable-functions.cpp:58:8: error: cannot take address of function \'foo\' because it has one or more non-tautological enable_if conditions","clang/test/SemaCXX/unaddressable-functions.cpp:63:15: error: cannot take address of function \'foo\' because it has one or more non-tautological enable_if conditions"} } }, ["err_aix_attr_unsupported_tls_model"]={ [c]={{nil,y,"err_aix_attr_unsupported_tls_model"}}, [d]={{nil,y,"TLS model \'%0\' is not yet supported on AIX"}}, [e]={{nil,y,"TLS model \'A\' is not yet supported on AIX"}}, [f]=k, [g]="TLS model \'(.*?)\' is not yet supported on AIX", [h]=a, [i]={{nil,y,m}}, [b]={"3dbcea8b957a",1615397021,"Reland [clang] Check unsupported types in expressions","Reland [clang] Check unsupported types in expressions\n\nThis was committed as ec6c847179fd, but then reverted after a failure\nin: https://lab.llvm.org/buildbot/#/builders/84/builds/13983\n\nI was not able to reproduce the problem, but I added an extra check\nfor a NULL QualType just in case.\n\nOriginal comit message:\n\nThe patch adds missing diagnostics for cases like:\n\n float F3 = ((__float128)F1 * (__float128)F2) / 2.0f;\n\nSema::checkDeviceDecl (renamed to checkTypeSupport) is changed to work\nwith a type without the corresponding ValueDecl. It is also refactored\nso that host diagnostics for unsupported types can be added here as\nwell.\n\nDifferential Revision: https://reviews.llvm.org/D109315"}, [j]={{n,2044,"static void handleTLSModelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (S.Context.getTargetInfo().getTriple().isOSAIX() && Model != \"global-dynamic\" && Model != \"local-exec\") {\n S.Diag(LiteralLoc, diag::err_aix_attr_unsupported_tls_model) << Model;"}} }, ["err_aix_unsupported_tls_model"]={ [c]={{nil,y,"err_aix_unsupported_tls_model"}}, [d]={{nil,y,"TLS model \'%0\' is not yet supported on AIX"}}, [e]={{nil,y,"TLS model \'A\' is not yet supported on AIX"}}, [f]=k, [g]="TLS model \'(.*?)\' is not yet supported on AIX", [h]=a, [i]={{nil,y,W}}, [b]={"0687578728ea",1610286626,"[C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths.","[C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths.\n\nThis is support for the user-facing options to create importable header units\nfrom headers in the user or system search paths (or to be given an absolute path).\n\nThis means that an incomplete header path will be passed by the driver and the\nlookup carried out using the search paths present when the front end is run.\n\nTo support this, we introduce file fypes for c++-{user,system,header-unit}-header.\nThese terms are the same as the ones used by GCC, to minimise the differences for\ntooling (and users).\n\nThe preprocessor checks for headers before issuing a warning for\n\"#pragma once\" in a header build. We ensure that the importable header units\nare recognised as headers in order to avoid such warnings.\n\nDifferential Revision: https://reviews.llvm.org/D121096"}, [j]={{bb,1892,"#include \"clang/Driver/Options.inc\"\n // ...\n if (Arg *A = Args.getLastArg(OPT_ftlsmodel_EQ)) {\n if (T.isOSAIX()) {\n // ...\n if (Name != \"global-dynamic\" && Name != \"local-exec\")\n Diags.Report(diag::err_aix_unsupported_tls_model) << Name;"}}, [l]={ ["clang/test/Sema/aix-attr-tls_model.c"]={"clang/test/Sema/aix-attr-tls_model.c:9:46: error: TLS model \'local-dynamic\' is not yet supported on AIX","clang/test/Sema/aix-attr-tls_model.c:10:46: error: TLS model \'initial-exec\' is not yet supported on AIX"} } }, ["err_alias_after_tentative"]={ [c]="err_alias_after_tentative", [d]="alias definition of %0 after tentative definition", [e]="alias definition of A after tentative definition", [f]=k, [g]="alias definition of (.*?) after tentative definition", [h]=a, [i]=m, [b]={"d53ffa0a70d8",1382477943,"Treat aliases as definitions.","Treat aliases as definitions.\n\nThis fixes pr17639.\n\nBefore this patch clang would consider\n\nvoid foo(void) __attribute((alias(\"__foo\")));\n\na declaration. It now correctly handles it as a definition.\n\nInitial patch by Alp Toker. I added support for variables.\n\nllvm-svn: 193200"}, [j]={{o,3041,"/// checkNewAttributesAfterDef - If we already have a definition, check that\n/// there are no new attributes in this declaration.\nstatic void checkNewAttributesAfterDef(Sema &S, Decl *New, const Decl *Old) {\n // ...\n for (unsigned I = 0, E = NewAttributes.size(); I != E;) {\n // ...\n if (isa<AliasAttr>(NewAttribute) || isa<IFuncAttr>(NewAttribute)) {\n if (FunctionDecl *FD = dyn_cast<FunctionDecl>(New)) {\n // ...\n } else {\n // ...\n unsigned Diag = cast<VarDecl>(Def)->isThisDeclarationADefinition() == VarDecl::TentativeDefinition ? diag::err_alias_after_tentative : diag::err_redefinition;"}}, [l]={ ["clang/test/Sema/alias-redefinition.c"]={"clang/test/Sema/alias-redefinition.c:32:12: error: alias definition of \'var4\' after tentative definition"} } }, ["err_alias_declaration_not_identifier"]={ [c]="err_alias_declaration_not_identifier", [d]="name defined in alias declaration must be an identifier", [e]="name defined in alias declaration must be an identifier", [f]=k, [g]="name defined in alias declaration must be an identifier", [h]=a, [i]=V, [b]={"dda56e4b4a9c",1302877477,"Support for C++11 (non-template) alias declarations.","Support for C++11 (non-template) alias declarations.\n\nllvm-svn: 129567"}, [j]={{db,905,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\n // ...\n // Name must be an identifier.\n if (D.Name.getKind() != UnqualifiedIdKind::IK_Identifier) {\n Diag(D.Name.StartLocation, diag::err_alias_declaration_not_identifier);"},{db,910,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\n // ...\n // Name must be an identifier.\n if (D.Name.getKind() != UnqualifiedIdKind::IK_Identifier) {\n // ...\n } else if (D.TypenameLoc.isValid())\n Diag(D.TypenameLoc, diag::err_alias_declaration_not_identifier) << FixItHint::CreateRemoval(SourceRange(D.TypenameLoc, D.SS.isNotEmpty() ? D.SS.getEndLoc() : D.TypenameLoc));"},{db,915,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\n // ...\n // Name must be an identifier.\n if (D.Name.getKind() != UnqualifiedIdKind::IK_Identifier) {\n // ...\n } else if (D.TypenameLoc.isValid())\n // ...\n else if (D.SS.isNotEmpty())\n Diag(D.SS.getBeginLoc(), diag::err_alias_declaration_not_identifier) << FixItHint::CreateRemoval(D.SS.getRange());"}}, [l]={ ["clang/test/CXX/temp/temp.decls/p3.cpp"]={"clang/test/CXX/temp/temp.decls/p3.cpp:7:7: error: name defined in alias declaration must be an identifier"} } }, ["err_alias_declaration_pack_expansion"]={ [c]="err_alias_declaration_pack_expansion", [d]="alias declaration cannot be a pack expansion", [e]="alias declaration cannot be a pack expansion", [f]=k, [g]="alias declaration cannot be a pack expansion", [h]=a, [i]=V, [b]={"22a250cd5d8e",1482120533,"[c++1z] P0195R2: Support pack-expansion of using-declarations.","[c++1z] P0195R2: Support pack-expansion of using-declarations.\n\nThis change introduces UsingPackDecl as a marker for the set of UsingDecls\nproduced by pack expansion of a single (unresolved) using declaration. This is\nnot strictly necessary (we just need to be able to map from the original using\ndeclaration to its expansions somehow), but it\'s useful to maintain the\ninvariant that each declaration reference instantiates to refer to one\ndeclaration.\n\nllvm-svn: 290080"}, [j]={{db,918,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\n // ...\n if (D.EllipsisLoc.isValid())\n Diag(D.EllipsisLoc, diag::err_alias_declaration_pack_expansion) << FixItHint::CreateRemoval(SourceRange(D.EllipsisLoc));"}} }, ["err_alias_declaration_specialization"]={ [c]="err_alias_declaration_specialization", [d]="%select{partial specialization|explicit specialization|explicit instantiation}0 of alias templates is not permitted", [e]={{nil,nil,{{"partial specialization","explicit specialization","explicit instantiation"}," of alias templates is not permitted"}}}, [f]=k, [g]="(?:partial specialization|explicit specialization|explicit instantiation) of alias templates is not permitted", [h]=a, [i]=V, [b]={"3f1b5d077b7e",1304632627,"Implement support for C++0x alias templates.","Implement support for C++0x alias templates.\n\nllvm-svn: 130953"}, [j]={{db,897,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\n // ...\n if (SpecKind != -1) {\n // ...\n Diag(Range.getBegin(), diag::err_alias_declaration_specialization) << SpecKind << Range;"}}, [l]={ ["clang/test/CXX/temp/temp.decls/p3.cpp"]={"clang/test/CXX/temp/temp.decls/p3.cpp:4:29: error: partial specialization of alias templates is not permitted","clang/test/CXX/temp/temp.decls/p3.cpp:5:1: error: explicit specialization of alias templates is not permitted","clang/test/CXX/temp/temp.decls/p3.cpp:6:1: error: explicit instantiation of alias templates is not permitted"} } }, ["err_alias_is_definition"]={ [c]="err_alias_is_definition", [d]="definition %0 cannot also be an %select{alias|ifunc}1", [e]={{nil,nil,{"definition A cannot also be an ",{"alias","ifunc"}}}}, [f]=k, [g]="definition (.*?) cannot also be an (?:alias|ifunc)", [h]=a, [i]=m, [b]={"2dc814664385",1421658028,"Sema: Variable definitions cannot be __attribute__((alias))","Sema: Variable definitions cannot be __attribute__((alias))\n\nThings that are OK:\n extern int var1 __attribute((alias(\"v1\")));\n static int var2 __attribute((alias(\"v2\")));\n\nThings that are not OK:\n int var3 __attribute((alias(\"v3\")));\n extern int var4 __attribute((alias(\"v4\"))) = 4;\n\nWe choose to accpet:\n struct S { static int var5 __attribute((alias(\"v5\"))); };\n\n This code causes assertion failues in GCC 4.8 and ICC 13.0.1, we have\n no reason to reject it.\n\nThis partially fixes PR22217.\n\nllvm-svn: 226436"}, [j]={{o,6968,"static void checkAttributesAfterMerging(Sema &S, NamedDecl &ND) {\n // ...\n if (auto *VD = dyn_cast<VarDecl>(&ND)) {\n if (VD->hasInit()) {\n if (const auto *Attr = VD->getAttr<AliasAttr>()) {\n // ...\n S.Diag(Attr->getLocation(), diag::err_alias_is_definition) << VD << 0;"},{o,15265,"Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D, SkipBodyInfo *SkipBody, FnBodyKind BodyKind) {\n // ...\n // Check for defining attributes before the check for redefinition.\n if (const auto *Attr = FD->getAttr<AliasAttr>()) {\n Diag(Attr->getLocation(), diag::err_alias_is_definition) << FD << 0;"},{o,15270,"Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D, SkipBodyInfo *SkipBody, FnBodyKind BodyKind) {\n // ...\n if (const auto *Attr = FD->getAttr<IFuncAttr>()) {\n Diag(Attr->getLocation(), diag::err_alias_is_definition) << FD << 1;"},{n,1980,"static void handleIFuncAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (FD->isThisDeclarationADefinition()) {\n S.Diag(AL.getLoc(), diag::err_alias_is_definition) << FD << 1;"},{n,2003,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // Aliases should be on declarations, not definitions.\n if (const auto *FD = dyn_cast<FunctionDecl>(D)) {\n if (FD->isThisDeclarationADefinition()) {\n S.Diag(AL.getLoc(), diag::err_alias_is_definition) << FD << 0;"},{n,2009,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // Aliases should be on declarations, not definitions.\n if (const auto *FD = dyn_cast<FunctionDecl>(D)) {\n // ...\n } else {\n // ...\n if (VD->isThisDeclarationADefinition() && VD->isExternallyVisible()) {\n S.Diag(AL.getLoc(), diag::err_alias_is_definition) << VD << 0;"},{n,7662,"static void handleWebAssemblyExportNameAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (FD->isThisDeclarationADefinition()) {\n S.Diag(D->getLocation(), diag::err_alias_is_definition) << FD << 0;"}}, [l]={ ["clang/test/Sema/alias-redefinition.c"]={"clang/test/Sema/alias-redefinition.c:23:19: error: definition \'fun5\' cannot also be an alias","clang/test/Sema/alias-redefinition.c:25:23: error: definition \'var1\' cannot also be an alias","clang/test/Sema/alias-redefinition.c:26:30: error: definition \'var2\' cannot also be an alias"} } }, ["err_alias_not_supported_on_darwin"]={ [c]="err_alias_not_supported_on_darwin", [d]={{nil,X,"aliases are not supported on darwin"},{T,nil,"only weak aliases are supported on darwin"}}, [e]={{nil,X,"aliases are not supported on darwin"},{T,nil,"only weak aliases are supported on darwin"}}, [f]=k, [g]="aliases are not supported on darwin", [h]=a, [i]=m, [b]={"0017c5fa92ad",1291735403,"Fix PR8720 by printing an error message with a substring that the gcc testsuite searches for.","Fix PR8720 by printing an error message with a substring that the gcc testsuite searches for.\n\nllvm-svn: 121137"}, [j]={{n,1993,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (S.Context.getTargetInfo().getTriple().isOSDarwin()) {\n S.Diag(AL.getLoc(), diag::err_alias_not_supported_on_darwin);"}}, [l]={ ["clang/test/Sema/attr-alias.c"]={"clang/test/Sema/attr-alias.c:5:29: error: aliases are not supported on darwin"} } }, ["err_alias_not_supported_on_nvptx"]={ [c]="err_alias_not_supported_on_nvptx", [d]="CUDA does not support aliases", [e]="CUDA does not support aliases", [f]=k, [g]="CUDA does not support aliases", [h]=a, [i]=m, [b]={"a8f0254bc1a4",1453584490,"[CUDA] Reject the alias attribute in CUDA device code.","[CUDA] Reject the alias attribute in CUDA device code.\n\nSummary: CUDA (well, strictly speaking, NVPTX) doesn\'t support aliases.\n\nReviewers: echristo\n\nSubscribers: cfe-commits, jhen, tra\n\nDifferential Revision: http://reviews.llvm.org/D16502\n\nllvm-svn: 258641"}, [j]={{n,1997,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (S.Context.getTargetInfo().getTriple().isNVPTX()) {\n S.Diag(AL.getLoc(), diag::err_alias_not_supported_on_nvptx);"}}, [l]={ ["clang/test/SemaCUDA/alias.cu"]={"clang/test/SemaCUDA/alias.cu:6:16: error: CUDA does not support aliases"} } }, ["err_alias_template_extra_headers"]={ [c]="err_alias_template_extra_headers", [d]="extraneous template parameter list in alias template declaration", [e]="extraneous template parameter list in alias template declaration", [f]=k, [g]="extraneous template parameter list in alias template declaration", [h]=a, [i]=m, [b]={"3f1b5d077b7e",1304632627,"Implement support for C++0x alias templates.","Implement support for C++0x alias templates.\n\nllvm-svn: 130953"}, [j]={{M,13299,"Decl *Sema::ActOnAliasDeclaration(Scope *S, AccessSpecifier AS, MultiTemplateParamsArg TemplateParamLists, SourceLocation UsingLoc, UnqualifiedId &Name, const ParsedAttributesView &AttrList, TypeResult Type, Decl *DeclFromDeclSpec) {\n // ...\n if (TemplateParamLists.size()) {\n // ...\n if (TemplateParamLists.size() != 1) {\n Diag(UsingLoc, diag::err_alias_template_extra_headers) << SourceRange(TemplateParamLists[1]->getTemplateLoc(), TemplateParamLists[TemplateParamLists.size() - 1]->getRAngleLoc());"}}, [l]={ ["clang/test/SemaCXX/alias-template.cpp"]={"clang/test/SemaCXX/alias-template.cpp:139:45: error: extraneous template parameter list in alias template declaration"} } }, ["err_alias_to_undefined"]={ [c]="err_alias_to_undefined", [d]="%select{alias|ifunc}0 must point to a defined %select{variable or |}1function", [e]={{nil,nil,{{"alias","ifunc"}," must point to a defined ",{"variable or ",a},"function"}}}, [f]=k, [g]="(?:alias|ifunc) must point to a defined (?:variable or |)function", [h]=a, [i]={{nil,B,W},{"7.1",nil,m}}, [b]={"0fad0d772433",1382449866,"This patch causes clang to reject alias attributes that point to undefined","This patch causes clang to reject alias attributes that point to undefined\nnames. For example, with this patch we now reject\n\nvoid f1(void) __attribute__((alias(\"g1\")));\n\nThis patch is implemented in CodeGen. It is quiet a bit simpler and more\ncompatible with gcc than implementing it in Sema. The downside is that the\nerrors only fire during -emit-llvm.\n\nllvm-svn: 193161"}, [j]={{"clang/lib/CodeGen/CodeGenModule.cpp",578,"static bool checkAliasedGlobal(DiagnosticsEngine &Diags, SourceLocation Location, bool IsIFunc, const llvm::GlobalValue *Alias, const llvm::GlobalValue *&GV, const llvm::MapVector<GlobalDecl, StringRef> &MangledDeclNames, SourceRange AliasRange) {\n // ...\n if (GV->isDeclaration()) {\n Diags.Report(Location, diag::err_alias_to_undefined) << IsIFunc << IsIFunc;"},{"clang/lib/CodeGen/CodeGenModule.cpp",602,"static bool checkAliasedGlobal(DiagnosticsEngine &Diags, SourceLocation Location, bool IsIFunc, const llvm::GlobalValue *Alias, const llvm::GlobalValue *&GV, const llvm::MapVector<GlobalDecl, StringRef> &MangledDeclNames, SourceRange AliasRange) {\n // ...\n if (IsIFunc) {\n // ...\n if (!F) {\n Diags.Report(Location, diag::err_alias_to_undefined) << IsIFunc << IsIFunc;"}}, [l]={ ["clang/test/Sema/attr-alias-elf.c"]={"clang/test/Sema/attr-alias-elf.c:7:30: error: alias must point to a defined variable or function","clang/test/Sema/attr-alias-elf.c:10:30: error: alias must point to a defined variable or function","clang/test/Sema/attr-alias-elf.c:49:30: error: alias must point to a defined variable or function","clang/test/Sema/attr-alias-elf.c:52:30: error: alias must point to a defined variable or function","clang/test/Sema/attr-alias-elf.c:56:30: error: alias must point to a defined variable or function"} } }, ["err_align_value_attribute_argument_not_int"]={ [c]="err_align_value_attribute_argument_not_int", [d]="\'align_value\' attribute requires integer constant", [e]="\'align_value\' attribute requires integer constant", [f]=k, [g]="\'align_value\' attribute requires integer constant", [h]=a, [i]=m, [b]={"1b0d24e03abf",1412284885,"Initial support for the align_value attribute","Initial support for the align_value attribute\n\nThis adds support for the align_value attribute. This attribute is supported by\nIntel\'s compiler (versions 14.0+), and several of my HPC users have requested\nsupport in Clang. It specifies an alignment assumption on the values to which a\npointer points, and is used by numerical libraries to encourage efficient\ngeneration of vector code.\n\nOf course, we already have an aligned attribute that can specify enhanced\nalignment for a type, so why is this additional attribute important? The\nproblem is that if you want to specify that an input array of T is, say,\n64-byte aligned, you could try this:\n\n typedef double aligned_double attribute((aligned(64)));\n void foo(aligned_double *P) {\n double x = P[0]; // This is fine.\n double y = P[1]; // What alignment did those doubles have again?\n }\n\nthe access here to P[1] causes problems. P was specified as a pointer to type\naligned_double, and any object of type aligned_double must be 64-byte aligned.\nBut if P[0] is 64-byte aligned, then P[1] cannot be, and this access causes\nundefined behavior. Getting round this problem requires a lot of awkward\ncasting and hand-unrolling of loops, all of which is bad.\n\nWith the align_value attribute, we can accomplish what we\'d like in a well\ndefined way:\n\n typedef double *aligned_double_ptr attribute((align_value(64)));\n void foo(aligned_double_ptr P) {\n double x = P[0]; // This is fine.\n double y = P[1]; // This is fine too.\n }\n\nThis attribute does not create a new type (and so it not part of the type\nsystem), and so will only \"propagate\" through templates, auto, etc. by\noptimizer deduction after inlining. This seems consistent with Intel\'s\nimplementation (thanks to Alexey for confirming the various Intel-compiler\nbehaviors).\n\nAs a final note, I would have chosen to call this aligned_value, not\nalign_value, for better naming consistency with the aligned attribute, but I\nthink it would be more useful to users to adopt Intel\'s name.\n\nllvm-svn: 218910"}, [j]={{n,4331,"void Sema::AddAlignValueAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E) {\n // ...\n if (!E->isValueDependent()) {\n // ...\n ExprResult ICE = VerifyIntegerConstantExpression(E, &Alignment, diag::err_align_value_attribute_argument_not_int);"}}, [l]={ ["clang/test/Sema/align_value.c"]={"clang/test/Sema/align_value.c:23:45: error: \'align_value\' attribute requires integer constant"} } }, ["err_alignas_attribute_wrong_decl_type"]={ [c]="err_alignas_attribute_wrong_decl_type", [d]={{nil,E,"%0 attribute cannot be applied to %select{a function parameter|a variable with \'register\' storage class|a \'catch\' variable|a bit-field|an enumeration}1"},{x,nil,"%0 attribute cannot be applied to a %select{function parameter|variable with \'register\' storage class|\'catch\' variable|bit-field}1"}}, [e]={{nil,E,{"A attribute cannot be applied to ",{"a function parameter","a variable with \'register\' storage class","a \'catch\' variable","a bit-field","an enumeration"}}},{x,nil,{"A attribute cannot be applied to a ",{"function parameter","variable with \'register\' storage class","\'catch\' variable","bit-field"}}}}, [f]=k, [g]="(.*?) attribute cannot be applied to (?:a function parameter|a variable with \'register\' storage class|a \'catch\' variable|a bit\\-field|an enumeration)", [h]=a, [i]=m, [b]={"1dba27cd4942",1359450129,"Implement C++11 [dcl.align]p1 and C11 6.7.5/2 rules for alignas and _Alignas.","Implement C++11 [dcl.align]p1 and C11 6.7.5/2 rules for alignas and _Alignas.\n\nllvm-svn: 173779"}, [j]={{n,4435,"/// Perform checking of type validity\n///\n/// C++11 [dcl.align]p1:\n/// An alignment-specifier may be applied to a variable or to a class\n/// data member, but it shall not be applied to a bit-field, a function\n/// parameter, the formal parameter of a catch clause, or a variable\n/// declared with the register storage class specifier. An\n/// alignment-specifier may also be applied to the declaration of a class\n/// or enumeration type.\n/// CWG 2354:\n/// CWG agreed to remove permission for alignas to be applied to\n/// enumerations.\n/// C11 6.7.5/2:\n/// An alignment attribute shall not be specified in a declaration of\n/// a typedef, or a bit-field, or a function, or a parameter, or an\n/// object declared with the register storage-class specifier.\nstatic bool validateAlignasAppliedType(Sema &S, Decl *D, const AlignedAttr &Attr, SourceLocation AttrLoc) {\n // ...\n if (DiagKind != -1) {\n return S.Diag(AttrLoc, diag::err_alignas_attribute_wrong_decl_type) << &Attr << DiagKind;"}}, [l]={ ["clang/test/SemaCXX/attr-cxx0x.cpp"]={"clang/test/SemaCXX/attr-cxx0x.cpp:11:16: error: \'alignas\' attribute cannot be applied to a bit-field","clang/test/SemaCXX/attr-cxx0x.cpp:14:8: error: \'alignas\' attribute cannot be applied to a function parameter","clang/test/SemaCXX/attr-cxx0x.cpp:15:3: error: \'alignas\' attribute cannot be applied to a variable with \'register\' storage class","clang/test/SemaCXX/attr-cxx0x.cpp:17:12: error: \'alignas\' attribute cannot be applied to a \'catch\' variable"} } }, ["err_alignas_mismatch"]={ [c]="err_alignas_mismatch", [d]="redeclaration has different alignment requirement (%1 vs %0)", [e]="redeclaration has different alignment requirement (B vs A)", [f]=k, [g]="redeclaration has different alignment requirement \\((.*?) vs (.*?)\\)", [h]=a, [i]=m, [b]={"bc8caaf05f09",1361508939,"Implement C++11 [dcl.align]p6-p8, and C11 6.7.5/7. This had to be split out of","Implement C++11 [dcl.align]p6-p8, and C11 6.7.5/7. This had to be split out of\nthe normal attribute-merging path, because we can\'t merge alignment attributes\nwithout knowing the complete set of alignment attributes which apply to a\nparticular declaration.\n\nllvm-svn: 175861"}, [j]={{o,2841,"/// Merge alignment attributes from \\p Old to \\p New, taking into account the\n/// special semantics of C11\'s _Alignas specifier and C++11\'s alignas attribute.\n///\n/// \\return \\c true if any attributes were added to \\p New.\nstatic bool mergeAlignedAttrs(Sema &S, NamedDecl *New, Decl *Old) {\n // ...\n if (OldAlignasAttr && NewAlignasAttr && OldAlign != NewAlign) {\n // ...\n if (OldAlign != NewAlign) {\n S.Diag(NewAlignasAttr->getLocation(), diag::err_alignas_mismatch) << (unsigned)S.Context.toCharUnitsFromBits(OldAlign).getQuantity() << (unsigned)S.Context.toCharUnitsFromBits(NewAlign).getQuantity();"}}, [l]={ ["clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p8.cpp"]={"clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p8.cpp:6:1: error: redeclaration has different alignment requirement (4 vs 8)"} } }, ["err_alignas_missing_on_definition"]={ [c]="err_alignas_missing_on_definition", [d]="%0 must be specified on definition if it is specified on any declaration", [e]="A must be specified on definition if it is specified on any declaration", [f]=k, [g]="(.*?) must be specified on definition if it is specified on any declaration", [h]=a, [i]=m, [b]={"bc8caaf05f09",1361508939,"Implement C++11 [dcl.align]p6-p8, and C11 6.7.5/7. This had to be split out of","Implement C++11 [dcl.align]p6-p8, and C11 6.7.5/7. This had to be split out of\nthe normal attribute-merging path, because we can\'t merge alignment attributes\nwithout knowing the complete set of alignment attributes which apply to a\nparticular declaration.\n\nllvm-svn: 175861"}, [j]={{o,2857,"/// Merge alignment attributes from \\p Old to \\p New, taking into account the\n/// special semantics of C11\'s _Alignas specifier and C++11\'s alignas attribute.\n///\n/// \\return \\c true if any attributes were added to \\p New.\nstatic bool mergeAlignedAttrs(Sema &S, NamedDecl *New, Decl *Old) {\n // ...\n if (OldAlignasAttr && !NewAlignasAttr && isAttributeTargetADefinition(New)) {\n // ...\n S.Diag(New->getLocation(), diag::err_alignas_missing_on_definition) << OldAlignasAttr;"},{o,3085,"/// checkNewAttributesAfterDef - If we already have a definition, check that\n/// there are no new attributes in this declaration.\nstatic void checkNewAttributesAfterDef(Sema &S, Decl *New, const Decl *Old) {\n // ...\n for (unsigned I = 0, E = NewAttributes.size(); I != E;) {\n // ...\n if (isa<C11NoReturnAttr>(NewAttribute)) {\n // ...\n } else if (isa<UuidAttr>(NewAttribute)) {\n // ...\n } else if (const AlignedAttr *AA = dyn_cast<AlignedAttr>(NewAttribute)) {\n if (AA->isAlignas()) {\n // ...\n S.Diag(Def->getLocation(), diag::err_alignas_missing_on_definition) << AA;"}}, [l]={ ["clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p6.cpp"]={"clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p6.cpp:18:5: error: \'alignas\' must be specified on definition if it is specified on any declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p6.cpp:25:5: error: \'alignas\' must be specified on definition if it is specified on any declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p6.cpp:27:5: error: \'alignas\' must be specified on definition if it is specified on any declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p6.cpp:33:8: error: \'alignas\' must be specified on definition if it is specified on any declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p6.cpp:43:8: error: \'alignas\' must be specified on definition if it is specified on any declaration"} } }, ["err_alignas_underaligned"]={ [c]="err_alignas_underaligned", [d]="requested alignment is less than minimum alignment of %1 for type %0", [e]="requested alignment is less than minimum alignment of B for type A", [f]=k, [g]="requested alignment is less than minimum alignment of (.*?) for type (.*?)", [h]=a, [i]=m, [b]={"848e1f19605a",1359706328,"Implement [dcl.align]p5 and C11 6.7.5/4: alignas cannot underalign.","Implement [dcl.align]p5 and C11 6.7.5/4: alignas cannot underalign.\nAlso support alignas(0), which C++11 and C11 require us to ignore.\n\nllvm-svn: 174157"}, [j]={{n,4616,"void Sema::CheckAlignasUnderalignment(Decl *D) {\n // ...\n if (Align && DiagTy->isSizelessType()) {\n // ...\n } else if (AlignasAttr && Align) {\n // ...\n if (NaturalAlign > RequestedAlign)\n Diag(AlignasAttr->getLocation(), diag::err_alignas_underaligned) << DiagTy << (unsigned)NaturalAlign.getQuantity();"}}, [l]={ ["clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp"]={"clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:3:1: error: requested alignment is less than minimum alignment of 4 for type \'int\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:4:12: error: requested alignment is less than minimum alignment of 4 for type \'int\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:6:23: error: requested alignment is less than minimum alignment of 4 for type \'int\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:9:19: error: requested alignment is less than minimum alignment of 4 for type \'int\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:12:1: error: requested alignment is less than minimum alignment of 4 for type \'int\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:21:8: error: requested alignment is less than minimum alignment of 4 for type \'S2\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:24:8: error: requested alignment is less than minimum alignment of 8 for type \'S3\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:27:8: error: requested alignment is less than minimum alignment of 8 for type \'S4\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:30:3: error: requested alignment is less than minimum alignment of 8 for type \'S1\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:40:7: error: requested alignment is less than minimum alignment of 8 for type \'S1\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:41:7: error: requested alignment is less than minimum alignment of 8 for type \'S6\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:42:7: error: requested alignment is less than minimum alignment of 8 for type \'S7\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:45:8: error: requested alignment is less than minimum alignment of 2 for type \'X<1, 2, char>\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:46:3: error: requested alignment is less than minimum alignment of 2 for type \'short\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:45:8: error: requested alignment is less than minimum alignment of 2 for type \'X<1, 1, short>\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:46:3: error: requested alignment is less than minimum alignment of 2 for type \'short\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:46:3: error: requested alignment is less than minimum alignment of 8 for type \'S1\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:45:8: error: requested alignment is less than minimum alignment of 8 for type \'X<4, 4, S1>\'","clang/test/CXX/dcl.dcl/dcl.attr/dcl.align/p5.cpp:60:3: error: requested alignment is less than minimum alignment of 2 for type \'short\'"} } }, ["err_aligned_allocation_unavailable"]={ [c]={{nil,A,"err_aligned_allocation_unavailable"}}, [d]={{nil,r,"aligned %select{allocation|deallocation}0 function of type \'%1\' is %select{only|not}4 available on %2%select{ %3 or newer|}4"},{"11.1",A,"aligned %select{allocation|deallocation}0 function of type \'%1\' is only available on %2 %3 or newer"}}, [e]={{nil,r,{"aligned ",{"allocation","deallocation"}," function of type \'B\' is ",{"only","not"}," available on C",{" D or newer",a}}},{"11.1",A,{"aligned ",{"allocation","deallocation"}," function of type \'B\' is only available on C D or newer"}}}, [f]=k, [g]="aligned (?:allocation|deallocation) function of type \'(.*?)\' is (?:only|not) available on (.*?)(?: (.*?) or newer|)", [h]=a, [i]={{nil,A,m}}, [b]={"e5015abf185b",1533337957,"[Preprocessor] Allow libc++ to detect when aligned allocation is unavailable.","[Preprocessor] Allow libc++ to detect when aligned allocation is unavailable.\n\nLibc++ needs to know when aligned allocation is supported by clang, but is\notherwise unavailable at link time. Otherwise, libc++ will incorrectly end up\ngenerating calls to `__builtin_operator_new`/`__builtin_operator_delete` with\nalignment arguments.\n\nThis patch implements the following changes:\n\n* The `__cpp_aligned_new` feature test macro to no longer be defined when\n aligned allocation is otherwise enabled but unavailable.\n\n* The Darwin driver no longer passes `-faligned-alloc-unavailable` when the\n user manually specifies `-faligned-allocation` or `-fno-aligned-allocation`.\n\n* Instead of a warning Clang now generates a hard error when an aligned\n allocation or deallocation function is referenced but unavailable.\n\nPatch by Eric Fiselier.\n\nReviewers: rsmith, vsapsai, erik.pilkington, ahatanak, dexonsmith\n\nReviewed By: rsmith\n\nSubscribers: Quuxplusone, cfe-commits\n\nDifferential Revision: https://reviews.llvm.org/D45015\n\nllvm-svn: 338934"}, [j]={{D,1968,"// Emit a diagnostic if an aligned allocation/deallocation function that is not\n// implemented in the standard library is selected.\nvoid Sema::diagnoseUnavailableAlignedAllocation(const FunctionDecl &FD, SourceLocation Loc) {\n if (isUnavailableAlignedAllocationFunction(FD)) {\n // ...\n Diag(Loc, diag::err_aligned_allocation_unavailable) << IsDelete << FD.getType().getAsString() << OSName << OSVersion.getAsString() << OSVersion.empty();"}}, [l]={ ["clang/test/SemaCXX/unavailable_aligned_allocation.cpp"]={"clang/test/SemaCXX/unavailable_aligned_allocation.cpp:52:13: error: aligned allocation function of type \'void *(unsigned long, enum std::align_val_t)\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:52:13: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:53:7: error: aligned allocation function of type \'void *(unsigned long, enum std::align_val_t)\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:53:7: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:54:3: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:55:7: error: aligned allocation function of type \'void *(std::size_t, std::align_val_t, const std::nothrow_t &) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:55:7: error: aligned deallocation function of type \'void (void *, std::align_val_t, const std::nothrow_t &) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:57:14: error: aligned allocation function of type \'void *(unsigned long, enum std::align_val_t)\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:57:14: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:58:8: error: aligned allocation function of type \'void *(unsigned long, enum std::align_val_t)\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:58:8: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:59:3: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:60:8: error: aligned allocation function of type \'void *(std::size_t, std::align_val_t, const std::nothrow_t &) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:60:8: error: aligned deallocation function of type \'void (void *, std::align_val_t, const std::nothrow_t &) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:107:13: error: aligned allocation function of type \'void *(unsigned long, enum std::align_val_t)\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:107:13: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:140:16: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:173:13: error: aligned allocation function of type \'void *(unsigned long, enum std::align_val_t)\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:174:3: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:175:7: error: aligned allocation function of type \'void *(unsigned long, enum std::align_val_t)\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:176:3: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:177:7: error: aligned allocation function of type \'void *(unsigned long, enum std::align_val_t)\' is not available on z/OS","clang/test/SemaCXX/unavailable_aligned_allocation.cpp:178:3: error: aligned deallocation function of type \'void (void *, enum std::align_val_t) noexcept\' is not available on z/OS"} } }, ["err_aligned_attribute_argument_not_int"]={ [c]="err_aligned_attribute_argument_not_int", [d]="\'aligned\' attribute requires integer constant", [e]="\'aligned\' attribute requires integer constant", [f]=k, [g]="\'aligned\' attribute requires integer constant", [h]=a, [i]=m, [b]={"e2b3744890f6",1336171132,"Move Sema::VerifyIntegerConstantExpression() and","Move Sema::VerifyIntegerConstantExpression() and\nSema::ConvertToIntegralOrEnumerationType() from PartialDiagnostics to\nabstract \"diagnoser\" classes. Not much of a win here, but we\'re\n-several PartialDiagnostics.\n\nllvm-svn: 156217"}, [j]={{n,4473,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\n // ...\n ExprResult ICE = VerifyIntegerConstantExpression(E, &Alignment, diag::err_aligned_attribute_argument_not_int);"}}, [l]={ ["clang/test/Parser/cxx0x-attributes.cpp"]={"clang/test/Parser/cxx0x-attributes.cpp:227:9: error: \'aligned\' attribute requires integer constant"} } }, ["err_alignment_dependent_typedef_name"]={ [c]="err_alignment_dependent_typedef_name", [d]="requested alignment is dependent but declaration is not dependent", [e]="requested alignment is dependent but declaration is not dependent", [f]=k, [g]="requested alignment is dependent but declaration is not dependent", [h]=a, [i]=m, [b]={"26a1e0ef760a",1428374229,"[Sema] Don\'t permit dependent alignments on non-dependent typedef-names","[Sema] Don\'t permit dependent alignments on non-dependent typedef-names\n\nA dependent alignment attribute (like __attribute__((aligned(...))) or\n__declspec(align(...))) on a non-dependent typedef or using declaration\nposes a considerable challenge: the type is _not_ dependent, the size\n_may_ be dependent if the type is used as an array type, the alignment\n_is_ dependent.\n\nIt is reasonable for a compiler to be able to query the size and\nalignment of a complete type. Let\'s help that become an invariant.\n\nThis fixes PR22042.\n\nDifferential Revision: http://reviews.llvm.org/D8693\n\nllvm-svn: 234280"}, [j]={{n,4457,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\n // ...\n if (E->isValueDependent()) {\n // We can\'t support a dependent alignment on a non-dependent type,\n // because we have no way to model that a type is \"alignment-dependent\"\n // but not dependent in any other way.\n if (const auto *TND = dyn_cast<TypedefNameDecl>(D)) {\n if (!TND->getUnderlyingType()->isDependentType()) {\n Diag(AttrLoc, diag::err_alignment_dependent_typedef_name) << E->getSourceRange();"},{n,4547,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, TypeSourceInfo *TS, bool IsPackExpansion) {\n // ...\n if (TS->getType()->isDependentType()) {\n // We can\'t support a dependent alignment on a non-dependent type,\n // because we have no way to model that a type is \"type-dependent\"\n // but not dependent in any other way.\n if (const auto *TND = dyn_cast<TypedefNameDecl>(D)) {\n if (!TND->getUnderlyingType()->isDependentType()) {\n Diag(AttrLoc, diag::err_alignment_dependent_typedef_name) << TS->getTypeLoc().getSourceRange();"}}, [l]={ ["clang/test/SemaCXX/alignof.cpp"]={"clang/test/SemaCXX/alignof.cpp:91:30: error: requested alignment is dependent but declaration is not dependent","clang/test/SemaCXX/alignof.cpp:97:26: error: requested alignment is dependent but declaration is not dependent"} } }, ["err_alignment_not_power_of_two"]={ [c]="err_alignment_not_power_of_two", [d]="requested alignment is not a power of 2", [e]="requested alignment is not a power of 2", [f]=k, [g]="requested alignment is not a power of 2", [h]=a, [i]=m, [b]={"bcc06085a894",1410130694,"Add __builtin_assume and __builtin_assume_aligned using @llvm.assume.","Add __builtin_assume and __builtin_assume_aligned using @llvm.assume.\n\nThis makes use of the recently-added @llvm.assume intrinsic to implement a\n__builtin_assume(bool) intrinsic (to provide additional information to the\noptimizer). This hooks up __assume in MS-compatibility mode to mirror\n__builtin_assume (the semantics have been intentionally kept compatible), and\nimplements GCC\'s __builtin_assume_aligned as assume((p - o) & mask == 0). LLVM\nnow contains special logic to deal with assumptions of this form.\n\nllvm-svn: 217349"}, [j]={{t,339,"/// Check that the value argument for __builtin_is_aligned(value, alignment) and\n/// __builtin_aligned_{up,down}(value, alignment) is an integer or a pointer\n/// type (but not a function pointer) and that the alignment is a power-of-two.\nstatic bool SemaBuiltinAlignment(Sema &S, CallExpr *TheCall, unsigned ID) {\n // ...\n // We can\'t check validity of alignment if it is value dependent.\n if (!AlignOp->isValueDependent() && AlignOp->EvaluateAsInt(AlignResult, S.Context, Expr::SE_AllowSideEffects)) {\n // ...\n if (!AlignValue.isPowerOf2()) {\n S.Diag(AlignOp->getExprLoc(), diag::err_alignment_not_power_of_two);"},{t,8631,"/// Handle __builtin_alloca_with_align. This is declared\n/// as (size_t, size_t) where the second size_t must be a power of 2 greater\n/// than 8.\nbool Sema::SemaBuiltinAllocaWithAlign(CallExpr *TheCall) {\n // ...\n // We can\'t check the value of a dependent argument.\n if (!Arg->isTypeDependent() && !Arg->isValueDependent()) {\n // ...\n if (!Result.isPowerOf2())\n return Diag(TheCall->getBeginLoc(), diag::err_alignment_not_power_of_two) << Arg->getSourceRange();"},{t,8674,"/// Handle __builtin_assume_aligned. This is declared\n/// as (const void*, size_t, ...) and can take one optional constant int arg.\nbool Sema::SemaBuiltinAssumeAligned(CallExpr *TheCall) {\n // ...\n // We can\'t check the value of a dependent argument.\n if (!SecondArg->isValueDependent()) {\n // ...\n if (!Result.isPowerOf2())\n return Diag(TheCall->getBeginLoc(), diag::err_alignment_not_power_of_two) << SecondArg->getSourceRange();"},{n,1711,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n // ...\n if (!E->isValueDependent()) {\n // ...\n if (!I->isPowerOf2()) {\n Diag(AttrLoc, diag::err_alignment_not_power_of_two) << E->getSourceRange();"},{n,4336,"void Sema::AddAlignValueAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E) {\n // ...\n if (!E->isValueDependent()) {\n // ...\n if (!Alignment.isPowerOf2()) {\n Diag(AttrLoc, diag::err_alignment_not_power_of_two) << E->getSourceRange();"},{n,4494,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\n // ...\n // C++11 [dcl.align]p2:\n // -- if the constant expression evaluates to zero, the alignment\n // specifier shall have no effect\n // C11 6.7.5p6:\n // An alignment specification of zero has no effect.\n if (!(TmpAttr.isAlignas() && !Alignment)) {\n if (!llvm::isPowerOf2_64(AlignVal)) {\n Diag(AttrLoc, diag::err_alignment_not_power_of_two) << E->getSourceRange();"}}, [l]={ ["clang/test/Sema/align_value.c"]={"clang/test/Sema/align_value.c:8:33: error: requested alignment is not a power of 2","clang/test/Sema/align_value.c:11:33: error: requested alignment is not a power of 2"} } }, ["err_alignment_too_big"]={ [c]="err_alignment_too_big", [d]="requested alignment must be %0 or smaller", [e]="requested alignment must be A or smaller", [f]=k, [g]="requested alignment must be (.*?) or smaller", [h]=a, [i]=m, [b]={"5116993f8ea7",1477892268,"Add support for __builtin_alloca_with_align","Add support for __builtin_alloca_with_align\n\n__builtin_alloca always uses __BIGGEST_ALIGNMENT__ for the alignment of\nthe allocation. __builtin_alloca_with_align allows the programmer to\nspecify the alignment of the allocation.\n\nThis fixes PR30658.\n\nllvm-svn: 285544"}, [j]={{t,334,"/// Check that the value argument for __builtin_is_aligned(value, alignment) and\n/// __builtin_aligned_{up,down}(value, alignment) is an integer or a pointer\n/// type (but not a function pointer) and that the alignment is a power-of-two.\nstatic bool SemaBuiltinAlignment(Sema &S, CallExpr *TheCall, unsigned ID) {\n // ...\n // We can\'t check validity of alignment if it is value dependent.\n if (!AlignOp->isValueDependent() && AlignOp->EvaluateAsInt(AlignResult, S.Context, Expr::SE_AllowSideEffects)) {\n // ...\n if (llvm::APSInt::compareValues(AlignValue, MaxValue) > 0) {\n S.Diag(AlignOp->getExprLoc(), diag::err_alignment_too_big) << toString(MaxValue, 10);"},{t,8639,"/// Handle __builtin_alloca_with_align. This is declared\n/// as (size_t, size_t) where the second size_t must be a power of 2 greater\n/// than 8.\nbool Sema::SemaBuiltinAllocaWithAlign(CallExpr *TheCall) {\n // ...\n // We can\'t check the value of a dependent argument.\n if (!Arg->isTypeDependent() && !Arg->isValueDependent()) {\n // ...\n if (Result > std::numeric_limits<int32_t>::max())\n return Diag(TheCall->getBeginLoc(), diag::err_alignment_too_big) << std::numeric_limits<int32_t>::max() << Arg->getSourceRange();"}}, [l]={ ["clang/test/Sema/builtin-align.c"]={"clang/test/Sema/builtin-align.c:93:26: error: requested alignment must be 128 or smaller","clang/test/Sema/builtin-align.c:99:33: error: requested alignment must be 2147483648 or smaller","clang/test/Sema/builtin-align.c:100:33: error: requested alignment must be 2147483648 or smaller","clang/test/Sema/builtin-align.c:101:42: error: requested alignment must be 9223372036854775808 or smaller","clang/test/Sema/builtin-align.c:102:46: error: requested alignment must be 9223372036854775808 or smaller"} } }, ["err_alignment_too_small"]={ [c]="err_alignment_too_small", [d]="requested alignment must be %0 or greater", [e]="requested alignment must be A or greater", [f]=k, [g]="requested alignment must be (.*?) or greater", [h]=a, [i]=m, [b]={"5116993f8ea7",1477892268,"Add support for __builtin_alloca_with_align","Add support for __builtin_alloca_with_align\n\n__builtin_alloca always uses __BIGGEST_ALIGNMENT__ for the alignment of\nthe allocation. __builtin_alloca_with_align allows the programmer to\nspecify the alignment of the allocation.\n\nThis fixes PR30658.\n\nllvm-svn: 285544"}, [j]={{t,330,"/// Check that the value argument for __builtin_is_aligned(value, alignment) and\n/// __builtin_aligned_{up,down}(value, alignment) is an integer or a pointer\n/// type (but not a function pointer) and that the alignment is a power-of-two.\nstatic bool SemaBuiltinAlignment(Sema &S, CallExpr *TheCall, unsigned ID) {\n // ...\n // We can\'t check validity of alignment if it is value dependent.\n if (!AlignOp->isValueDependent() && AlignOp->EvaluateAsInt(AlignResult, S.Context, Expr::SE_AllowSideEffects)) {\n // ...\n if (AlignValue < 1) {\n S.Diag(AlignOp->getExprLoc(), diag::err_alignment_too_small) << 1;"},{t,8635,"/// Handle __builtin_alloca_with_align. This is declared\n/// as (size_t, size_t) where the second size_t must be a power of 2 greater\n/// than 8.\nbool Sema::SemaBuiltinAllocaWithAlign(CallExpr *TheCall) {\n // ...\n // We can\'t check the value of a dependent argument.\n if (!Arg->isTypeDependent() && !Arg->isValueDependent()) {\n // ...\n if (Result < Context.getCharWidth())\n return Diag(TheCall->getBeginLoc(), diag::err_alignment_too_small) << (unsigned)Context.getCharWidth() << Arg->getSourceRange();"}}, [l]={ ["clang/test/SemaCXX/builtin-align-cxx.cpp"]={"clang/test/SemaCXX/builtin-align-cxx.cpp:47:64: error: requested alignment must be 1 or greater"} } }, ["err_alignof_member_of_incomplete_type"]={ [c]="err_alignof_member_of_incomplete_type", [d]="invalid application of \'alignof\' to a field of a class still being defined", [e]="invalid application of \'alignof\' to a field of a class still being defined", [f]=k, [g]="invalid application of \'alignof\' to a field of a class still being defined", [h]=a, [i]=m, [b]={"768439eb2e7e",1367826034,"Require the containing type to be complete when we see","Require the containing type to be complete when we see\n__alignof__ of a field.\n\nThis problem can only happen in C++11.\n\nAlso do some petty optimizations.\n\nrdar://13784901\n\nllvm-svn: 181185"}, [j]={{Y,4687,"static bool CheckAlignOfExpr(Sema &S, Expr *E, UnaryExprOrTypeTrait ExprKind) {\n // ...\n // If it\'s a field, require the containing struct to have a\n // complete definition so that we can compute the layout.\n //\n // This can happen in C++11 onwards, either by naming the member\n // in a way that is not transformed into a member access expression\n // (in an unevaluated operand, for instance), or by naming the member\n // in a trailing-return-type.\n //\n // For the record, since __alignof__ on expressions is a GCC\n // extension, GCC seems to permit this but always gives the\n // nonsensical answer 0.\n //\n // We don\'t really need the layout here --- we could instead just\n // directly check for all the appropriate alignment-lowing\n // attributes --- but that would require duplicating a lot of\n // logic that just isn\'t worth duplicating for such a marginal\n // use-case.\n if (FieldDecl *FD = dyn_cast_or_null<FieldDecl>(D)) {\n // Fast path this check, since we at least know the record has a\n // definition if we can find a member of it.\n if (!FD->getParent()->isCompleteDefinition()) {\n S.Diag(E->getExprLoc(), diag::err_alignof_member_of_incomplete_type) << E->getSourceRange();"}}, [l]={ ["clang/test/SemaCXX/alignof.cpp"]={"clang/test/SemaCXX/alignof.cpp:7:39: error: invalid application of \'alignof\' to a field of a class still being defined","clang/test/SemaCXX/alignof.cpp:8:39: error: invalid application of \'alignof\' to a field of a class still being defined","clang/test/SemaCXX/alignof.cpp:9:38: error: invalid application of \'alignof\' to a field of a class still being defined"} } }, ["err_allocation_of_abstract_type"]={ [c]="err_allocation_of_abstract_type", [d]="allocating an object of abstract class type %0", [e]="allocating an object of abstract class type A", [f]=k, [g]="allocating an object of abstract class type (.*?)", [h]=a, [i]=m, [b]={"0d5ca29b7836",1237830550,"It\'s an error to try to allocate an abstract object using new.","It\'s an error to try to allocate an abstract object using new.\n\nllvm-svn: 67542"}, [j]={{"clang/lib/Sema/SemaCast.cpp",1885,"/// TryStaticImplicitCast - Tests whether a conversion according to C++ 5.2.9p2\n/// is valid:\n///\n/// An expression e can be explicitly converted to a type T using a\n/// @c static_cast if the declaration \"T t(e);\" is well-formed [...].\nTryCastResult TryStaticImplicitCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, Sema::CheckedConversionKind CCK, SourceRange OpRange, unsigned &msg, CastKind &Kind, bool ListInitialization) {\n if (DestType->isRecordType()) {\n if (Self.RequireCompleteType(OpRange.getBegin(), DestType, diag::err_bad_cast_incomplete) || Self.RequireNonAbstractType(OpRange.getBegin(), DestType, diag::err_allocation_of_abstract_type)) {"},{D,2468,"/// Checks that a type is suitable as the allocated type\n/// in a new-expression.\nbool Sema::CheckAllocatedType(QualType AllocType, SourceLocation Loc, SourceRange R) {\n // ...\n else if (RequireNonAbstractType(Loc, AllocType, diag::err_allocation_of_abstract_type))"},{D,4120,"static ExprResult BuildCXXCastArgument(Sema &S, SourceLocation CastLoc, QualType Ty, CastKind Kind, CXXMethodDecl *Method, DeclAccessPair FoundDecl, bool HadMultipleCandidates, Expr *From) {\n // ...\n case CK_ConstructorConversion: {\n // ...\n if (S.RequireNonAbstractType(CastLoc, Ty, diag::err_allocation_of_abstract_type))"},{L,8719,"ExprResult InitializationSequence::Perform(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, MultiExprArg Args, QualType *ResultType) {\n // ...\n // C++ [class.abstract]p2:\n // no objects of an abstract class can be created except as subobjects\n // of a class derived from it\n auto checkAbstractType = [&](QualType T) -> bool {\n // ...\n return S.RequireNonAbstractType(Kind.getLocation(), T, diag::err_allocation_of_abstract_type);"}}, [l]={ ["clang/test/CXX/class.derived/class.abstract/p2.cpp"]={"clang/test/CXX/class.derived/class.abstract/p2.cpp:16:5: error: allocating an object of abstract class type \'A\'","clang/test/CXX/class.derived/class.abstract/p2.cpp:17:5: error: allocating an object of abstract class type \'A\'","clang/test/CXX/class.derived/class.abstract/p2.cpp:18:5: error: allocating an object of abstract class type \'A\'"} } }, ["err_altivec_empty_initializer"]={ [c]="err_altivec_empty_initializer", [d]="expected initializer", [e]="expected initializer", [f]=k, [g]="expected initializer", [h]=a, [i]=m, [b]={"a96114ed087b",1249840544,"AltiVec-style vector initializer syntax, vec4 a = (vec4)(a, b, c, d);","AltiVec-style vector initializer syntax, vec4 a = (vec4)(a, b, c, d);\n\nIn addition to being defined by the AltiVec PIM, this is also the vector\ninitializer syntax used by OpenCL, so that vector literals are compatible\nwith macro arguments.\n\nllvm-svn: 78535"}, [j]={{Y,8445,"ExprResult Sema::ActOnCastExpr(Scope *S, SourceLocation LParenLoc, Declarator &D, ParsedType &Ty, SourceLocation RParenLoc, Expr *CastExpr) {\n // ...\n if ((getLangOpts().AltiVec || getLangOpts().ZVector || getLangOpts().OpenCL) && castType->isVectorType() && (PE || PLE)) {\n if (PLE && PLE->getNumExprs() == 0) {\n Diag(PLE->getExprLoc(), diag::err_altivec_empty_initializer);"}} }, ["err_ambiguous_base_to_derived_cast"]={ [c]="err_ambiguous_base_to_derived_cast", [d]="ambiguous cast from base %0 to derived %1:%2", [e]="ambiguous cast from base A to derived B:C", [f]=k, [g]="ambiguous cast from base (.*?) to derived (.*?)\\:(.*?)", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{"clang/lib/Sema/SemaCast.cpp",1714,"/// TryStaticDowncast - Common functionality of TryStaticReferenceDowncast and\n/// TryStaticPointerDowncast. Tests whether a static downcast from SrcType to\n/// DestType is possible and allowed.\nTryCastResult TryStaticDowncast(Sema &Self, CanQualType SrcType, CanQualType DestType, bool CStyle, SourceRange OpRange, QualType OrigSrcType, QualType OrigDestType, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath) {\n // ...\n if (Paths.isAmbiguous(SrcType.getUnqualifiedType())) {\n // ...\n Self.Diag(OpRange.getBegin(), diag::err_ambiguous_base_to_derived_cast) << QualType(SrcType).getUnqualifiedType() << QualType(DestType).getUnqualifiedType() << PathDisplayStr << OpRange;"}}, [l]={ ["clang/test/SemaCXX/cstyle-cast.cpp"]={"clang/test/SemaCXX/cstyle-cast.cpp:130:9: error: ambiguous cast from base \'A\' to derived \'H\':","clang/test/SemaCXX/cstyle-cast.cpp:131:9: error: ambiguous cast from base \'A\' to derived \'H\':"} } }, ["err_ambiguous_delete_operand"]={ [c]="err_ambiguous_delete_operand", [d]="ambiguous conversion of delete expression of type %0 to a pointer", [e]="ambiguous conversion of delete expression of type A to a pointer", [f]=k, [g]="ambiguous conversion of delete expression of type (.*?) to a pointer", [h]=a, [i]=m, [b]={"c34c179f4bcd",1253035307,"Perform overload resolution when selecting a pointer conversion","Perform overload resolution when selecting a pointer conversion\nfunction for delete of a class expression and issue\ngood diagnostic when result is ambiguous.\n\nllvm-svn: 81870"}, [j]={{D,3646,"/// ActOnCXXDelete - Parsed a C++ \'delete\' expression (C++ 5.3.5), as in:\n/// @code ::delete ptr; @endcode\n/// or\n/// @code delete [] ptr; @endcode\nExprResult Sema::ActOnCXXDelete(SourceLocation StartLoc, bool UseGlobal, bool ArrayForm, Expr *ExE) {\n // ...\n if (!Ex.get()->isTypeDependent()) {\n // ...\n class DeleteConverter : public ContextualImplicitConverter {\n // ...\n SemaDiagnosticBuilder diagnoseAmbiguous(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_ambiguous_delete_operand) << T; }"}}, [l]={ ["clang/test/SemaCXX/conversion-delete-expr.cpp"]={"clang/test/SemaCXX/conversion-delete-expr.cpp:14:4: error: ambiguous conversion of delete expression of type \'D\' to a pointer","clang/test/SemaCXX/conversion-delete-expr.cpp:42:4: error: ambiguous conversion of delete expression of type \'D2\' to a pointer","clang/test/SemaCXX/conversion-delete-expr.cpp:59:4: error: ambiguous conversion of delete expression of type \'D3\' to a pointer"} } }, ["err_ambiguous_derived_to_base_conv"]={ [c]="err_ambiguous_derived_to_base_conv", [d]="ambiguous conversion from derived class %0 to base class %1:%2", [e]="ambiguous conversion from derived class A to base class B:C", [f]=k, [g]="ambiguous conversion from derived class (.*?) to base class (.*?)\\:(.*?)", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{M,3167,"bool Sema::CheckDerivedToBaseConversion(QualType Derived, QualType Base, SourceLocation Loc, SourceRange Range, CXXCastPath *BasePath, bool IgnoreAccess) { return CheckDerivedToBaseConversion(Derived, Base, diag::err_upcast_to_inaccessible_base, diag::err_ambiguous_derived_to_base_conv, Loc, Range, DeclarationName(), BasePath, IgnoreAccess); }"},{Z,3147,"/// CheckPointerConversion - Check the pointer conversion from the\n/// expression From to the type ToType. This routine checks for\n/// ambiguous or inaccessible derived-to-base pointer\n/// conversions for which IsPointerConversion has already returned\n/// true. It returns true and produces a diagnostic if there was an\n/// error, or returns false otherwise.\nbool Sema::CheckPointerConversion(Expr *From, QualType ToType, CastKind &Kind, CXXCastPath &BasePath, bool IgnoreBaseAccess, bool Diagnose) {\n // ...\n if (const PointerType *ToPtrType = ToType->getAs<PointerType>()) {\n if (const PointerType *FromPtrType = FromType->getAs<PointerType>()) {\n // ...\n if (FromPointeeType->isRecordType() && ToPointeeType->isRecordType() && !Context.hasSameUnqualifiedType(FromPointeeType, ToPointeeType)) {\n // ...\n if (Diagnose) {\n // ...\n AmbiguousID = diag::err_ambiguous_derived_to_base_conv;"}}, [l]={ ["clang/test/SemaCXX/dynamic-cast.cpp"]={"clang/test/SemaCXX/dynamic-cast.cpp:62:9: error: ambiguous conversion from derived class \'F\' to base class \'A\':","clang/test/SemaCXX/dynamic-cast.cpp:63:9: error: ambiguous conversion from derived class \'F\' to base class \'A\':"} } }, ["err_ambiguous_destructor"]={ [c]={{nil,E,"err_ambiguous_destructor"}}, [d]={{nil,E,"destructor of class %0 is ambiguous"}}, [e]={{nil,E,"destructor of class A is ambiguous"}}, [f]=k, [g]="destructor of class (.*?) is ambiguous", [h]=a, [i]={{nil,E,m}}, [b]={eb,1625925174,gb,hb}, [j]={{o,18540,"/// [class.dtor]p4:\n/// At the end of the definition of a class, overload resolution is\n/// performed among the prospective destructors declared in that class with\n/// an empty argument list to select the destructor for the class, also\n/// known as the selected destructor.\n///\n/// We do the overload resolution here, then mark the selected constructor in the AST.\n/// Later CXXRecordDecl::getDestructor() will return the selected constructor.\nstatic void ComputeSelectedDestructor(Sema &S, CXXRecordDecl *Record) {\n // ...\n case OR_Ambiguous:\n Msg = diag::err_ambiguous_destructor;"}}, [l]={ ["clang/test/CXX/class/class.dtor/p4.cpp"]={"clang/test/CXX/class/class.dtor/p4.cpp:62:17: error: destructor of class \'D<1>\' is ambiguous"} } }, ["err_ambiguous_inherited_constructor"]={ [c]="err_ambiguous_inherited_constructor", [d]="constructor of %0 inherited from multiple base class subobjects", [e]="constructor of A inherited from multiple base class subobjects", [f]=k, [g]="constructor of (.*?) inherited from multiple base class subobjects", [h]=a, [i]=m, [b]={"5179eb78210a",1467140637,"P0136R1, DR1573, DR1645, DR1715, DR1736, DR1903, DR1941, DR1959, DR1991:","P0136R1, DR1573, DR1645, DR1715, DR1736, DR1903, DR1941, DR1959, DR1991:\n\nReplace inheriting constructors implementation with new approach, voted into\nC++ last year as a DR against C++11.\n\nInstead of synthesizing a set of derived class constructors for each inherited\nbase class constructor, we make the constructors of the base class visible to\nconstructor lookup in the derived class, using the normal rules for\nusing-declarations.\n\nFor constructors, UsingShadowDecl now has a ConstructorUsingShadowDecl derived\nclass that tracks the requisite additional information. We create shadow\nconstructors (not found by name lookup) in the derived class to model the\nactual initialization, and have a new expression node,\nCXXInheritedCtorInitExpr, to model the initialization of a base class from such\na constructor. (This initialization is special because it performs real perfect\nforwarding of arguments.)\n\nIn cases where argument forwarding is not possible (for inalloca calls,\nvariadic calls, and calls with callee parameter cleanup), the shadow inheriting\nconstructor is not emitted and instead we directly emit the initialization code\ninto the caller of the inherited constructor.\n\nNote that this new model is not perfectly compatible with the old model in some\ncorner cases. In particular:\n * if B inherits a private constructor from A, and C uses that constructor to\n construct a B, then we previously required that A befriends B and B\n befriends C, but the new rules require A to befriend C directly, and\n * if a derived class has its own constructors (and so its implicit default\n constructor is suppressed), it may still inherit a default constructor from\n a base class\n\nllvm-svn: 274049"}, [j]={{M,7302,"class Sema::InheritedConstructorInfo {\n // ...\n InheritedConstructorInfo(Sema &S, SourceLocation UseLoc, ConstructorUsingShadowDecl *Shadow) : S(S), UseLoc(UseLoc) {\n // ...\n // Find the set of such base class subobjects and check that there\'s a\n // unique constructed subobject.\n for (auto *D : Shadow->redecls()) {\n // ...\n // [class.inhctor.init]p2:\n // If the constructor was inherited from multiple base class subobjects\n // of type B, the program is ill-formed.\n if (!ConstructedBase) {\n // ...\n } else if (ConstructedBase != DConstructedBase && !Shadow->isInvalidDecl()) {\n if (!DiagnosedMultipleConstructedBases) {\n S.Diag(UseLoc, diag::err_ambiguous_inherited_constructor) << Shadow->getTargetDecl();"}}, [l]={ ["clang/test/CXX/special/class.init/class.inhctor.init/p2.cpp"]={"clang/test/CXX/special/class.init/class.inhctor.init/p2.cpp:23:6: error: constructor of \'A\' inherited from multiple base class subobjects"} } }, ["err_ambiguous_member_multiple_subobject_types"]={ [c]="err_ambiguous_member_multiple_subobject_types", [d]="member %0 found in multiple base classes of different types", [e]="member A found in multiple base classes of different types", [f]=k, [g]="member (.*?) found in multiple base classes of different types", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{"clang/lib/Sema/SemaLookup.cpp",2812,"/// Produce a diagnostic describing the ambiguity that resulted\n/// from name lookup.\n///\n/// \\param Result The result of the ambiguous lookup to be diagnosed.\nvoid Sema::DiagnoseAmbiguousLookup(LookupResult &Result) {\n // ...\n case LookupResult::AmbiguousBaseSubobjectTypes: {\n Diag(NameLoc, diag::err_ambiguous_member_multiple_subobject_types) << Name << LookupRange;"}}, [l]={ ["clang/test/SemaCXX/lookup-member.cpp"]={"clang/test/SemaCXX/lookup-member.cpp:38:19: error: member \'f\' found in multiple base classes of different types"} } }, ["err_ambiguous_member_multiple_subobjects"]={ [c]="err_ambiguous_member_multiple_subobjects", [d]="non-static member %0 found in multiple base-class subobjects of type %1:%2", [e]="non-static member A found in multiple base-class subobjects of type B:C", [f]=k, [g]="non\\-static member (.*?) found in multiple base\\-class subobjects of type (.*?)\\:(.*?)", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{"clang/lib/Sema/SemaLookup.cpp",2798,"/// Produce a diagnostic describing the ambiguity that resulted\n/// from name lookup.\n///\n/// \\param Result The result of the ambiguous lookup to be diagnosed.\nvoid Sema::DiagnoseAmbiguousLookup(LookupResult &Result) {\n // ...\n case LookupResult::AmbiguousBaseSubobjects: {\n // ...\n Diag(NameLoc, diag::err_ambiguous_member_multiple_subobjects) << Name << SubobjectType << getAmbiguousPathsDisplayString(*Paths) << LookupRange;"}}, [l]={ ["clang/test/SemaCXX/member-name-lookup.cpp"]={"clang/test/SemaCXX/member-name-lookup.cpp:38:5: error: non-static member \'a\' found in multiple base-class subobjects of type \'A\':","clang/test/SemaCXX/member-name-lookup.cpp:42:5: error: non-static member \'f\' found in multiple base-class subobjects of type \'A\':","clang/test/SemaCXX/member-name-lookup.cpp:54:3: error: non-static member \'a\' found in multiple base-class subobjects of type \'A\':","clang/test/SemaCXX/member-name-lookup.cpp:58:3: error: non-static member \'f\' found in multiple base-class subobjects of type \'A\':","clang/test/SemaCXX/member-name-lookup.cpp:108:5: error: non-static member \'a\' found in multiple base-class subobjects of type \'A\':","clang/test/SemaCXX/member-name-lookup.cpp:129:3: error: non-static member \'a\' found in multiple base-class subobjects of type \'A\':"} } }, ["err_ambiguous_memptr_conv"]={ [c]="err_ambiguous_memptr_conv", [d]="ambiguous conversion from pointer to member of %select{base|derived}0 class %1 to pointer to member of %select{derived|base}0 class %2:%3", [e]={{nil,nil,{"ambiguous conversion from pointer to member of ",{"base","derived"}," class B to pointer to member of ",{"derived","base"}," class C:D"}}}, [f]=k, [g]="ambiguous conversion from pointer to member of (?:base|derived) class (.*?) to pointer to member of (?:derived|base) class (.*?)\\:(.*?)", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{"clang/lib/Sema/SemaCast.cpp",1816,"/// TryStaticMemberPointerUpcast - Tests whether a conversion according to\n/// C++ 5.2.9p9 is valid:\n///\n/// An rvalue of type \"pointer to member of D of type cv1 T\" can be\n/// converted to an rvalue of type \"pointer to member of B of type cv2 T\",\n/// where B is a base class of D [...].\n///\nTryCastResult TryStaticMemberPointerUpcast(Sema &Self, ExprResult &SrcExpr, QualType SrcType, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath) {\n // ...\n // B is a base of D. But is it an allowed base? If not, it\'s a hard error.\n if (Paths.isAmbiguous(Self.Context.getCanonicalType(DestClass))) {\n // ...\n Self.Diag(OpRange.getBegin(), diag::err_ambiguous_memptr_conv) << 1 << SrcClass << DestClass << PathDisplayStr << OpRange;"},{Z,3278,"/// CheckMemberPointerConversion - Check the member pointer conversion from the\n/// expression From to the type ToType. This routine checks for ambiguous or\n/// virtual or inaccessible base-to-derived member pointer conversions\n/// for which IsMemberPointerConversion has already returned true. It returns\n/// true and produces a diagnostic if there was an error, or returns false\n/// otherwise.\nbool Sema::CheckMemberPointerConversion(Expr *From, QualType ToType, CastKind &Kind, CXXCastPath &BasePath, bool IgnoreBaseAccess) {\n // ...\n if (Paths.isAmbiguous(Context.getCanonicalType(FromClass).getUnqualifiedType())) {\n // ...\n Diag(From->getExprLoc(), diag::err_ambiguous_memptr_conv) << 0 << FromClass << ToClass << PathDisplayStr << From->getSourceRange();"}}, [l]={ ["clang/test/CXX/conv/conv.mem/p4.cpp"]={"clang/test/CXX/conv/conv.mem/p4.cpp:33:25: error: ambiguous conversion from pointer to member of base class \'Base\' to pointer to member of derived class \'test2::Derived\':","clang/test/CXX/conv/conv.mem/p4.cpp:34:27: error: ambiguous conversion from pointer to member of base class \'Base\' to pointer to member of derived class \'test2::Derived\':","clang/test/CXX/conv/conv.mem/p4.cpp:52:25: error: ambiguous conversion from pointer to member of base class \'Base\' to pointer to member of derived class \'test4::Derived\':","clang/test/CXX/conv/conv.mem/p4.cpp:53:27: error: ambiguous conversion from pointer to member of base class \'Base\' to pointer to member of derived class \'test4::Derived\':"} } }, ["err_ambiguous_reference"]={ [c]="err_ambiguous_reference", [d]="reference to %0 is ambiguous", [e]="reference to A is ambiguous", [f]=k, [g]="reference to (.*?) is ambiguous", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{"clang/lib/Sema/SemaLookup.cpp",2863,"/// Produce a diagnostic describing the ambiguity that resulted\n/// from name lookup.\n///\n/// \\param Result The result of the ambiguous lookup to be diagnosed.\nvoid Sema::DiagnoseAmbiguousLookup(LookupResult &Result) {\n // ...\n case LookupResult::AmbiguousReference: {\n Diag(NameLoc, diag::err_ambiguous_reference) << Name << LookupRange;"}}, [l]={ ["clang/test/CXX/basic/basic.lookup/basic.lookup.qual/namespace.qual/p5.cpp"]={"clang/test/CXX/basic/basic.lookup/basic.lookup.qual/namespace.qual/p5.cpp:28:14: error: reference to \'x\' is ambiguous","clang/test/CXX/basic/basic.lookup/basic.lookup.qual/namespace.qual/p5.cpp:29:15: error: reference to \'x\' is ambiguous"} } }, ["err_ambiguous_suitable_delete_member_function_found"]={ [c]="err_ambiguous_suitable_delete_member_function_found", [d]="multiple suitable %0 functions in %1", [e]="multiple suitable A functions in B", [f]=k, [g]="multiple suitable (.*?) functions in (.*?)", [h]=a, [i]=m, [b]={"66a8759400a9",1280881886,"Look through using declarations when deciding whether to use an operator","Look through using declarations when deciding whether to use an operator\ndelete for a virtual destructor. Diagnose ambiguities.\n\nFixes PR7803.\n\nllvm-svn: 110173"}, [j]={{D,3300,"bool Sema::FindDeallocationFunction(SourceLocation StartLoc, CXXRecordDecl *RD, DeclarationName Name, FunctionDecl *&Operator, bool Diagnose, bool WantSize, bool WantAligned) {\n // ...\n // We found multiple suitable operators; complain about the ambiguity.\n // FIXME: The standard doesn\'t say to do this; it appears that the intent\n // is that this should never happen.\n if (!Matches.empty()) {\n if (Diagnose) {\n Diag(StartLoc, diag::err_ambiguous_suitable_delete_member_function_found) << Name << RD;"}}, [l]={ ["clang/test/CXX/special/class.dtor/p9.cpp"]={"clang/test/CXX/special/class.dtor/p9.cpp:65:6: error: multiple suitable \'operator delete\' functions in \'D\'"} } }, ["err_ambiguous_tag_hiding"]={ [c]="err_ambiguous_tag_hiding", [d]="a type named %0 is hidden by a declaration in a different namespace", [e]="a type named A is hidden by a declaration in a different namespace", [f]=k, [g]="a type named (.*?) is hidden by a declaration in a different namespace", [h]=a, [i]=m, [b]={"6538c930503a",1255153699,"Qualified lookup through using declarations. Diagnose a new type of ambiguity.","Qualified lookup through using declarations. Diagnose a new type of ambiguity.\nSplit the various ambiguous result enumerators into their own enum. Tests\nfor most of C++ [namespace.qual].\n\nllvm-svn: 83700"}, [j]={{"clang/lib/Sema/SemaLookup.cpp",2838,"/// Produce a diagnostic describing the ambiguity that resulted\n/// from name lookup.\n///\n/// \\param Result The result of the ambiguous lookup to be diagnosed.\nvoid Sema::DiagnoseAmbiguousLookup(LookupResult &Result) {\n // ...\n case LookupResult::AmbiguousTagHiding: {\n Diag(NameLoc, diag::err_ambiguous_tag_hiding) << Name << LookupRange;"}}, [l]={ ["clang/test/CXX/basic/basic.lookup/basic.lookup.qual/namespace.qual/p5.cpp"]={"clang/test/CXX/basic/basic.lookup/basic.lookup.qual/namespace.qual/p5.cpp:32:17: error: a type named \'y\' is hidden by a declaration in a different namespace"} } }, ["err_analyzer_checker_incompatible_analyzer_option"]={ [c]={{nil,q,"err_analyzer_checker_incompatible_analyzer_option"}}, [d]={{nil,q,"checker cannot be enabled with analyzer option \'%0\' == %1"}}, [e]={{nil,q,"checker cannot be enabled with analyzer option \'A\' == B"}}, [f]=k, [g]="checker cannot be enabled with analyzer option \'(.*?)\' \\=\\= (.*?)", [h]=a, [i]={{nil,q,W}}, [b]={Eb,1534346725,Mb,Ib}, [j]={{"clang/lib/StaticAnalyzer/Checkers/ContainerModeling.cpp",1064,"bool ento::shouldRegisterContainerModeling(const CheckerManager &mgr) {\n // ...\n if (!mgr.getAnalyzerOptions().ShouldAggressivelySimplifyBinaryOperation) {\n mgr.getASTContext().getDiagnostics().Report(diag::err_analyzer_checker_incompatible_analyzer_option) << \"aggressive-binary-operation-simplification\""}}, [l]={ ["clang/test/Analysis/iterator-modeling-no-aggressive-binary-operation-simplification-no-crash.cpp"]={"error: checker cannot be enabled with analyzer option \'aggressive-binary-operation-simplification\' == false","error: checker cannot be enabled with analyzer option \'aggressive-binary-operation-simplification\' == false"} } }, ["err_analyzer_checker_option_invalid_input"]={ [c]={{nil,K,"err_analyzer_checker_option_invalid_input"}}, [d]={{nil,K,"invalid input for checker option \'%0\', that expects %1"}}, [e]={{nil,K,"invalid input for checker option \'A\', that expects B"}}, [f]=k, [g]="invalid input for checker option \'(.*?)\', that expects (.*?)", [h]=a, [i]={{nil,K,W}}, [b]={Eb,1534346725,Mb,Ib}, [j]={{"clang/lib/StaticAnalyzer/Core/CheckerManager.cpp",66,"void CheckerManager::reportInvalidCheckerOptionValue(const CheckerBase *C, StringRef OptionName, StringRef ExpectedValueDesc) const { getDiagnostics().Report(diag::err_analyzer_checker_option_invalid_input) << (llvm::Twine() + C->getTagDescription() + \":\" + OptionName).str() << ExpectedValueDesc; }"},{"clang/lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp",366,"/// Insert the checker/package option to AnalyzerOptions\' config table, and\n/// validate it, if the user supplied it on the command line.\nstatic void insertAndValidate(StringRef FullName, const CmdLineOption &Option, AnalyzerOptions &AnOpts, DiagnosticsEngine &Diags) {\n // ...\n if (Option.OptionType == \"bool\") {\n if (SuppliedValue != \"true\" && SuppliedValue != \"false\") {\n if (AnOpts.ShouldEmitErrorsOnInvalidConfigValue) {\n Diags.Report(diag::err_analyzer_checker_option_invalid_input) << FullOption << \"a boolean value\";"},{"clang/lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp",380,"/// Insert the checker/package option to AnalyzerOptions\' config table, and\n/// validate it, if the user supplied it on the command line.\nstatic void insertAndValidate(StringRef FullName, const CmdLineOption &Option, AnalyzerOptions &AnOpts, DiagnosticsEngine &Diags) {\n // ...\n if (Option.OptionType == \"int\") {\n // ...\n if (HasFailed) {\n if (AnOpts.ShouldEmitErrorsOnInvalidConfigValue) {\n Diags.Report(diag::err_analyzer_checker_option_invalid_input) << FullOption << \"an integer value\";"}} }, ["err_analyzer_checker_option_unknown"]={ [c]={{nil,K,"err_analyzer_checker_option_unknown"}}, [d]={{nil,K,"checker \'%0\' has no option called \'%1\'"}}, [e]={{nil,K,"checker \'A\' has no option called \'B\'"}}, [f]=k, [g]="checker \'(.*?)\' has no option called \'(.*?)\'", [h]=a, [i]={{nil,K,W}}, [b]={Eb,1534346725,Mb,Ib}, [j]={{"clang/lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp",484,"static void isOptionContainedIn(const CmdLineOptionList &OptionList, StringRef SuppliedChecker, StringRef SuppliedOption, const AnalyzerOptions &AnOpts, DiagnosticsEngine &Diags) {\n // ...\n if (llvm::none_of(OptionList, SameOptName)) {\n Diags.Report(diag::err_analyzer_checker_option_unknown) << SuppliedChecker << SuppliedOption;"}} }, ["err_analyzer_config_invalid_input"]={ [c]={{nil,B,"err_analyzer_config_invalid_input"}}, [d]={{nil,B,"invalid input for analyzer-config option \'%0\', that expects %1 value"}}, [e]={{nil,B,"invalid input for analyzer-config option \'A\', that expects B value"}}, [f]=k, [g]="invalid input for analyzer\\-config option \'(.*?)\', that expects (.*?) value", [h]=a, [i]={{nil,B,W}}, [b]={Eb,1534346725,Mb,Ib}, [j]={{bb,1106,"static void initOption(AnalyzerOptions::ConfigTable &Config, DiagnosticsEngine *Diags, bool &OptionField, StringRef Name, bool DefaultVal) {\n // ...\n if (!PossiblyInvalidVal) {\n if (Diags)\n Diags->Report(diag::err_analyzer_config_invalid_input) << Name << \"a boolean\";"},{bb,1123,"static void initOption(AnalyzerOptions::ConfigTable &Config, DiagnosticsEngine *Diags, unsigned &OptionField, StringRef Name, unsigned DefaultVal) {\n // ...\n if (Diags && HasFailed)\n Diags->Report(diag::err_analyzer_config_invalid_input) << Name << \"an unsigned\";"},{bb,1181,"#include \"clang/StaticAnalyzer/Core/AnalyzerOptions.def\"\n // ...\n if (AnOpts.ShouldTrackConditionsDebug && !AnOpts.ShouldTrackConditions)\n Diags->Report(diag::err_analyzer_config_invalid_input) << \"track-conditions-debug\""},{bb,1185,"#include \"clang/StaticAnalyzer/Core/AnalyzerOptions.def\"\n // ...\n if (!AnOpts.CTUDir.empty() && !llvm::sys::fs::is_directory(AnOpts.CTUDir))\n Diags->Report(diag::err_analyzer_config_invalid_input) << \"ctu-dir\""},{bb,1190,"#include \"clang/StaticAnalyzer/Core/AnalyzerOptions.def\"\n // ...\n if (!AnOpts.ModelPath.empty() && !llvm::sys::fs::is_directory(AnOpts.ModelPath))\n Diags->Report(diag::err_analyzer_config_invalid_input) << \"model-path\""}} }, ["err_analyzer_config_multiple_values"]={ [c]="err_analyzer_config_multiple_values", [d]="analyzer-config option \'%0\' should contain only one \'=\'", [e]="analyzer-config option \'A\' should contain only one \'=\'", [f]=k, [g]="analyzer\\-config option \'(.*?)\' should contain only one \'\\=\'", [h]=a, [i]=W, [b]={"fb5351eed39a",1346219700,"Add new -cc1 driver option -analyzer-config, which allows one to specify","Add new -cc1 driver option -analyzer-config, which allows one to specify\na comma separated collection of key:value pairs (which are strings). This\nallows a general way to provide analyzer configuration data from the command line.\n\nNo clients yet.\n\nllvm-svn: 162827"}, [j]={{bb,1045,"#include \"clang/StaticAnalyzer/Core/Analyses.def\"\n // ...\n // Go through the analyzer configuration options.\n for (const auto *A : Args.filtered(OPT_analyzer_config)) {\n // ...\n for (const auto &configVal : configVals) {\n // ...\n if (val.contains(\'=\')) {\n Diags.Report(SourceLocation(), diag::err_analyzer_config_multiple_values) << configVal;"}} }, ["err_analyzer_config_no_value"]={ [c]="err_analyzer_config_no_value", [d]="analyzer-config option \'%0\' has a key but no value", [e]="analyzer-config option \'A\' has a key but no value", [f]=k, [g]="analyzer\\-config option \'(.*?)\' has a key but no value", [h]=a, [i]=W, [b]={"fb5351eed39a",1346219700,"Add new -cc1 driver option -analyzer-config, which allows one to specify","Add new -cc1 driver option -analyzer-config, which allows one to specify\na comma separated collection of key:value pairs (which are strings). This\nallows a general way to provide analyzer configuration data from the command line.\n\nNo clients yet.\n\nllvm-svn: 162827"}, [j]={{bb,1040,"#include \"clang/StaticAnalyzer/Core/Analyses.def\"\n // ...\n // Go through the analyzer configuration options.\n for (const auto *A : Args.filtered(OPT_analyzer_config)) {\n // ...\n for (const auto &configVal : configVals) {\n // ...\n if (val.empty()) {\n Diags.Report(SourceLocation(), diag::err_analyzer_config_no_value) << configVal;"}} }, ["err_analyzer_config_unknown"]={ [c]={{nil,B,"err_analyzer_config_unknown"}}, [d]={{nil,B,"unknown analyzer-config \'%0\'"}}, [e]={{nil,B,"unknown analyzer-config \'A\'"}}, [f]=k, [g]="unknown analyzer\\-config \'(.*?)\'", [h]=a, [i]={{nil,B,W}}, [b]={Eb,1534346725,Mb,Ib}, [j]={{bb,1054,"#include \"clang/StaticAnalyzer/Core/Analyses.def\"\n // ...\n // Go through the analyzer configuration options.\n for (const auto *A : Args.filtered(OPT_analyzer_config)) {\n // ...\n for (const auto &configVal : configVals) {\n // ...\n // TODO: Check checker options too, possibly in CheckerRegistry.\n // Leave unknown non-checker configs unclaimed.\n if (!key.contains(\":\") && Opts.isUnknownAnalyzerConfig(key)) {\n if (Opts.ShouldEmitErrorsOnInvalidConfigValue)\n Diags.Report(diag::err_analyzer_config_unknown) << key;"}} }, ["err_analyzer_not_built_with_z3"]={ [c]={{nil,E,"err_analyzer_not_built_with_z3"}}, [d]={{nil,E,"analyzer constraint manager \'z3\' is only available if LLVM was built with -DLLVM_ENABLE_Z3_SOLVER=ON"}}, [e]={{nil,E,"analyzer constraint manager \'z3\' is only available if LLVM was built with -DLLVM_ENABLE_Z3_SOLVER=ON"}}, [f]=k, [g]="analyzer constraint manager \'z3\' is only available if LLVM was built with \\-DLLVM_ENABLE_Z3_SOLVER\\=ON", [h]=a, [i]={{nil,E,W}}, [b]={"0687578728ea",1610286626,"[C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths.","[C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths.\n\nThis is support for the user-facing options to create importable header units\nfrom headers in the user or system search paths (or to be given an absolute path).\n\nThis means that an incomplete header path will be passed by the driver and the\nlookup carried out using the search paths present when the front end is run.\n\nTo support this, we introduce file fypes for c++-{user,system,header-unit}-header.\nThese terms are the same as the ones used by GCC, to minimise the differences for\ntooling (and users).\n\nThe preprocessor checks for headers before issuing a warning for\n\"#pragma once\" in a header build. We ensure that the importable header units\nare recognised as headers in order to avoid such warnings.\n\nDifferential Revision: https://reviews.llvm.org/D121096"}, [j]={{bb,960,"#ifndef LLVM_WITH_Z3\n if (Value == AnalysisConstraints::Z3ConstraintsModel) {\n Diags.Report(diag::err_analyzer_not_built_with_z3);"}} }, ["err_anon_bitfield_has_negative_width"]={ [c]="err_anon_bitfield_has_negative_width", [d]="anonymous bit-field has negative width (%0)", [e]="anonymous bit-field has negative width (A)", [f]=k, [g]="anonymous bit\\-field has negative width \\((.*?)\\)", [h]=a, [i]=m, [b]={"f9b00eb7dc88",1240248578,"clean up anonymous bitfield diagnostics, PR4017","clean up anonymous bitfield diagnostics, PR4017\n\nllvm-svn: 69608"}, [j]={{o,17926,"// Note that FieldName may be null for anonymous bitfields.\nExprResult Sema::VerifyBitField(SourceLocation FieldLoc, IdentifierInfo *FieldName, QualType FieldTy, bool IsMsStruct, Expr *BitWidth) {\n // ...\n if (Value.isSigned() && Value.isNegative()) {\n // ...\n return Diag(FieldLoc, diag::err_anon_bitfield_has_negative_width) << toString(Value, 10);"}}, [l]={ ["clang/test/Sema/bitfield.c"]={"clang/test/Sema/bitfield.c:26:3: error: anonymous bit-field has negative width (-2)"} } }, ["err_anon_bitfield_member_init"]={ [c]={{nil,r,"err_anon_bitfield_member_init"}}, [d]={{nil,r,"anonymous bit-field cannot have a default member initializer"}}, [e]={{nil,r,"anonymous bit-field cannot have a default member initializer"}}, [f]=k, [g]="anonymous bit\\-field cannot have a default member initializer", [h]=a, [i]={{nil,r,V}}, [b]={"2e204e23911b",1601401476,"[clang] Enable support for #pragma STDC FENV_ACCESS","[clang] Enable support for #pragma STDC FENV_ACCESS\n\nReviewers: rjmccall, rsmith, sepavloff\n\nDifferential Revision: https://reviews.llvm.org/D87528"}, [j]={{db,3021,"/// ParseCXXClassMemberDeclaration - Parse a C++ class member declaration.\n///\n/// member-declaration:\n/// decl-specifier-seq[opt] member-declarator-list[opt] \';\'\n/// function-definition \';\'[opt]\n/// ::[opt] nested-name-specifier template[opt] unqualified-id \';\'[TODO]\n/// using-declaration [TODO]\n/// [C++0x] static_assert-declaration\n/// template-declaration\n/// [GNU] \'__extension__\' member-declaration\n///\n/// member-declarator-list:\n/// member-declarator\n/// member-declarator-list \',\' member-declarator\n///\n/// member-declarator:\n/// declarator virt-specifier-seq[opt] pure-specifier[opt]\n/// [C++2a] declarator requires-clause\n/// declarator constant-initializer[opt]\n/// [C++11] declarator brace-or-equal-initializer[opt]\n/// identifier[opt] \':\' constant-expression\n///\n/// virt-specifier-seq:\n/// virt-specifier\n/// virt-specifier-seq virt-specifier\n///\n/// virt-specifier:\n/// override\n/// final\n/// [MS] sealed\n///\n/// pure-specifier:\n/// \'= 0\'\n///\n/// constant-initializer:\n/// \'=\' constant-expression\n///\nParser::DeclGroupPtrTy Parser::ParseCXXClassMemberDeclaration(AccessSpecifier AS, ParsedAttributes &AccessAttrs, const ParsedTemplateInfo &TemplateInfo, ParsingDeclRAIIObject *TemplateDiags) {\n // ...\n while (true) {\n // ...\n if (Tok.isOneOf(tok::equal, tok::l_brace) && PureSpecLoc.isInvalid()) {\n // DRXXXX: Anonymous bit-fields cannot have a brace-or-equal-initializer.\n if (BitfieldSize.isUsable() && !DeclaratorInfo.hasName()) {\n // ...\n Diag(Tok, diag::err_anon_bitfield_member_init);"}}, [l]={ ["clang/test/CXX/class/class.bit/p1.cpp"]={"clang/test/CXX/class/class.bit/p1.cpp:10:11: error: anonymous bit-field cannot have a default member initializer","clang/test/CXX/class/class.bit/p1.cpp:11:11: error: anonymous bit-field cannot have a default member initializer","clang/test/CXX/class/class.bit/p1.cpp:13:11: error: anonymous bit-field cannot have a default member initializer"} } }, ["err_anon_bitfield_qualifiers"]={ [c]={{nil,A,"err_anon_bitfield_qualifiers"}}, [d]={{nil,A,"anonymous bit-field cannot have qualifiers"}}, [e]={{nil,A,"anonymous bit-field cannot have qualifiers"}}, [f]=k, [g]="anonymous bit\\-field cannot have qualifiers", [h]=a, [i]={{nil,A,m}}, [b]={"33e90d160b1b",1521320920,"Implement DR2229, which prohibits unnamed bit-fields from having qualifiers in C++.","Implement DR2229, which prohibits unnamed bit-fields from having qualifiers in C++.\n\nllvm-svn: 327781"}, [j]={{o,18153,"/// Build a new FieldDecl and check its well-formedness.\n///\n/// This routine builds a new FieldDecl given the fields name, type,\n/// record, etc. \\p PrevDecl should refer to any previous declaration\n/// with the same name and in the same scope as the field to be\n/// created.\n///\n/// \\returns a new FieldDecl.\n///\n/// \\todo The Declarator argument is a hack. It will be removed once\nFieldDecl *Sema::CheckFieldDecl(DeclarationName Name, QualType T, TypeSourceInfo *TInfo, RecordDecl *Record, SourceLocation Loc, bool Mutable, Expr *BitWidth, InClassInitStyle InitStyle, SourceLocation TSSL, AccessSpecifier AS, NamedDecl *PrevDecl, Declarator *D) {\n // ...\n // Anonymous bit-fields cannot be cv-qualified (CWG 2229).\n if (!InvalidDecl && getLangOpts().CPlusPlus && !II && BitWidth && T.hasQualifiers()) {\n // ...\n Diag(Loc, diag::err_anon_bitfield_qualifiers);"}}, [l]={ ["clang/test/CXX/class/class.bit/p2.cpp"]={"clang/test/CXX/class/class.bit/p2.cpp:12:13: error: anonymous bit-field cannot have qualifiers"} } }, ["err_anon_type_definition"]={ [c]="err_anon_type_definition", [d]="declaration of anonymous %0 must be a definition", [e]="declaration of anonymous A must be a definition", [f]=k, [g]="declaration of anonymous (.*?) must be a definition", [h]=a, [i]=V, [b]={N,1236199783,O,P}, [j]={{db,1949,"#include \"clang/Basic/TransformTypeTraits.def\"\n // ...\n if (!Name && !TemplateId && (DS.getTypeSpecType() == DeclSpec::TST_error || TUK != Sema::TUK_Definition)) {\n if (DS.getTypeSpecType() != DeclSpec::TST_error) {\n // ...\n Diag(StartLoc, diag::err_anon_type_definition) << DeclSpec::getSpecifierName(TagType, Policy);"}}, [l]={ ["clang/test/Sema/decl-invalid.c"]={"clang/test/Sema/decl-invalid.c:4:9: error: declaration of anonymous union must be a definition","clang/test/Sema/decl-invalid.c:19:1: error: declaration of anonymous struct must be a definition"} } }, ["err_anonymous_enum_bitfield"]={ [c]={{nil,q,"err_anonymous_enum_bitfield"}}, [d]={{nil,q,"ISO C++ only allows \':\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit-field"}}, [e]={{nil,q,"ISO C++ only allows \':\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit-field"}}, [f]=k, [g]="ISO C\\+\\+ only allows \'\\:\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit\\-field", [h]=a, [i]={{nil,q,V}}, [b]={"c90e19810743",1588991058,"Fix parsing of enum-base to follow C++11 rules.","Fix parsing of enum-base to follow C++11 rules.\n\nPreviously we implemented non-standard disambiguation rules to\ndistinguish an enum-base from a bit-field but otherwise treated a :\nafter an elaborated-enum-specifier as introducing an enum-base. That\nmisparses various examples (anywhere an elaborated-type-specifier can\nappear followed by a colon, such as within a ternary operator or\n_Generic).\n\nWe now implement the C++11 rules, with the old cases accepted as\nextensions where that seemed reasonable. These amount to:\n * an enum-base must always be accompanied by an enum definition (except\n in a standalone declaration of the form \'enum E : T;\')\n * in a member-declaration, \'enum E :\' always introduces an enum-base,\n never a bit-field\n * in a type-specifier (or similar context), \'enum E :\' is not\n permitted; the colon means whatever else it would mean in that\n context.\n\nFixed underlying types for enums are also permitted in Objective-C and\nunder MS extensions, plus as a language extension in all other modes.\nThe behavior in ObjC and MS extensions modes is unchanged (but the\nbit-field disambiguation is a bit better); remaining language modes\nfollow the C++11 rules.\n\nFixes PR45726, PR39979, PR19810, PR44941, and most of PR24297, plus C++\ncore issues 1514 and 1966."}, [j]={{Bb,4919,"/// ParseEnumSpecifier\n/// enum-specifier: [C99 6.7.2.2]\n/// \'enum\' identifier[opt] \'{\' enumerator-list \'}\'\n///[C99/C++]\'enum\' identifier[opt] \'{\' enumerator-list \',\' \'}\'\n/// [GNU] \'enum\' attributes[opt] identifier[opt] \'{\' enumerator-list \',\' [opt]\n/// \'}\' attributes[opt]\n/// [MS] \'enum\' __declspec[opt] identifier[opt] \'{\' enumerator-list \',\' [opt]\n/// \'}\'\n/// \'enum\' identifier\n/// [GNU] \'enum\' attributes[opt] identifier\n///\n/// [C++11] enum-head \'{\' enumerator-list[opt] \'}\'\n/// [C++11] enum-head \'{\' enumerator-list \',\' \'}\'\n///\n/// enum-head: [C++11]\n/// enum-key attribute-specifier-seq[opt] identifier[opt] enum-base[opt]\n/// enum-key attribute-specifier-seq[opt] nested-name-specifier\n/// identifier enum-base[opt]\n///\n/// enum-key: [C++11]\n/// \'enum\'\n/// \'enum\' \'class\'\n/// \'enum\' \'struct\'\n///\n/// enum-base: [C++11]\n/// \':\' type-specifier-seq\n///\n/// [C++] elaborated-type-specifier:\n/// [C++] \'enum\' nested-name-specifier[opt] identifier\n///\nvoid Parser::ParseEnumSpecifier(SourceLocation StartLoc, DeclSpec &DS, const ParsedTemplateInfo &TemplateInfo, AccessSpecifier AS, DeclSpecContext DSC) {\n // ...\n // Parse the fixed underlying type.\n if (Tok.is(tok::colon)) {\n // ...\n if (CanBeBitfield && !isEnumBase(CanBeOpaqueEnumDeclaration)) {\n // Outside C++11, do not interpret the tokens as an enum-base if they do\n // not make sense as one. In C++11, it\'s an error if this happens.\n if (getLangOpts().CPlusPlus11)\n Diag(Tok.getLocation(), diag::err_anonymous_enum_bitfield);"}}, [l]={ ["clang/test/SemaCXX/enum-bitfield.cpp"]={"clang/test/SemaCXX/enum-bitfield.cpp:9:10: error: ISO C++ only allows \':\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit-field","clang/test/SemaCXX/enum-bitfield.cpp:16:10: error: ISO C++ only allows \':\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit-field","clang/test/SemaCXX/enum-bitfield.cpp:17:10: error: ISO C++ only allows \':\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit-field"} } }, ["err_anonymous_property"]={ [c]="err_anonymous_property", [d]="anonymous property is not supported", [e]="anonymous property is not supported", [f]=k, [g]="anonymous property is not supported", [h]=a, [i]=m, [b]={"5e77d76c953d",1366097310,"Basic support for Microsoft property declarations and","Basic support for Microsoft property declarations and\nreferences thereto.\n\nPatch by Tong Shen!\n\nllvm-svn: 179585"}, [j]={{M,18817,"/// HandleMSProperty - Analyze a __delcspec(property) field of a C++ class.\n///\nMSPropertyDecl *Sema::HandleMSProperty(Scope *S, RecordDecl *Record, SourceLocation DeclStart, Declarator &D, Expr *BitWidth, InClassInitStyle InitStyle, AccessSpecifier AS, const ParsedAttr &MSPropertyAttr) {\n // ...\n if (!II) {\n Diag(DeclStart, diag::err_anonymous_property);"}}, [l]={ ["clang/test/SemaCXX/MicrosoftExtensions.cpp"]={"clang/test/SemaCXX/MicrosoftExtensions.cpp:410:38: error: anonymous property is not supported"} } }, ["err_anonymous_record_bad_member"]={ [c]="err_anonymous_record_bad_member", [d]="anonymous %select{struct|union}0 can only contain non-static data members", [e]={{nil,nil,{"anonymous ",{zb,yb}," can only contain non-static data members"}}}, [f]=k, [g]="anonymous (?:struct|union) can only contain non\\-static data members", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{o,5645,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n // C++ [class.union]p2:\n // The member-specification of an anonymous union shall only\n // define non-static data members. [Note: nested types and\n // functions cannot be declared within an anonymous union. ]\n for (auto *Mem : Record->decls()) {\n // ...\n if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n // ...\n } else if (Mem->isImplicit()) {\n // ...\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n // ...\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n // ...\n } else if (isa<AccessSpecDecl>(Mem)) {\n // ...\n } else if (isa<StaticAssertDecl>(Mem)) {\n // ...\n } else {\n // ...\n unsigned DK = diag::err_anonymous_record_bad_member;"}} }, ["err_anonymous_record_member_redecl"]={ [c]="err_anonymous_record_member_redecl", [d]="member of anonymous %select{struct|union}0 redeclares %1", [e]={{nil,nil,{"member of anonymous ",{zb,yb}," redeclares B"}}}, [f]=k, [g]="member of anonymous (?:struct|union) redeclares (.*?)", [h]=a, [i]=m, [b]={"da7b27ff0b98",1447738809,"[Sema] Combine similar diagnostics using %select. NFC","[Sema] Combine similar diagnostics using %select. NFC\n\nllvm-svn: 253315"}, [j]={{o,5358,"/// We are trying to inject an anonymous member into the given scope;\n/// check if there\'s an existing declaration that can\'t be overloaded.\n///\n/// \\return true if this is a forbidden redeclaration\nstatic bool CheckAnonMemberRedeclaration(Sema &SemaRef, Scope *S, DeclContext *Owner, DeclarationName Name, SourceLocation NameLoc, bool IsUnion) {\n // ...\n SemaRef.Diag(NameLoc, diag::err_anonymous_record_member_redecl) << IsUnion << Name;"}}, [l]={ ["clang/test/Sema/anonymous-struct-union.c"]={"clang/test/Sema/anonymous-struct-union.c:44:9: error: member of anonymous union redeclares \'x\'","clang/test/Sema/anonymous-struct-union.c:88:9: error: member of anonymous union redeclares \'f0\'"} } }, ["err_anonymous_record_nonpublic_member"]={ [c]="err_anonymous_record_nonpublic_member", [d]="anonymous %select{struct|union}0 cannot contain a %select{private|protected}1 data member", [e]={{nil,nil,{"anonymous ",{zb,yb}," cannot contain a ",{Q,R}," data member"}}}, [f]=k, [g]="anonymous (?:struct|union) cannot contain a (?:private|protected) data member", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{o,5598,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n // C++ [class.union]p2:\n // The member-specification of an anonymous union shall only\n // define non-static data members. [Note: nested types and\n // functions cannot be declared within an anonymous union. ]\n for (auto *Mem : Record->decls()) {\n // ...\n if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n // ...\n if (FD->getAccess() != AS_public) {\n Diag(FD->getLocation(), diag::err_anonymous_record_nonpublic_member) << Record->isUnion() << (FD->getAccess() == AS_protected);"}}, [l]={ ["clang/test/SemaCXX/anonymous-union.cpp"]={"clang/test/SemaCXX/anonymous-union.cpp:116:16: error: anonymous union cannot contain a private data member","clang/test/SemaCXX/anonymous-union.cpp:117:20: error: anonymous union cannot contain a protected data member"} } }, ["err_anonymous_record_with_function"]={ [c]="err_anonymous_record_with_function", [d]="functions cannot be declared in an anonymous %select{struct|union}0", [e]={{nil,nil,{"functions cannot be declared in an anonymous ",{zb,yb}}}}, [f]=k, [g]="functions cannot be declared in an anonymous (?:struct|union)", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{o,5649,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n // C++ [class.union]p2:\n // The member-specification of an anonymous union shall only\n // define non-static data members. [Note: nested types and\n // functions cannot be declared within an anonymous union. ]\n for (auto *Mem : Record->decls()) {\n // ...\n if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n // ...\n } else if (Mem->isImplicit()) {\n // ...\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n // ...\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n // ...\n } else if (isa<AccessSpecDecl>(Mem)) {\n // ...\n } else if (isa<StaticAssertDecl>(Mem)) {\n // ...\n } else {\n // ...\n if (isa<TypeDecl>(Mem))\n // ...\n else if (isa<FunctionDecl>(Mem))\n DK = diag::err_anonymous_record_with_function;"}}, [l]={ ["clang/test/SemaCXX/anonymous-union.cpp"]={"clang/test/SemaCXX/anonymous-union.cpp:115:10: error: functions cannot be declared in an anonymous union"} } }, ["err_anonymous_record_with_static"]={ [c]="err_anonymous_record_with_static", [d]="static members cannot be declared in an anonymous %select{struct|union}0", [e]={{nil,nil,{"static members cannot be declared in an anonymous ",{zb,yb}}}}, [f]=k, [g]="static members cannot be declared in an anonymous (?:struct|union)", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{o,5651,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n // C++ [class.union]p2:\n // The member-specification of an anonymous union shall only\n // define non-static data members. [Note: nested types and\n // functions cannot be declared within an anonymous union. ]\n for (auto *Mem : Record->decls()) {\n // ...\n if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n // ...\n } else if (Mem->isImplicit()) {\n // ...\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n // ...\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n // ...\n } else if (isa<AccessSpecDecl>(Mem)) {\n // ...\n } else if (isa<StaticAssertDecl>(Mem)) {\n // ...\n } else {\n // ...\n if (isa<TypeDecl>(Mem))\n // ...\n else if (isa<FunctionDecl>(Mem))\n // ...\n else if (isa<VarDecl>(Mem))\n DK = diag::err_anonymous_record_with_static;"}} }, ["err_anonymous_record_with_type"]={ [c]="err_anonymous_record_with_type", [d]="types cannot be declared in an anonymous %select{struct|union}0", [e]={{nil,nil,{"types cannot be declared in an anonymous ",{zb,yb}}}}, [f]=k, [g]="types cannot be declared in an anonymous (?:struct|union)", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{o,5626,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n // C++ [class.union]p2:\n // The member-specification of an anonymous union shall only\n // define non-static data members. [Note: nested types and\n // functions cannot be declared within an anonymous union. ]\n for (auto *Mem : Record->decls()) {\n // ...\n if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n // ...\n } else if (Mem->isImplicit()) {\n // ...\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n // ...\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n if (!MemRecord->isAnonymousStructOrUnion() && MemRecord->getDeclName()) {\n // Visual C++ allows type definition in anonymous struct or union.\n if (getLangOpts().MicrosoftExt)\n // ...\n else {\n // ...\n Diag(MemRecord->getLocation(), diag::err_anonymous_record_with_type) << Record->isUnion();"},{o,5647,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n // C++ [class.union]p2:\n // The member-specification of an anonymous union shall only\n // define non-static data members. [Note: nested types and\n // functions cannot be declared within an anonymous union. ]\n for (auto *Mem : Record->decls()) {\n // ...\n if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n // ...\n } else if (Mem->isImplicit()) {\n // ...\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n // ...\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n // ...\n } else if (isa<AccessSpecDecl>(Mem)) {\n // ...\n } else if (isa<StaticAssertDecl>(Mem)) {\n // ...\n } else {\n // ...\n if (isa<TypeDecl>(Mem))\n DK = diag::err_anonymous_record_with_type;"},{o,5655,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n // C++ [class.union]p2:\n // The member-specification of an anonymous union shall only\n // define non-static data members. [Note: nested types and\n // functions cannot be declared within an anonymous union. ]\n for (auto *Mem : Record->decls()) {\n // ...\n if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n // ...\n } else if (Mem->isImplicit()) {\n // ...\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n // ...\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n // ...\n } else if (isa<AccessSpecDecl>(Mem)) {\n // ...\n } else if (isa<StaticAssertDecl>(Mem)) {\n // ...\n } else {\n // ...\n if (getLangOpts().MicrosoftExt && DK == diag::err_anonymous_record_with_type)"}}, [l]={ ["clang/test/SemaCXX/anonymous-union.cpp"]={"clang/test/SemaCXX/anonymous-union.cpp:112:12: error: types cannot be declared in an anonymous union"} } }, ["err_anonymous_struct_not_member"]={ [c]="err_anonymous_struct_not_member", [d]="anonymous %select{structs|structs and classes}0 must be %select{struct or union|class}0 members", [e]={{nil,nil,{"anonymous ",{"structs","structs and classes"}," must be ",{"struct or union","class"}," members"}}}, [f]=k, [g]="anonymous (?:structs|structs and classes) must be (?:struct or union|class) members", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{o,5675,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (!Record->isUnion() && !Owner->isRecord()) {\n Diag(Record->getLocation(), diag::err_anonymous_struct_not_member) << getLangOpts().CPlusPlus;"}}, [l]={ ["clang/test/CXX/module/module.interface/p3.cpp"]={"clang/test/CXX/module/module.interface/p3.cpp:19:8: error: anonymous structs and classes must be class members"} } }, ["err_anonymous_union_not_static"]={ [c]="err_anonymous_union_not_static", [d]="anonymous unions at namespace or global scope must be declared \'static\'", [e]="anonymous unions at namespace or global scope must be declared \'static\'", [f]=k, [g]="anonymous unions at namespace or global scope must be declared \'static\'", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{o,5530,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n if (Record->isUnion()) {\n // ...\n if (DS.getStorageClassSpec() != DeclSpec::SCS_static && (OwnerScope->isTranslationUnit() || (OwnerScope->isNamespace() && !cast<NamespaceDecl>(OwnerScope)->isAnonymousNamespace()))) {\n Diag(Record->getLocation(), diag::err_anonymous_union_not_static) << FixItHint::CreateInsertion(Record->getLocation(), \"static \");"}}, [l]={ ["clang/test/CXX/module/module.interface/p3.cpp"]={"clang/test/CXX/module/module.interface/p3.cpp:21:8: error: anonymous unions at namespace or global scope must be declared \'static\'"} } }, ["err_anonymous_union_with_storage_spec"]={ [c]="err_anonymous_union_with_storage_spec", [d]="anonymous union at class scope must not have a storage specifier", [e]="anonymous union at class scope must not have a storage specifier", [f]=k, [g]="anonymous union at class scope must not have a storage specifier", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{o,5543,"/// BuildAnonymousStructOrUnion - Handle the declaration of an\n/// anonymous structure or union. Anonymous unions are a C++ feature\n/// (C++ [class.union]) and a C11 feature; anonymous structures\n/// are a C11 feature and GNU C++ extension.\nDecl *Sema::BuildAnonymousStructOrUnion(Scope *S, DeclSpec &DS, AccessSpecifier AS, RecordDecl *Record, const PrintingPolicy &Policy) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n if (Record->isUnion()) {\n // ...\n }\n // C++ [class.union]p6:\n // A storage class is not allowed in a declaration of an\n // anonymous union in a class scope.\n else if (DS.getStorageClassSpec() != DeclSpec::SCS_unspecified && isa<RecordDecl>(Owner)) {\n Diag(DS.getStorageClassSpecLoc(), diag::err_anonymous_union_with_storage_spec) << FixItHint::CreateRemoval(DS.getStorageClassSpecLoc());"}}, [l]={ ["clang/test/SemaCXX/anonymous-union.cpp"]={"clang/test/SemaCXX/anonymous-union.cpp:27:3: error: anonymous union at class scope must not have a storage specifier"} } }, ["err_anyx86_interrupt_attribute"]={ [c]="err_anyx86_interrupt_attribute", [d]="%select{x86|x86-64}0 \'interrupt\' attribute only applies to functions that have %select{a \'void\' return type|only a pointer parameter optionally followed by an integer parameter|a pointer as the first parameter|a %2 type as the second parameter}1", [e]={{nil,nil,{{"x86","x86-64"}," \'interrupt\' attribute only applies to functions that have ",{"a \'void\' return type","only a pointer parameter optionally followed by an integer parameter","a pointer as the first parameter","a C type as the second parameter"}}}}, [f]=k, [g]="(?:x86|x86\\-64) \'interrupt\' attribute only applies to functions that have (?:a \'void\' return type|only a pointer parameter optionally followed by an integer parameter|a pointer as the first parameter|a (.*?) type as the second parameter)", [h]=a, [i]=m, [b]={"d51e9933b6aa",1452830791,"[X86] Support \'interrupt\' attribute for x86","[X86] Support \'interrupt\' attribute for x86\nThis attribute may be attached to a function definition and instructs the backend to generate appropriate function entry/exit code so that\nit can be used directly as an interrupt handler.\nThe IRET instruction, instead of the RET instruction, is used to return from interrupt or exception handlers. All registers, except for the EFLAGS register which is restored by the IRET instruction, are preserved by the compiler.\nAny interruptible-without-stack-switch code must be compiled with -mno-red-zone since interrupt handlers can and will, because of the hardware design, touch\nthe red zone.\n\ninterrupt handler must be declared with a mandatory pointer argument:\nstruct interrupt_frame;\n\n__attribute__ ((interrupt))\nvoid f (struct interrupt_frame *frame) {\n ...\n}\nand user must properly define the structure the pointer pointing to.\n\nexception handler: \n\nThe exception handler is very similar to the interrupt handler with a different mandatory function signature:\n#ifdef __x86_64__\ntypedef unsigned long long int uword_t;\n#else\ntypedef unsigned int uword_t;\n#endif\n\nstruct interrupt_frame;\n\n__attribute__ ((interrupt))\nvoid f (struct interrupt_frame *frame, uword_t error_code) {\n ...\n}\nand compiler pops the error code off stack before the IRET instruction.\n\nThe exception handler should only be used for exceptions which push an error code and all other exceptions must use the interrupt handler.\nThe system will crash if the wrong handler is used.\nDifferential Revision: http://reviews.llvm.org/D15709\n\nllvm-svn: 257867"}, [j]={{n,7536,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // Interrupt handler must have void return type.\n if (!getFunctionOrMethodResultType(D)->isVoidType()) {\n S.Diag(getFunctionOrMethodResultSourceRange(D).getBegin(), diag::err_anyx86_interrupt_attribute) << (S.Context.getTargetInfo().getTriple().getArch() == llvm::Triple::x86 ? 0 : 1) << 0;"},{n,7546,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (NumParams < 1 || NumParams > 2) {\n S.Diag(D->getBeginLoc(), diag::err_anyx86_interrupt_attribute) << (S.Context.getTargetInfo().getTriple().getArch() == llvm::Triple::x86 ? 0 : 1) << 1;"},{n,7556,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // The first argument must be a pointer.\n if (!getFunctionOrMethodParamType(D, 0)->isPointerType()) {\n S.Diag(getFunctionOrMethodParamRange(D, 0).getBegin(), diag::err_anyx86_interrupt_attribute) << (S.Context.getTargetInfo().getTriple().getArch() == llvm::Triple::x86 ? 0 : 1) << 2;"},{n,7572,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (NumParams == 2 && (!getFunctionOrMethodParamType(D, 1)->isUnsignedIntegerType() || S.Context.getTypeSize(getFunctionOrMethodParamType(D, 1)) != TypeSize)) {\n S.Diag(getFunctionOrMethodParamRange(D, 1).getBegin(), diag::err_anyx86_interrupt_attribute) << (S.Context.getTargetInfo().getTriple().getArch() == llvm::Triple::x86 ? 0 : 1) << 3 << S.Context.getIntTypeForBitwidth(TypeSize, /*Signed=*/false);"}}, [l]={ ["clang/test/SemaCXX/attr-x86-interrupt.cpp"]={"clang/test/SemaCXX/attr-x86-interrupt.cpp:15:28: error: x86-64 \'interrupt\' attribute only applies to functions that have a \'void\' return type","clang/test/SemaCXX/attr-x86-interrupt.cpp:16:1: error: x86-64 \'interrupt\' attribute only applies to functions that have only a pointer parameter optionally followed by an integer parameter","clang/test/SemaCXX/attr-x86-interrupt.cpp:17:1: error: x86-64 \'interrupt\' attribute only applies to functions that have only a pointer parameter optionally followed by an integer parameter","clang/test/SemaCXX/attr-x86-interrupt.cpp:18:38: error: x86-64 \'interrupt\' attribute only applies to functions that have a pointer as the first parameter","clang/test/SemaCXX/attr-x86-interrupt.cpp:26:47: error: x86-64 \'interrupt\' attribute only applies to functions that have a \'unsigned long long\' type as the second parameter","clang/test/SemaCXX/attr-x86-interrupt.cpp:34:48: error: x86-64 \'interrupt\' attribute only applies to functions that have a \'unsigned long long\' type as the second parameter","clang/test/SemaCXX/attr-x86-interrupt.cpp:41:46: error: x86-64 \'interrupt\' attribute only applies to functions that have a \'unsigned long long\' type as the second parameter"} } }, ["err_anyx86_interrupt_called"]={ [c]="err_anyx86_interrupt_called", [d]="interrupt service routine cannot be called directly", [e]="interrupt service routine cannot be called directly", [f]=k, [g]="interrupt service routine cannot be called directly", [h]=a, [i]=m, [b]={"d51e9933b6aa",1452830791,"[X86] Support \'interrupt\' attribute for x86","[X86] Support \'interrupt\' attribute for x86\nThis attribute may be attached to a function definition and instructs the backend to generate appropriate function entry/exit code so that\nit can be used directly as an interrupt handler.\nThe IRET instruction, instead of the RET instruction, is used to return from interrupt or exception handlers. All registers, except for the EFLAGS register which is restored by the IRET instruction, are preserved by the compiler.\nAny interruptible-without-stack-switch code must be compiled with -mno-red-zone since interrupt handlers can and will, because of the hardware design, touch\nthe red zone.\n\ninterrupt handler must be declared with a mandatory pointer argument:\nstruct interrupt_frame;\n\n__attribute__ ((interrupt))\nvoid f (struct interrupt_frame *frame) {\n ...\n}\nand user must properly define the structure the pointer pointing to.\n\nexception handler: \n\nThe exception handler is very similar to the interrupt handler with a different mandatory function signature:\n#ifdef __x86_64__\ntypedef unsigned long long int uword_t;\n#else\ntypedef unsigned int uword_t;\n#endif\n\nstruct interrupt_frame;\n\n__attribute__ ((interrupt))\nvoid f (struct interrupt_frame *frame, uword_t error_code) {\n ...\n}\nand compiler pops the error code off stack before the IRET instruction.\n\nThe exception handler should only be used for exceptions which push an error code and all other exceptions must use the interrupt handler.\nThe system will crash if the wrong handler is used.\nDifferential Revision: http://reviews.llvm.org/D15709\n\nllvm-svn: 257867"}, [j]={{Y,7356,"/// BuildResolvedCallExpr - Build a call to a resolved expression,\n/// i.e. an expression not of \\p OverloadTy. The expression should\n/// unary-convert to an expression of function-pointer or\n/// block-pointer type.\n///\n/// \\param NDecl the declaration being called, if available\nExprResult Sema::BuildResolvedCallExpr(Expr *Fn, NamedDecl *NDecl, SourceLocation LParenLoc, ArrayRef<Expr *> Args, SourceLocation RParenLoc, Expr *Config, bool IsExecConfig, ADLCallKind UsesADL) {\n // ...\n // Functions with \'interrupt\' attribute cannot be called directly.\n if (FDecl && FDecl->hasAttr<AnyX86InterruptAttr>()) {\n Diag(Fn->getExprLoc(), diag::err_anyx86_interrupt_called);"}}, [l]={ ["clang/test/SemaCXX/attr-x86-interrupt.cpp"]={"clang/test/SemaCXX/attr-x86-interrupt.cpp:62:3: error: interrupt service routine cannot be called directly","clang/test/SemaCXX/attr-x86-interrupt.cpp:68:3: error: interrupt service routine cannot be called directly","clang/test/SemaCXX/attr-x86-interrupt.cpp:48:3: error: interrupt service routine cannot be called directly"} } }, ["err_arc_array_param_no_ownership"]={ [c]="err_arc_array_param_no_ownership", [d]="must explicitly describe intended ownership of an object array parameter", [e]="must explicitly describe intended ownership of an object array parameter", [f]=k, [g]="must explicitly describe intended ownership of an object array parameter", [h]=a, [i]=J, [b]={jb,1308874139,fb,kb}, [j]={{o,14905,"ParmVarDecl *Sema::CheckParameter(DeclContext *DC, SourceLocation StartLoc, SourceLocation NameLoc, IdentifierInfo *Name, QualType T, TypeSourceInfo *TSInfo, StorageClass SC) {\n // In ARC, infer a lifetime qualifier for appropriate parameter types.\n if (getLangOpts().ObjCAutoRefCount && T.getObjCLifetime() == Qualifiers::OCL_None && T->isObjCLifetimeType()) {\n // ...\n // Special cases for arrays:\n // - if it\'s const, use __unsafe_unretained\n // - otherwise, it\'s an error\n if (T->isArrayType()) {\n if (!T.isConstQualified()) {\n if (DelayedDiagnostics.shouldDelayDiagnostics())\n DelayedDiagnostics.add(sema::DelayedDiagnostic::makeForbiddenType(NameLoc, diag::err_arc_array_param_no_ownership, T, false));"},{o,14907,"ParmVarDecl *Sema::CheckParameter(DeclContext *DC, SourceLocation StartLoc, SourceLocation NameLoc, IdentifierInfo *Name, QualType T, TypeSourceInfo *TSInfo, StorageClass SC) {\n // In ARC, infer a lifetime qualifier for appropriate parameter types.\n if (getLangOpts().ObjCAutoRefCount && T.getObjCLifetime() == Qualifiers::OCL_None && T->isObjCLifetimeType()) {\n // ...\n // Special cases for arrays:\n // - if it\'s const, use __unsafe_unretained\n // - otherwise, it\'s an error\n if (T->isArrayType()) {\n if (!T.isConstQualified()) {\n if (DelayedDiagnostics.shouldDelayDiagnostics())\n // ...\n else\n Diag(NameLoc, diag::err_arc_array_param_no_ownership) << TSInfo->getTypeLoc().getSourceRange();"},{n,9835,"/// Handle a delayed forbidden-type diagnostic.\nstatic void handleDelayedForbiddenType(Sema &S, DelayedDiagnostic &DD, Decl *D) {\n // ...\n if (S.getLangOpts().ObjCAutoRefCount)\n if (const auto *FD = dyn_cast<FunctionDecl>(D)) {\n // ...\n if (FD->hasAttr<UnavailableAttr>() && DD.getForbiddenTypeDiagnostic() == diag::err_arc_array_param_no_ownership) {"}}, [l]={ ["clang/test/SemaObjCXX/arc-0x.mm"]={"clang/test/SemaObjCXX/arc-0x.mm:110:16: error: must explicitly describe intended ownership of an object array parameter","clang/test/SemaObjCXX/arc-0x.mm:111:15: error: must explicitly describe intended ownership of an object array parameter"} } }, ["err_arc_assign_property_ownership"]={ [c]="err_arc_assign_property_ownership", [d]="existing instance variable %1 for property %0 with %select{unsafe_unretained|assign}2 attribute must be __unsafe_unretained", [e]={{nil,nil,{"existing instance variable B for property A with ",{"unsafe_unretained","assign"}," attribute must be __unsafe_unretained"}}}, [f]=k, [g]="existing instance variable (.*?) for property (.*?) with (?:unsafe_unretained|assign) attribute must be __unsafe_unretained", [h]=a, [i]="ARC and @properties", [b]={jb,1308874139,fb,kb}, [j]={{cb,208,"class PropertiesRewriter {\n // ...\n void removeAssignForDefaultStrong(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n if (I->ImplD)\n Pass.TA.clearDiagnostic(diag::err_arc_strong_property_ownership, diag::err_arc_assign_property_ownership, diag::err_arc_inconsistent_property_ownership, I->IvarD->getLocation());"},{cb,237,"class PropertiesRewriter {\n // ...\n void rewriteAssign(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n // ...\n if (I->ImplD)\n Pass.TA.clearDiagnostic(diag::err_arc_strong_property_ownership, diag::err_arc_assign_property_ownership, diag::err_arc_inconsistent_property_ownership, I->IvarD->getLocation());"},{cb,262,"class PropertiesRewriter {\n // ...\n void maybeAddWeakOrUnsafeUnretainedAttr(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n // ...\n if (I->ImplD) {\n Pass.TA.clearDiagnostic(diag::err_arc_strong_property_ownership, diag::err_arc_assign_property_ownership, diag::err_arc_inconsistent_property_ownership, I->IvarD->getLocation());"},{mb,777,"static void checkARCPropertyImpl(Sema &S, SourceLocation propertyImplLoc, ObjCPropertyDecl *property, ObjCIvarDecl *ivar) {\n // ...\n case Qualifiers::OCL_ExplicitNone:\n S.Diag(ivar->getLocation(), diag::err_arc_assign_property_ownership) << property->getDeclName() << ivar->getDeclName() << ((property->getPropertyAttributesAsWritten() & ObjCPropertyAttribute::kind_assign) != 0);"}}, [l]={ ["clang/test/SemaObjC/mrc-weak.m"]={"clang/test/SemaObjC/mrc-weak.m:24:13: error: existing instance variable \'_ub\' for property \'ub\' with unsafe_unretained attribute must be __unsafe_unretained"} } }, ["err_arc_atomic_ownership"]={ [c]="err_arc_atomic_ownership", [d]="cannot perform atomic operation on a pointer to type %0: type has non-trivial ownership", [e]="cannot perform atomic operation on a pointer to type A: type has non-trivial ownership", [f]=k, [g]="cannot perform atomic operation on a pointer to type (.*?)\\: type has non\\-trivial ownership", [h]=a, [i]=J, [b]={jb,1308874139,fb,kb}, [j]={{t,3238,"bool Sema::CheckARMBuiltinExclusiveCall(unsigned BuiltinID, CallExpr *TheCall, unsigned MaxWidth) {\n // ...\n case Qualifiers::OCL_Weak:\n case Qualifiers::OCL_Strong:\n case Qualifiers::OCL_Autoreleasing:\n Diag(DRE->getBeginLoc(), diag::err_arc_atomic_ownership) << ValType << PointerArg->getSourceRange();"},{t,7247,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n case Qualifiers::OCL_Weak:\n case Qualifiers::OCL_Strong:\n case Qualifiers::OCL_Autoreleasing:\n // ...\n Diag(ExprRange.getBegin(), diag::err_arc_atomic_ownership) << ValType << Ptr->getSourceRange();"},{t,7582,"/// We have a call to a function like __sync_fetch_and_add, which is an\n/// overloaded function based on the pointer type of its first argument.\n/// The main BuildCallExpr routines have already promoted the types of\n/// arguments because all of these calls are prototyped as void(...).\n///\n/// This function goes through and does final semantic checking for these\n/// builtins, as well as generating any warnings.\nExprResult Sema::SemaBuiltinAtomicOverloaded(ExprResult TheCallResult) {\n // ...\n case Qualifiers::OCL_Weak:\n case Qualifiers::OCL_Strong:\n case Qualifiers::OCL_Autoreleasing:\n Diag(DRE->getBeginLoc(), diag::err_arc_atomic_ownership) << ValType << FirstArg->getSourceRange();"}}, [l]={ [nb]={"clang/test/SemaObjC/arc.m:515:3: error: cannot perform atomic operation on a pointer to type \'__strong id\': type has non-trivial ownership"} } }, ["err_arc_autoreleasing_capture"]={ [c]="err_arc_autoreleasing_capture", [d]="cannot capture __autoreleasing variable in a %select{block|lambda by copy}0", [e]={{nil,nil,{"cannot capture __autoreleasing variable in a ",{Lb,"lambda by copy"}}}}, [f]=k, [g]="cannot capture __autoreleasing variable in a (?:block|lambda by copy)", [h]=a, [i]=J, [b]={"67cd5e094e43",1333085028,"Forbid the block and lambda copy-capture of __autoreleasing variables","Forbid the block and lambda copy-capture of __autoreleasing variables\nin ARC, under the usual reasoning limiting the use of __autoreleasing.\n\nllvm-svn: 153725"}, [j]={{Y,19244,"// Returns true if the capture by block was successful.\nstatic bool captureInBlock(BlockScopeInfo *BSI, ValueDecl *Var, SourceLocation Loc, const bool BuildAndDiagnose, QualType &CaptureType, QualType &DeclRefType, const bool Nested, Sema &S, bool Invalid) {\n // ...\n // Forbid the block-capture of autoreleasing variables.\n if (!Invalid && CaptureType.getObjCLifetime() == Qualifiers::OCL_Autoreleasing) {\n if (BuildAndDiagnose) {\n S.Diag(Loc, diag::err_arc_autoreleasing_capture) << /*block*/ 0;"},{Y,19394,"/// Capture the given variable in the lambda.\nstatic bool captureInLambda(LambdaScopeInfo *LSI, ValueDecl *Var, SourceLocation Loc, const bool BuildAndDiagnose, QualType &CaptureType, QualType &DeclRefType, const bool RefersToCapturedVariable, const Sema::TryCaptureKind Kind, SourceLocation EllipsisLoc, const bool IsTopScope, Sema &S, bool Invalid) {\n // ...\n // Compute the type of the field that will capture this variable.\n if (ByRef) {\n // ...\n } else {\n // ...\n // Forbid the lambda copy-capture of autoreleasing variables.\n if (!Invalid && CaptureType.getObjCLifetime() == Qualifiers::OCL_Autoreleasing) {\n if (BuildAndDiagnose) {\n S.Diag(Loc, diag::err_arc_autoreleasing_capture) << /*lambda*/ 1;"}}, [l]={ ["clang/test/SemaObjC/arc-invalid.m"]={"clang/test/SemaObjC/arc-invalid.m:17:23: error: cannot capture __autoreleasing variable in a block"} } }, ["err_arc_autoreleasing_var"]={ [c]="err_arc_autoreleasing_var", [d]="%select{__block variables|global variables|fields|instance variables}0 cannot have __autoreleasing ownership", [e]={{nil,nil,{{"__block variables","global variables","fields","instance variables"}," cannot have __autoreleasing ownership"}}}, [f]=k, [g]="(?:__block variables|global variables|fields|instance variables) cannot have __autoreleasing ownership", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{o,6876,"bool Sema::inferObjCARCLifetime(ValueDecl *decl) {\n // ...\n if (lifetime == Qualifiers::OCL_Autoreleasing) {\n // ...\n if (kind != -1U) {\n Diag(decl->getLocation(), diag::err_arc_autoreleasing_var) << kind;"}}, [l]={ ["clang/test/SemaObjC/arc-property-decl-attrs.m"]={"clang/test/SemaObjC/arc-property-decl-attrs.m:8:24: error: instance variables cannot have __autoreleasing ownership","clang/test/SemaObjC/arc-property-decl-attrs.m:19:24: error: instance variables cannot have __autoreleasing ownership","clang/test/SemaObjC/arc-property-decl-attrs.m:30:24: error: instance variables cannot have __autoreleasing ownership"} } }, ["err_arc_bridge_cast_incompatible"]={ [c]="err_arc_bridge_cast_incompatible", [d]="incompatible types casting %0 to %1 with a %select{__bridge|__bridge_transfer|__bridge_retained}2 cast", [e]={{nil,nil,{"incompatible types casting A to B with a ",{"__bridge","__bridge_transfer","__bridge_retained"}," cast"}}}, [f]=k, [g]="incompatible types casting (.*?) to (.*?) with a (?:__bridge|__bridge_transfer|__bridge_retained) cast", [h]=a, [i]="ARC Casting Rules", [b]={G,1308178962,H,F}, [j]={{S,4728,"ExprResult Sema::BuildObjCBridgedCast(SourceLocation LParenLoc, ObjCBridgeCastKind Kind, SourceLocation BridgeKeywordLoc, TypeSourceInfo *TSInfo, Expr *SubExpr) {\n // ...\n if (T->isDependentType() || SubExpr->isTypeDependent()) {\n // ...\n } else if (T->isObjCARCBridgableType() && FromType->isCARCBridgableType()) {\n // ...\n } else if (T->isCARCBridgableType() && FromType->isObjCARCBridgableType()) {\n // ...\n } else {\n Diag(LParenLoc, diag::err_arc_bridge_cast_incompatible) << FromType << T << Kind << SubExpr->getSourceRange() << TSInfo->getTypeLoc().getSourceRange();"}}, [l]={ ["clang/test/SemaObjCXX/arc-bridged-cast.mm"]={"clang/test/SemaObjCXX/arc-bridged-cast.mm:21:3: error: incompatible types casting \'CFTypeRef\' (aka \'const void *\') to \'int *\' with a __bridge cast"} } }, ["err_arc_bridge_cast_wrong_kind"]={ [c]="err_arc_bridge_cast_wrong_kind", [d]="cast of %select{Objective-C|block|C}0 pointer type %1 to %select{Objective-C|block|C}2 pointer type %3 cannot use %select{__bridge|__bridge_transfer|__bridge_retained}4", [e]={{nil,nil,{"cast of ",{Jb,Lb,Cb}," pointer type B to ",{Jb,Lb,Cb}," pointer type D cannot use ",{"__bridge","__bridge_transfer","__bridge_retained"}}}}, [f]=k, [g]="cast of (?:Objective\\-C|block|C) pointer type (.*?) to (?:Objective\\-C|block|C) pointer type (.*?) cannot use (?:__bridge|__bridge_transfer|__bridge_retained)", [h]=a, [i]="ARC Casting Rules", [b]={G,1308178962,H,F}, [j]={{S,4665,"ExprResult Sema::BuildObjCBridgedCast(SourceLocation LParenLoc, ObjCBridgeCastKind Kind, SourceLocation BridgeKeywordLoc, TypeSourceInfo *TSInfo, Expr *SubExpr) {\n // ...\n if (T->isDependentType() || SubExpr->isTypeDependent()) {\n // ...\n } else if (T->isObjCARCBridgableType() && FromType->isCARCBridgableType()) {\n // ...\n case OBC_BridgeRetained: {\n // ...\n Diag(BridgeKeywordLoc, diag::err_arc_bridge_cast_wrong_kind) << 2 << FromType << (T->isBlockPointerType() ? 1 : 0) << T << SubExpr->getSourceRange() << Kind;"},{S,4708,"ExprResult Sema::BuildObjCBridgedCast(SourceLocation LParenLoc, ObjCBridgeCastKind Kind, SourceLocation BridgeKeywordLoc, TypeSourceInfo *TSInfo, Expr *SubExpr) {\n // ...\n if (T->isDependentType() || SubExpr->isTypeDependent()) {\n // ...\n } else if (T->isObjCARCBridgableType() && FromType->isCARCBridgableType()) {\n // ...\n } else if (T->isCARCBridgableType() && FromType->isObjCARCBridgableType()) {\n // ...\n case OBC_BridgeTransfer: {\n // ...\n Diag(BridgeKeywordLoc, diag::err_arc_bridge_cast_wrong_kind) << (FromType->isBlockPointerType() ? 1 : 0) << FromType << 2 << T << SubExpr->getSourceRange() << Kind;"}} }, ["err_arc_bridge_retain"]={ [c]="err_arc_bridge_retain", [d]="unknown cast annotation __bridge_retain; did you mean __bridge_retained?", [e]="unknown cast annotation __bridge_retain; did you mean __bridge_retained?", [f]=k, [g]="unknown cast annotation __bridge_retain; did you mean __bridge_retained\\?", [h]=a, [i]="ARC Parse Issue", [b]={"0c07bee8bd2c",1308347772,"Only accept __bridge_retain in system headers, as Doug suggested.","Only accept __bridge_retain in system headers, as Doug suggested.\n\nllvm-svn: 133300"}, [j]={{"clang/lib/Parse/ParseExpr.cpp",2982,"/// ParseParenExpression - This parses the unit that starts with a \'(\' token,\n/// based on what is allowed by ExprType. The actual thing parsed is returned\n/// in ExprType. If stopIfCastExpr is true, it will only return the parsed type,\n/// not the parsed cast-expression.\n///\n/// \\verbatim\n/// primary-expression: [C99 6.5.1]\n/// \'(\' expression \')\'\n/// [GNU] \'(\' compound-statement \')\' (if !ParenExprOnly)\n/// postfix-expression: [C99 6.5.2]\n/// \'(\' type-name \')\' \'{\' initializer-list \'}\'\n/// \'(\' type-name \')\' \'{\' initializer-list \',\' \'}\'\n/// cast-expression: [C99 6.5.4]\n/// \'(\' type-name \')\' cast-expression\n/// [ARC] bridged-cast-expression\n/// [ARC] bridged-cast-expression:\n/// (__bridge type-name) cast-expression\n/// (__bridge_transfer type-name) cast-expression\n/// (__bridge_retained type-name) cast-expression\n/// fold-expression: [C++1z]\n/// \'(\' cast-expression fold-operator \'...\' \')\'\n/// \'(\' \'...\' fold-operator cast-expression \')\'\n/// \'(\' cast-expression fold-operator \'...\'\n/// fold-operator cast-expression \')\'\n/// [OPENMP] Array shaping operation\n/// \'(\' \'[\' expression \']\' { \'[\' expression \']\' } cast-expression\n/// \\endverbatim\nExprResult Parser::ParseParenExpression(ParenParseOption &ExprType, bool stopIfCastExpr, bool isTypeCast, ParsedType &CastTy, SourceLocation &RParenLoc) {\n // ...\n // None of these cases should fall through with an invalid Result\n // unless they\'ve already reported an error.\n if (ExprType >= CompoundStmt && Tok.is(tok::l_brace)) {\n // ...\n } else if (ExprType >= CompoundLiteral && BridgeCast) {\n // ...\n if (tokenKind == tok::kw___bridge)\n // ...\n else if (tokenKind == tok::kw___bridge_transfer)\n // ...\n else if (tokenKind == tok::kw___bridge_retained)\n // ...\n else {\n // ...\n if (!PP.getSourceManager().isInSystemHeader(BridgeKeywordLoc))\n Diag(BridgeKeywordLoc, diag::err_arc_bridge_retain) << FixItHint::CreateReplacement(BridgeKeywordLoc, \"__bridge_retained\");"}}, [l]={ ["clang/test/SemaObjC/arc-bridged-cast.m"]={"clang/test/SemaObjC/arc-bridged-cast.m:35:20: error: unknown cast annotation __bridge_retain; did you mean __bridge_retained?"} } }, ["err_arc_cast_requires_bridge"]={ [c]="err_arc_cast_requires_bridge", [d]="%select{cast|implicit conversion}0 of %select{Objective-C|block|C}1 pointer type %2 to %select{Objective-C|block|C}3 pointer type %4 requires a bridged cast", [e]={{nil,nil,{{"cast","implicit conversion"}," of ",{Jb,Lb,Cb}," pointer type C to ",{Jb,Lb,Cb}," pointer type E requires a bridged cast"}}}, [f]=k, [g]="(?:cast|implicit conversion) of (?:Objective\\-C|block|C) pointer type (.*?) to (?:Objective\\-C|block|C) pointer type (.*?) requires a bridged cast", [h]=a, [i]="ARC Casting Rules", [b]={G,1308178962,H,F}, [j]={{lb,210,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n // ...\n void rewriteToBridgedCast(CastExpr *E, ObjCBridgeCastKind Kind, Transaction &Trans) {\n // ...\n if (!TA.hasDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, E->getBeginLoc())) {"},{lb,227,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n // ...\n void rewriteToBridgedCast(CastExpr *E, ObjCBridgeCastKind Kind, Transaction &Trans) {\n // ...\n TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, E->getBeginLoc());"},{lb,303,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n // ...\n void rewriteBlockCopyMacro(CastExpr *E) {\n // ...\n Pass.TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, OuterRange);"},{lb,313,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n // ...\n void removeBlockReleaseMacro(CastExpr *E) {\n // ...\n Pass.TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, OuterRange);"},{S,3918,"static void diagnoseObjCARCConversion(Sema &S, SourceRange castRange, QualType castType, ARCConversionTypeClass castACTC, Expr *castExpr, Expr *realCast, ARCConversionTypeClass exprACTC, Sema::CheckedConversionKind CCK) {\n // ...\n // Bridge from an ARC type to a CF type.\n if (castACTC == ACTC_retainable && isAnyRetainable(exprACTC)) {\n S.Diag(loc, diag::err_arc_cast_requires_bridge) << convKindForDiag << 2 // of C pointer type"},{S,3960,"static void diagnoseObjCARCConversion(Sema &S, SourceRange castRange, QualType castType, ARCConversionTypeClass castACTC, Expr *castExpr, Expr *realCast, ARCConversionTypeClass exprACTC, Sema::CheckedConversionKind CCK) {\n // ...\n // Bridge from a CF type to an ARC type.\n if (exprACTC == ACTC_retainable && isAnyRetainable(castACTC)) {\n // ...\n S.Diag(loc, diag::err_arc_cast_requires_bridge) << convKindForDiag << unsigned(castExprType->isBlockPointerType()) // of ObjC|block type"}}, [l]={ ["clang/test/SemaObjCXX/objcbridge-static-cast.mm"]={"clang/test/SemaObjCXX/objcbridge-static-cast.mm:30:10: error: cast of C pointer type \'CFTestingRef\' (aka \'__CFError *\') to Objective-C pointer type \'NSString *\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:56:9: error: cast of C pointer type \'CFErrorRef2\' (aka \'__CFErrorRef *\') to Objective-C pointer type \'NSString *\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:60:9: error: cast of C pointer type \'CFErrorRef2\' (aka \'__CFErrorRef *\') to Objective-C pointer type \'NSError *\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:63:9: error: cast of C pointer type \'CFErrorRef2\' (aka \'__CFErrorRef *\') to Objective-C pointer type \'MyError *\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:67:9: error: cast of C pointer type \'CFUColor2Ref\' (aka \'__CFUPrimeColor *\') to Objective-C pointer type \'NSUColor *\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:70:21: error: cast of Objective-C pointer type \'NSError *\' to C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:73:21: error: cast of Objective-C pointer type \'NSString *\' to C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:77:9: error: cast of C pointer type \'CFErrorRef2\' (aka \'__CFErrorRef *\') to Objective-C pointer type \'Class\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:81:21: error: cast of Objective-C pointer type \'Class\' to C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:89:9: error: cast of C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') to Objective-C pointer type \'id\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:92:8: error: cast of C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') to Objective-C pointer type \'id<P1,P2>\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:95:8: error: cast of C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') to Objective-C pointer type \'id<P1,P2,P4>\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:102:10: error: cast of C pointer type \'CFMyErrorRef\' (aka \'__CFMyErrorRef *\') to Objective-C pointer type \'id\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:105:8: error: cast of C pointer type \'CFMyErrorRef\' (aka \'__CFMyErrorRef *\') to Objective-C pointer type \'id<P1,P2>\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:108:8: error: cast of C pointer type \'CFMyErrorRef\' (aka \'__CFMyErrorRef *\') to Objective-C pointer type \'id<P1,P2,P3>\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:111:8: error: cast of C pointer type \'CFMyErrorRef\' (aka \'__CFMyErrorRef *\') to Objective-C pointer type \'id<P2,P3>\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:114:8: error: cast of C pointer type \'CFMyErrorRef\' (aka \'__CFMyErrorRef *\') to Objective-C pointer type \'id<P1,P2,P4>\' requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:121:20: error: cast of Objective-C pointer type \'id\' to C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:124:20: error: cast of Objective-C pointer type \'id<P1,P2,P3>\' to C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:127:20: error: cast of Objective-C pointer type \'id<P1,P2,P3,P4>\' to C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:130:20: error: cast of Objective-C pointer type \'id<P1,P2>\' to C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') requires a bridged cast","clang/test/SemaObjCXX/objcbridge-static-cast.mm:133:20: error: cast of Objective-C pointer type \'id<P2,P3>\' to C pointer type \'CFErrorRef\' (aka \'__CFErrorRef *\') requires a bridged cast"} } }, ["err_arc_collection_forward"]={ [c]="err_arc_collection_forward", [d]="collection expression type %0 is a forward declaration", [e]="collection expression type A is a forward declaration", [f]=k, [g]="collection expression type (.*?) is a forward declaration", [h]=a, [i]=J, [b]={"538482373bba",1311728835,"Clean up the analysis of the collection operand to ObjC","Clean up the analysis of the collection operand to ObjC\nfor-in statements; specifically, make sure to close over any\ntemporaries or cleanups it might require. In ARC, this has\nimplications for the lifetime of the collection, so emit it\nwith a retain and release it upon exit from the loop.\n\nrdar://problem/9817306\n\nllvm-svn: 136204"}, [j]={{"clang/lib/Sema/SemaStmt.cpp",2244,"ExprResult Sema::CheckObjCForCollectionOperand(SourceLocation forLoc, Expr *collection) {\n // ...\n if (iface && (getLangOpts().ObjCAutoRefCount ? RequireCompleteType(forLoc, QualType(objectType, 0), diag::err_arc_collection_forward, collection) : !isCompleteType(forLoc, QualType(objectType, 0)))) {"}}, [l]={ [nb]={"clang/test/SemaObjC/arc.m:690:3: error: collection expression type \'Test37\' is a forward declaration"} } }, ["err_arc_convesion_of_weak_unavailable"]={ [c]="err_arc_convesion_of_weak_unavailable", [d]="%select{implicit conversion|cast}0 of weak-unavailable object of type %1 to a __weak object of type %2", [e]={{nil,nil,{{"implicit conversion","cast"}," of weak-unavailable object of type B to a __weak object of type C"}}}, [f]=k, [g]="(?:implicit conversion|cast) of weak\\-unavailable object of type (.*?) to a __weak object of type (.*?)", [h]=a, [i]=wb, [b]={"f2913401fc81",1310146902,"objc++-arc: more diagnosis of converting a weak-unavailable","objc++-arc: more diagnosis of converting a weak-unavailable\nobject to a __weak object type. // rdar://9732636\n\nllvm-svn: 134706"}, [j]={{"clang/lib/Sema/SemaCast.cpp",3215,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n // ...\n // ARC imposes extra restrictions on casts.\n if (Self.getLangOpts().allowsNonTrivialObjCLifetimeQualifiers()) {\n // ...\n if (Self.getLangOpts().ObjCAutoRefCount && CastPtr) {\n // ...\n } else if (!Self.CheckObjCARCUnavailableWeakConversion(DestType, SrcType)) {\n Self.Diag(SrcExpr.get()->getBeginLoc(), diag::err_arc_convesion_of_weak_unavailable) << 1 << SrcType << DestType << SrcExpr.get()->getSourceRange();"},{D,4497,"/// PerformImplicitConversion - Perform an implicit conversion of the\n/// expression From to the type ToType by following the standard\n/// conversion sequence SCS. Returns the converted\n/// expression. Flavor is the context in which we\'re performing this\n/// conversion, for use in error messages.\nExprResult Sema::PerformImplicitConversion(Expr *From, QualType ToType, const StandardConversionSequence &SCS, AssignmentAction Action, CheckedConversionKind CCK) {\n // ...\n case ICK_Writeback_Conversion:\n case ICK_Pointer_Conversion: {\n if (SCS.IncompatibleObjC && Action != AA_Casting) {\n // ...\n } else if (getLangOpts().allowsNonTrivialObjCLifetimeQualifiers() && !CheckObjCARCUnavailableWeakConversion(ToType, From->getType())) {\n if (Action == AA_Initializing)\n // ...\n else\n Diag(From->getBeginLoc(), diag::err_arc_convesion_of_weak_unavailable) << (Action == AA_Casting) << From->getType() << ToType << From->getSourceRange();"}}, [l]={ ["clang/test/SemaObjCXX/arc-unavailable-for-weakref.mm"]={"clang/test/SemaObjCXX/arc-unavailable-for-weakref.mm:35:21: error: cast of weak-unavailable object of type \'NOWEAK *\' to a __weak object of type \'__weak id\'","clang/test/SemaObjCXX/arc-unavailable-for-weakref.mm:48:28: error: cast of weak-unavailable object of type \'NOWEAK<P,P1> *\' to a __weak object of type \'__weak id<P,P1>\'"} } }, ["err_arc_gained_method_convention"]={ [c]="err_arc_gained_method_convention", [d]="method implementation does not match its declaration", [e]="method implementation does not match its declaration", [f]=k, [g]="method implementation does not match its declaration", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{ib,2530,"/// In ARC, check whether the conventional meanings of the two methods\n/// match. If they don\'t, it\'s a hard error.\nstatic bool checkMethodFamilyMismatch(Sema &S, ObjCMethodDecl *impl, ObjCMethodDecl *decl) {\n // ...\n if (declFamily == OMF_None) {\n // ...\n errorID = diag::err_arc_gained_method_convention;"}}, [l]={ [Db]={"clang/test/ARCMT/checking.m:240:1: error: method implementation does not match its declaration","clang/test/ARCMT/checking.m:261:1: error: method implementation does not match its declaration","clang/test/ARCMT/checking.m:268:1: error: method implementation does not match its declaration"} } }, ["err_arc_illegal_explicit_message"]={ [c]="err_arc_illegal_explicit_message", [d]="ARC forbids explicit message send of %0", [e]="ARC forbids explicit message send of A", [f]=k, [g]="ARC forbids explicit message send of (.*?)", [h]=a, [i]=ob, [b]={G,1308178962,H,F}, [j]={{"clang/lib/ARCMigrate/TransRetainReleaseDealloc.cpp",390,"class RetainReleaseDeallocRemover : public RecursiveASTVisitor<RetainReleaseDeallocRemover> {\n // ...\n void clearDiagnostics(SourceLocation loc) const { Pass.TA.clearDiagnostic(diag::err_arc_illegal_explicit_message, diag::err_unavailable, diag::err_unavailable_message, loc); }"},{S,3269,"/// Build an Objective-C instance message expression.\n///\n/// This routine takes care of both normal instance messages and\n/// instance messages to the superclass instance.\n///\n/// \\param Receiver The expression that computes the object that will\n/// receive this message. This may be empty, in which case we are\n/// sending to the superclass instance and \\p SuperLoc must be a valid\n/// source location.\n///\n/// \\param ReceiverType The (static) type of the object receiving the\n/// message. When a \\p Receiver expression is provided, this is the\n/// same type as that expression. For a superclass instance send, this\n/// is a pointer to the type of the superclass.\n///\n/// \\param SuperLoc The location of the \"super\" keyword in a\n/// superclass instance message.\n///\n/// \\param Sel The selector to which the message is being sent.\n///\n/// \\param Method The method that this instance message is invoking, if\n/// already known.\n///\n/// \\param LBracLoc The location of the opening square bracket \']\'.\n///\n/// \\param RBracLoc The location of the closing square bracket \']\'.\n///\n/// \\param ArgsIn The message arguments.\nExprResult Sema::BuildInstanceMessage(Expr *Receiver, QualType ReceiverType, SourceLocation SuperLoc, Selector Sel, ObjCMethodDecl *Method, SourceLocation LBracLoc, ArrayRef<SourceLocation> SelectorLocs, SourceLocation RBracLoc, MultiExprArg ArgsIn, bool isImplicit) {\n // ...\n // In ARC, forbid the user from sending messages to\n // retain/release/autorelease/dealloc/retainCount explicitly.\n if (getLangOpts().ObjCAutoRefCount) {\n // ...\n case OMF_dealloc:\n case OMF_retain:\n case OMF_release:\n case OMF_autorelease:\n case OMF_retainCount:\n Diag(SelLoc, diag::err_arc_illegal_explicit_message) << Sel << RecRange;"}}, [l]={ [Db]={"clang/test/ARCMT/checking.m:76:17: error: ARC forbids explicit message send of \'release\'","clang/test/ARCMT/checking.m:78:15: error: ARC forbids explicit message send of \'release\'","clang/test/ARCMT/checking.m:80:23: error: ARC forbids explicit message send of \'retain\'","clang/test/ARCMT/checking.m:84:15: error: ARC forbids explicit message send of \'retain\'","clang/test/ARCMT/checking.m:86:15: error: ARC forbids explicit message send of \'release\'","clang/test/ARCMT/checking.m:90:6: error: ARC forbids explicit message send of \'retainCount\'","clang/test/ARCMT/checking.m:93:6: error: ARC forbids explicit message send of \'autorelease\'","clang/test/ARCMT/checking.m:96:6: error: ARC forbids explicit message send of \'autorelease\'","clang/test/ARCMT/checking.m:307:3: error: ARC forbids explicit message send of \'release\'"} } }, ["err_arc_illegal_method_def"]={ [c]="err_arc_illegal_method_def", [d]="ARC forbids %select{implementation|synthesis}0 of %1", [e]={{nil,nil,{"ARC forbids ",{"implementation","synthesis"}," of B"}}}, [f]=k, [g]="ARC forbids (?:implementation|synthesis) of (.*?)", [h]=a, [i]=ob, [b]={G,1308178962,H,F}, [j]={{ib,417,"/// ActOnStartOfObjCMethodDef - This routine sets up parameters; invisible\n/// and user declared, in the method definition\'s AST.\nvoid Sema::ActOnStartOfObjCMethodDef(Scope *FnBodyScope, Decl *D) {\n // ...\n // In ARC, disallow definition of retain/release/autorelease/retainCount\n if (getLangOpts().ObjCAutoRefCount) {\n // ...\n case OMF_retain:\n case OMF_retainCount:\n case OMF_release:\n case OMF_autorelease:\n Diag(MDecl->getLocation(), diag::err_arc_illegal_method_def) << 0 << MDecl->getSelector();"},{mb,1491,"/// ActOnPropertyImplDecl - This routine performs semantic checks and\n/// builds the AST node for a property implementation declaration; declared\n/// as \\@synthesize or \\@dynamic.\n///\nDecl *Sema::ActOnPropertyImplDecl(Scope *S, SourceLocation AtLoc, SourceLocation PropertyLoc, bool Synthesize, IdentifierInfo *PropertyId, IdentifierInfo *PropertyIvar, SourceLocation PropertyIvarLoc, ObjCPropertyQueryKind QueryKind) {\n // ...\n if (ObjCMethodDecl *getterMethod = property->getGetterMethodDecl()) {\n // ...\n if (getLangOpts().ObjCAutoRefCount && Synthesize)\n // ...\n case OMF_retain:\n case OMF_retainCount:\n case OMF_release:\n case OMF_autorelease:\n Diag(getterMethod->getLocation(), diag::err_arc_illegal_method_def) << 1 << getterMethod->getSelector();"}}, [l]={ ["clang/test/SemaObjC/arc-property-lifetime.m"]={"clang/test/SemaObjC/arc-property-lifetime.m:199:36: error: ARC forbids synthesis of \'retain\'"} } }, ["err_arc_illegal_selector"]={ [c]="err_arc_illegal_selector", [d]="ARC forbids use of %0 in a @selector", [e]="ARC forbids use of A in a @selector", [f]=k, [g]="ARC forbids use of (.*?) in a @selector", [h]=a, [i]=ob, [b]={G,1308178962,H,F}, [j]={{S,1364,"ExprResult Sema::ParseObjCSelectorExpression(Selector Sel, SourceLocation AtLoc, SourceLocation SelLoc, SourceLocation LParenLoc, SourceLocation RParenLoc, bool WarnMultipleSelectors) {\n // ...\n // In ARC, forbid the user from using @selector for\n // retain/release/autorelease/dealloc/retainCount.\n if (getLangOpts().ObjCAutoRefCount) {\n // ...\n case OMF_retain:\n case OMF_release:\n case OMF_autorelease:\n case OMF_retainCount:\n case OMF_dealloc:\n Diag(AtLoc, diag::err_arc_illegal_selector) << Sel << SourceRange(LParenLoc, RParenLoc);"}}, [l]={ [Db]={"clang/test/ARCMT/checking.m:110:11: error: ARC forbids use of \'retain\' in a @selector","clang/test/ARCMT/checking.m:111:7: error: ARC forbids use of \'release\' in a @selector","clang/test/ARCMT/checking.m:112:7: error: ARC forbids use of \'autorelease\' in a @selector","clang/test/ARCMT/checking.m:113:7: error: ARC forbids use of \'dealloc\' in a @selector"} } }, ["err_arc_inconsistent_property_ownership"]={ [c]="err_arc_inconsistent_property_ownership", [d]="%select{|unsafe_unretained|strong|weak}1 property %0 may not also be declared %select{|__unsafe_unretained|__strong|__weak|__autoreleasing}2", [e]={{nil,nil,{{a,"unsafe_unretained","strong","weak"}," property A may not also be declared ",{a,"__unsafe_unretained","__strong","__weak","__autoreleasing"}}}}, [f]=k, [g]="(?:|unsafe_unretained|strong|weak) property (.*?) may not also be declared (?:|__unsafe_unretained|__strong|__weak|__autoreleasing)", [h]=a, [i]="ARC and @properties", [b]={jb,1308874139,fb,kb}, [j]={{"clang/lib/ARCMigrate/TransGCAttrs.cpp",291,"static void checkAllAtProps(MigrationContext &MigrateCtx, SourceLocation AtLoc, IndivPropsTy &IndProps) {\n // ...\n for (unsigned i = 0, e = ATLs.size(); i != e; ++i) {\n // ...\n TA.clearDiagnostic(diag::err_arc_inconsistent_property_ownership, ATLs[i].second->getLocation());"},{cb,209,"class PropertiesRewriter {\n // ...\n void removeAssignForDefaultStrong(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n if (I->ImplD)\n Pass.TA.clearDiagnostic(diag::err_arc_strong_property_ownership, diag::err_arc_assign_property_ownership, diag::err_arc_inconsistent_property_ownership, I->IvarD->getLocation());"},{cb,238,"class PropertiesRewriter {\n // ...\n void rewriteAssign(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n // ...\n if (I->ImplD)\n Pass.TA.clearDiagnostic(diag::err_arc_strong_property_ownership, diag::err_arc_assign_property_ownership, diag::err_arc_inconsistent_property_ownership, I->IvarD->getLocation());"},{cb,263,"class PropertiesRewriter {\n // ...\n void maybeAddWeakOrUnsafeUnretainedAttr(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n // ...\n if (I->ImplD) {\n Pass.TA.clearDiagnostic(diag::err_arc_strong_property_ownership, diag::err_arc_assign_property_ownership, diag::err_arc_inconsistent_property_ownership, I->IvarD->getLocation());"},{mb,99,"/// Check the internal consistency of a property declaration with\n/// an explicit ownership qualifier.\nstatic void checkPropertyDeclWithOwnership(Sema &S, ObjCPropertyDecl *property) {\n // ...\n S.Diag(property->getLocation(), diag::err_arc_inconsistent_property_ownership) << property->getDeclName() << expectedLifetime << propertyLifetime;"}}, [l]={ ["clang/test/SemaObjC/arc-property-decl-attrs.m"]={"clang/test/SemaObjC/arc-property-decl-attrs.m:40:42: error: strong property \'x\' may not also be declared __unsafe_unretained","clang/test/SemaObjC/arc-property-decl-attrs.m:41:29: error: strong property \'y\' may not also be declared __weak","clang/test/SemaObjC/arc-property-decl-attrs.m:42:38: error: strong property \'z\' may not also be declared __autoreleasing","clang/test/SemaObjC/arc-property-decl-attrs.m:46:42: error: strong property \'x\' may not also be declared __unsafe_unretained","clang/test/SemaObjC/arc-property-decl-attrs.m:47:29: error: strong property \'y\' may not also be declared __weak","clang/test/SemaObjC/arc-property-decl-attrs.m:48:38: error: strong property \'z\' may not also be declared __autoreleasing","clang/test/SemaObjC/arc-property-decl-attrs.m:52:40: error: strong property \'x\' may not also be declared __unsafe_unretained","clang/test/SemaObjC/arc-property-decl-attrs.m:53:27: error: strong property \'y\' may not also be declared __weak","clang/test/SemaObjC/arc-property-decl-attrs.m:54:36: error: strong property \'z\' may not also be declared __autoreleasing","clang/test/SemaObjC/arc-property-decl-attrs.m:59:29: error: unsafe_unretained property \'y\' may not also be declared __weak","clang/test/SemaObjC/arc-property-decl-attrs.m:60:38: error: unsafe_unretained property \'z\' may not also be declared __autoreleasing","clang/test/SemaObjC/arc-property-decl-attrs.m:65:40: error: unsafe_unretained property \'y\' may not also be declared __weak","clang/test/SemaObjC/arc-property-decl-attrs.m:66:49: error: unsafe_unretained property \'z\' may not also be declared __autoreleasing"} } }, ["err_arc_indirect_no_ownership"]={ [c]="err_arc_indirect_no_ownership", [d]="%select{pointer|reference}1 to non-const type %0 with no explicit ownership", [e]={{nil,nil,{{"pointer","reference"}," to non-const type A with no explicit ownership"}}}, [f]=k, [g]="(?:pointer|reference) to non\\-const type (.*?) with no explicit ownership", [h]=a, [i]=J, [b]={jb,1308874139,fb,kb}, [j]={{p,2073,"/// Given that we\'re building a pointer or reference to the given\nstatic QualType inferARCLifetimeForPointee(Sema &S, QualType type, SourceLocation loc, bool isReference) {\n // ...\n // If the object type is const-qualified, we can safely use\n // __unsafe_unretained. This is safe (because there are no read\n // barriers), and it\'ll be safe to coerce anything but __weak* to\n // the resulting type.\n if (type.isConstQualified()) {\n // ...\n } else if (type->isObjCARCImplicitlyUnretainedType()) {\n // ...\n } else if (S.isUnevaluatedContext()) {\n // ...\n } else {\n // These types can show up in private ivars in system headers, so\n // we need this to not be an error in those cases. Instead we\n // want to delay.\n if (S.DelayedDiagnostics.shouldDelayDiagnostics()) {\n S.DelayedDiagnostics.add(sema::DelayedDiagnostic::makeForbiddenType(loc, diag::err_arc_indirect_no_ownership, type, isReference));"},{p,2075,"/// Given that we\'re building a pointer or reference to the given\nstatic QualType inferARCLifetimeForPointee(Sema &S, QualType type, SourceLocation loc, bool isReference) {\n // ...\n // If the object type is const-qualified, we can safely use\n // __unsafe_unretained. This is safe (because there are no read\n // barriers), and it\'ll be safe to coerce anything but __weak* to\n // the resulting type.\n if (type.isConstQualified()) {\n // ...\n } else if (type->isObjCARCImplicitlyUnretainedType()) {\n // ...\n } else if (S.isUnevaluatedContext()) {\n // ...\n } else {\n // These types can show up in private ivars in system headers, so\n // we need this to not be an error in those cases. Instead we\n // want to delay.\n if (S.DelayedDiagnostics.shouldDelayDiagnostics()) {\n // ...\n } else {\n S.Diag(loc, diag::err_arc_indirect_no_ownership) << type << isReference;"}}, [l]={ ["clang/test/SemaObjCXX/arc-ppe.mm"]={"clang/test/SemaObjCXX/arc-ppe.mm:16:41: error: pointer to non-const type \'id\' with no explicit ownership"} } }, ["err_arc_init_method_unrelated_result_type"]={ [c]="err_arc_init_method_unrelated_result_type", [d]="init methods must return a type related to the receiver type", [e]="init methods must return a type related to the receiver type", [f]=k, [g]="init methods must return a type related to the receiver type", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{ib,108,"/// Check whether the given method, which must be in the \'init\'\n/// family, is a valid member of that family.\n///\n/// \\param receiverTypeIfCall - if null, check this as if declaring it;\n/// if non-null, check this as if making a call to it with the given\n/// receiver type\n///\n/// \\return true to indicate that there was an error and appropriate\n/// actions were taken\nbool Sema::checkInitMethod(ObjCMethodDecl *method, QualType receiverTypeIfCall) {\n // ...\n Diag(loc, diag::err_arc_init_method_unrelated_result_type);"}}, [l]={ [Db]={"clang/test/ARCMT/checking.m:231:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:232:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:233:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:234:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:235:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:236:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:253:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:254:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:255:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:256:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:257:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:258:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:274:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:275:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:276:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:277:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:278:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:279:1: error: init methods must return a type related to the receiver type","clang/test/ARCMT/checking.m:284:1: error: init methods must return a type related to the receiver type"} } }, ["err_arc_lost_method_convention"]={ [c]="err_arc_lost_method_convention", [d]="method was declared as %select{an \'alloc\'|a \'copy\'|an \'init\'|a \'new\'}0 method, but its implementation doesn\'t match because %select{its result type is not an object pointer|its result type is unrelated to its receiver type}1", [e]={{nil,nil,{"method was declared as ",{"an \'alloc\'","a \'copy\'","an \'init\'","a \'new\'"}," method, but its implementation doesn\'t match because ",{"its result type is not an object pointer","its result type is unrelated to its receiver type"}}}}, [f]=k, [g]="method was declared as (?:an \'alloc\'|a \'copy\'|an \'init\'|a \'new\') method, but its implementation doesn\'t match because (?:its result type is not an object pointer|its result type is unrelated to its receiver type)", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{ib,2525,"/// In ARC, check whether the conventional meanings of the two methods\n/// match. If they don\'t, it\'s a hard error.\nstatic bool checkMethodFamilyMismatch(Sema &S, ObjCMethodDecl *impl, ObjCMethodDecl *decl) {\n // ...\n unsigned errorID = diag::err_arc_lost_method_convention;"}}, [l]={ [Db]={"clang/test/ARCMT/checking.m:246:1: error: method was declared as an \'init\' method, but its implementation doesn\'t match because its result type is not an object pointer","clang/test/ARCMT/checking.m:248:1: error: method was declared as an \'init\' method, but its implementation doesn\'t match because its result type is not an object pointer","clang/test/ARCMT/checking.m:249:1: error: method was declared as an \'init\' method, but its implementation doesn\'t match because its result type is not an object pointer","clang/test/ARCMT/checking.m:250:1: error: method was declared as an \'init\' method, but its implementation doesn\'t match because its result type is not an object pointer"} } }, ["err_arc_may_not_respond"]={ [c]="err_arc_may_not_respond", [d]="no visible @interface for %0 declares the selector %1", [e]="no visible @interface for A declares the selector B", [f]=k, [g]="no visible @interface for (.*?) declares the selector (.*?)", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{S,3089,"/// Build an Objective-C instance message expression.\n///\n/// This routine takes care of both normal instance messages and\n/// instance messages to the superclass instance.\n///\n/// \\param Receiver The expression that computes the object that will\n/// receive this message. This may be empty, in which case we are\n/// sending to the superclass instance and \\p SuperLoc must be a valid\n/// source location.\n///\n/// \\param ReceiverType The (static) type of the object receiving the\n/// message. When a \\p Receiver expression is provided, this is the\n/// same type as that expression. For a superclass instance send, this\n/// is a pointer to the type of the superclass.\n///\n/// \\param SuperLoc The location of the \"super\" keyword in a\n/// superclass instance message.\n///\n/// \\param Sel The selector to which the message is being sent.\n///\n/// \\param Method The method that this instance message is invoking, if\n/// already known.\n///\n/// \\param LBracLoc The location of the opening square bracket \']\'.\n///\n/// \\param RBracLoc The location of the closing square bracket \']\'.\n///\n/// \\param ArgsIn The message arguments.\nExprResult Sema::BuildInstanceMessage(Expr *Receiver, QualType ReceiverType, SourceLocation SuperLoc, Selector Sel, ObjCMethodDecl *Method, SourceLocation LBracLoc, ArrayRef<SourceLocation> SelectorLocs, SourceLocation RBracLoc, MultiExprArg ArgsIn, bool isImplicit) {\n // ...\n if (!Method) {\n // ...\n if (receiverIsIdLike || ReceiverType->isBlockPointerType() || (Receiver && Context.isObjCNSObjectType(Receiver->getType()))) {\n // ...\n } else if (ReceiverType->isObjCClassOrClassKindOfType() || ReceiverType->isObjCQualifiedClassType()) {\n // ...\n } else {\n // ...\n // We allow sending a message to a qualified ID (\"id<foo>\"), which is ok as\n // long as one of the protocols implements the selector (if not, warn).\n // And as long as message is not deprecated/unavailable (warn if it is).\n if (const ObjCObjectPointerType *QIdTy = ReceiverType->getAsObjCQualifiedIdType()) {\n // ...\n } else if (const ObjCObjectPointerType *OCIType = ReceiverType->getAsObjCInterfacePointerType()) {\n // ...\n if (!Method) {\n // ...\n if (!Method && getLangOpts().ObjCAutoRefCount) {\n Diag(SelLoc, diag::err_arc_may_not_respond) << OCIType->getPointeeType() << Sel << RecRange << SourceRange(SelectorLocs.front(), SelectorLocs.back());"}}, [l]={ ["clang/test/SemaObjC/typo-correction-subscript.m"]={"clang/test/SemaObjC/typo-correction-subscript.m:10:9: error: no visible @interface for \'Test\' declares the selector \'undeclaredMethod:\'"} } }, ["err_arc_method_not_found"]={ [c]="err_arc_method_not_found", [d]="no known %select{instance|class}1 method for selector %0", [e]={{nil,nil,{"no known ",{"instance","class"}," method for selector A"}}}, [f]=k, [g]="no known (?:instance|class) method for selector (.*?)", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{S,1743,"bool Sema::CheckMessageArgumentTypes(const Expr *Receiver, QualType ReceiverType, MultiExprArg Args, Selector Sel, ArrayRef<SourceLocation> SelectorLocs, ObjCMethodDecl *Method, bool isClassMessage, bool isSuperMessage, SourceLocation lbrac, SourceLocation rbrac, SourceRange RecRange, QualType &ReturnType, ExprValueKind &VK) {\n // ...\n if (!Method) {\n // ...\n if (getLangOpts().ObjCAutoRefCount)\n DiagID = diag::err_arc_method_not_found;"}}, [l]={ ["clang/test/SemaObjC/method-direct-arc.m"]={"clang/test/SemaObjC/method-direct-arc.m:46:9: error: no known class method for selector \'directMethod\'"} } }, ["err_arc_mismatched_cast"]={ [c]="err_arc_mismatched_cast", [d]="%select{implicit conversion|cast}0 of %select{%2|a non-Objective-C pointer type %2|a block pointer|an Objective-C pointer|an indirect pointer to an Objective-C pointer}1 to %3 is disallowed with ARC", [e]={{nil,nil,{{"implicit conversion","cast"}," of ",{Cb,"a non-Objective-C pointer type C","a block pointer","an Objective-C pointer","an indirect pointer to an Objective-C pointer"}," to D is disallowed with ARC"}}}, [f]=k, [g]="(?:implicit conversion|cast) of (?:(.*?)|a non\\-Objective\\-C pointer type (.*?)|a block pointer|an Objective\\-C pointer|an indirect pointer to an Objective\\-C pointer) to (.*?) is disallowed with ARC", [h]=a, [i]=ob, [b]={G,1308178962,H,F}, [j]={{lb,209,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n // ...\n void rewriteToBridgedCast(CastExpr *E, ObjCBridgeCastKind Kind, Transaction &Trans) {\n // ...\n if (!TA.hasDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, E->getBeginLoc())) {"},{lb,226,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n // ...\n void rewriteToBridgedCast(CastExpr *E, ObjCBridgeCastKind Kind, Transaction &Trans) {\n // ...\n TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, E->getBeginLoc());"},{lb,302,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n // ...\n void rewriteBlockCopyMacro(CastExpr *E) {\n // ...\n Pass.TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, OuterRange);"},{lb,312,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n // ...\n void removeBlockReleaseMacro(CastExpr *E) {\n // ...\n Pass.TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, OuterRange);"},{S,3997,"static void diagnoseObjCARCConversion(Sema &S, SourceRange castRange, QualType castType, ARCConversionTypeClass castACTC, Expr *castExpr, Expr *realCast, ARCConversionTypeClass exprACTC, Sema::CheckedConversionKind CCK) {\n // ...\n S.Diag(loc, diag::err_arc_mismatched_cast) << !convKindForDiag << srcKind << castExprType << castType << castRange << castExpr->getSourceRange();"}}, [l]={ ["clang/test/SemaObjC/arc-type-conversion.m"]={"clang/test/SemaObjC/arc-type-conversion.m:10:9: error: cast of an Objective-C pointer to \'int *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:12:9: error: cast of an Objective-C pointer to \'__autoreleasing id *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:13:9: error: cast of an Objective-C pointer to \'__strong id *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:17:9: error: cast of an Objective-C pointer to \'void **\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:58:9: error: implicit conversion of a non-Objective-C pointer type \'void *\' to \'__strong id *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:59:9: error: implicit conversion of a non-Objective-C pointer type \'void *\' to \'__weak id *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:60:9: error: implicit conversion of a non-Objective-C pointer type \'void *\' to \'__autoreleasing id *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:61:9: error: implicit conversion of a non-Objective-C pointer type \'void *\' to \'__unsafe_unretained id *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:86:9: error: cast of an indirect pointer to an Objective-C pointer to \'id\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:87:9: error: cast of an Objective-C pointer to \'__strong id *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:88:9: error: cast of an indirect pointer to an Objective-C pointer to \'NSString *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:89:9: error: cast of an Objective-C pointer to \'NSString *__strong *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:90:9: error: cast of an indirect pointer to an Objective-C pointer to \'Block\' (aka \'void (^)(void)\') is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:91:9: error: cast of an Objective-C pointer to \'__strong Block *\' (aka \'void (^__strong *)(void)\') is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:106:7: error: implicit conversion of a non-Objective-C pointer type \'struct S *\' to \'__strong id *\' is disallowed with ARC","clang/test/SemaObjC/arc-type-conversion.m:108:7: error: implicit conversion of an indirect pointer to an Objective-C pointer to \'struct S *\' is disallowed with ARC"} } }, ["err_arc_multiple_method_decl"]={ [c]="err_arc_multiple_method_decl", [d]="multiple methods named %0 found with mismatched result, parameter type or attributes", [e]="multiple methods named A found with mismatched result, parameter type or attributes", [f]=k, [g]="multiple methods named (.*?) found with mismatched result, parameter type or attributes", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{ib,3635,"void Sema::DiagnoseMultipleMethodInGlobalPool(SmallVectorImpl<ObjCMethodDecl *> &Methods, Selector Sel, SourceRange R, bool receiverIdOrClass) {\n // ...\n if (issueDiagnostic) {\n if (issueError)\n Diag(R.getBegin(), diag::err_arc_multiple_method_decl) << Sel << R;"}}, [l]={ [nb]={"clang/test/SemaObjC/arc.m:407:3: error: multiple methods named \'test16_1:\' found with mismatched result, parameter type or attributes","clang/test/SemaObjC/arc.m:408:3: error: multiple methods named \'test16_2:\' found with mismatched result, parameter type or attributes","clang/test/SemaObjC/arc.m:409:3: error: multiple methods named \'test16_3:\' found with mismatched result, parameter type or attributes","clang/test/SemaObjC/arc.m:410:3: error: multiple methods named \'test16_4:\' found with mismatched result, parameter type or attributes","clang/test/SemaObjC/arc.m:411:3: error: multiple methods named \'test16_5:\' found with mismatched result, parameter type or attributes"} } }, ["err_arc_new_array_without_ownership"]={ [c]="err_arc_new_array_without_ownership", [d]="\'new\' cannot allocate an array of %0 with no explicit ownership", [e]="\'new\' cannot allocate an array of A with no explicit ownership", [f]=k, [g]="\'new\' cannot allocate an array of (.*?) with no explicit ownership", [h]=a, [i]=J, [b]={jb,1308874139,fb,kb}, [j]={{D,2483,"/// Checks that a type is suitable as the allocated type\n/// in a new-expression.\nbool Sema::CheckAllocatedType(QualType AllocType, SourceLocation Loc, SourceRange R) {\n // C++ 5.3.4p1: \"[The] type shall be a complete object type, but not an\n // abstract class type or array thereof.\n if (AllocType->isFunctionType())\n // ...\n else if (AllocType->isReferenceType())\n // ...\n else if (!AllocType->isDependentType() && RequireCompleteSizedType(Loc, AllocType, diag::err_new_incomplete_or_sizeless_type, R))\n // ...\n else if (RequireNonAbstractType(Loc, AllocType, diag::err_allocation_of_abstract_type))\n // ...\n else if (AllocType->isVariablyModifiedType())\n // ...\n else if (AllocType.getAddressSpace() != LangAS::Default && !getLangOpts().OpenCLCPlusPlus)\n // ...\n else if (getLangOpts().ObjCAutoRefCount) {\n if (const ArrayType *AT = Context.getAsArrayType(AllocType)) {\n // ...\n if (BaseAllocType.getObjCLifetime() == Qualifiers::OCL_None && BaseAllocType->isObjCLifetimeType())\n return Diag(Loc, diag::err_arc_new_array_without_ownership) << BaseAllocType;"}} }, ["err_arc_nolifetime_behavior"]={ [c]="err_arc_nolifetime_behavior", [d]="explicit ownership qualifier on cast result has no effect", [e]="explicit ownership qualifier on cast result has no effect", [f]=k, [g]="explicit ownership qualifier on cast result has no effect", [h]=a, [i]=ob, [b]={"2fa646d59623",1319832367,"objective-c arc: type-casting of an objc pointer to","objective-c arc: type-casting of an objc pointer to\nan rvalue retainable object type with life-time qualifier has no\neffect and wil be diagnosed as error. // rdar://10244607\n\nllvm-svn: 143219"}, [j]={{S,4426,"Sema::ARCConversionResult Sema::CheckObjCConversion(SourceRange castRange, QualType castType, Expr *&castExpr, CheckedConversionKind CCK, bool Diagnose, bool DiagnoseCFAudited, BinaryOperatorKind Opc) {\n // ...\n if (exprACTC == castACTC) {\n // Check for viability and report error if casting an rvalue to a\n // life-time qualifier.\n if (castACTC == ACTC_retainable && (CCK == CCK_CStyleCast || CCK == CCK_OtherCast) && castType != castExprType) {\n // ...\n if (QDT != castType && QDT.getObjCLifetime() != Qualifiers::OCL_None) {\n if (Diagnose) {\n // ...\n Diag(loc, diag::err_arc_nolifetime_behavior);"}}, [l]={ ["clang/test/SemaObjCXX/arc-objc-lifetime.mm"]={"clang/test/SemaObjCXX/arc-objc-lifetime.mm:19:30: error: explicit ownership qualifier on cast result has no effect","clang/test/SemaObjCXX/arc-objc-lifetime.mm:22:30: error: explicit ownership qualifier on cast result has no effect","clang/test/SemaObjCXX/arc-objc-lifetime.mm:26:30: error: explicit ownership qualifier on cast result has no effect"} } }, ["err_arc_nonlocal_writeback"]={ [c]="err_arc_nonlocal_writeback", [d]="passing address of %select{non-local|non-scalar}0 object to __autoreleasing parameter for write-back", [e]={{nil,nil,{"passing address of ",{"non-local","non-scalar"}," object to __autoreleasing parameter for write-back"}}}, [f]=k, [g]="passing address of (?:non\\-local|non\\-scalar) object to __autoreleasing parameter for write\\-back", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{L,5948,"/// Check whether the given expression is a valid operand for an\n/// indirect copy/restore.\nstatic void checkIndirectCopyRestoreSource(Sema &S, Expr *src) {\n // ...\n S.Diag(src->getExprLoc(), diag::err_arc_nonlocal_writeback) << ((unsigned)iik - 1) // shift index into diagnostic explanations"}}, [l]={ ["clang/test/SemaObjCXX/arc-overloading.mm"]={"clang/test/SemaObjCXX/arc-overloading.mm:85:17: error: passing address of non-local object to __autoreleasing parameter for write-back"} } }, ["err_arc_objc_property_default_assign_on_object"]={ [c]="err_arc_objc_property_default_assign_on_object", [d]="ARC forbids synthesizing a property of an Objective-C object with unspecified ownership or storage attribute", [e]="ARC forbids synthesizing a property of an Objective-C object with unspecified ownership or storage attribute", [f]=k, [g]="ARC forbids synthesizing a property of an Objective\\-C object with unspecified ownership or storage attribute", [h]=a, [i]=ob, [b]={G,1308178962,H,F}, [j]={{cb,266,"class PropertiesRewriter {\n // ...\n void maybeAddWeakOrUnsafeUnretainedAttr(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n // ...\n if (I->ImplD) {\n // ...\n Pass.TA.clearDiagnostic(diag::err_arc_objc_property_default_assign_on_object, I->ImplD->getLocation());"},{mb,1306,"/// ActOnPropertyImplDecl - This routine performs semantic checks and\n/// builds the AST node for a property implementation declaration; declared\n/// as \\@synthesize or \\@dynamic.\n///\nDecl *Sema::ActOnPropertyImplDecl(Scope *S, SourceLocation AtLoc, SourceLocation PropertyLoc, bool Synthesize, IdentifierInfo *PropertyId, IdentifierInfo *PropertyIvar, SourceLocation PropertyIvarLoc, ObjCPropertyQueryKind QueryKind) {\n // ...\n // Check that we have a valid, previously declared ivar for @synthesize\n if (Synthesize) {\n // ...\n if (!Ivar) {\n // In ARC, give the ivar a lifetime qualifier based on the\n // property attributes.\n if ((getLangOpts().ObjCAutoRefCount || isARCWeak) && !PropertyIvarType.getObjCLifetime() && PropertyIvarType->isObjCRetainableType()) {\n // It\'s an error if we have to do this and the user didn\'t\n // explicitly write an ownership attribute on the property.\n if (!hasWrittenStorageAttribute(property, QueryKind) && !(kind & ObjCPropertyAttribute::kind_strong)) {\n Diag(PropertyDiagLoc, diag::err_arc_objc_property_default_assign_on_object);"}} }, ["err_arc_perform_selector_retains"]={ [c]="err_arc_perform_selector_retains", [d]="performSelector names a selector which retains the object", [e]="performSelector names a selector which retains the object", [f]=k, [g]="performSelector names a selector which retains the object", [h]=a, [i]=m, [b]={"b7a773626fea",1309905539,"objc-arc: enforce performSelector rules in rejecting retaining selectors","objc-arc: enforce performSelector rules in rejecting retaining selectors\npassed to it, and unknown selectors causing potential leak.\n// rdar://9659270\n\nllvm-svn: 134449"}, [j]={{S,3297,"/// Build an Objective-C instance message expression.\n///\n/// This routine takes care of both normal instance messages and\n/// instance messages to the superclass instance.\n///\n/// \\param Receiver The expression that computes the object that will\n/// receive this message. This may be empty, in which case we are\n/// sending to the superclass instance and \\p SuperLoc must be a valid\n/// source location.\n///\n/// \\param ReceiverType The (static) type of the object receiving the\n/// message. When a \\p Receiver expression is provided, this is the\n/// same type as that expression. For a superclass instance send, this\n/// is a pointer to the type of the superclass.\n///\n/// \\param SuperLoc The location of the \"super\" keyword in a\n/// superclass instance message.\n///\n/// \\param Sel The selector to which the message is being sent.\n///\n/// \\param Method The method that this instance message is invoking, if\n/// already known.\n///\n/// \\param LBracLoc The location of the opening square bracket \']\'.\n///\n/// \\param RBracLoc The location of the closing square bracket \']\'.\n///\n/// \\param ArgsIn The message arguments.\nExprResult Sema::BuildInstanceMessage(Expr *Receiver, QualType ReceiverType, SourceLocation SuperLoc, Selector Sel, ObjCMethodDecl *Method, SourceLocation LBracLoc, ArrayRef<SourceLocation> SelectorLocs, SourceLocation RBracLoc, MultiExprArg ArgsIn, bool isImplicit) {\n // ...\n // In ARC, forbid the user from sending messages to\n // retain/release/autorelease/dealloc/retainCount explicitly.\n if (getLangOpts().ObjCAutoRefCount) {\n // ...\n case OMF_performSelector:\n if (Method && NumArgs >= 1) {\n if (const auto *SelExp = dyn_cast<ObjCSelectorExpr>(Args[0]->IgnoreParens())) {\n // ...\n if (SelMethod) {\n // ...\n case OMF_alloc:\n case OMF_copy:\n case OMF_mutableCopy:\n case OMF_new:\n case OMF_init:\n // Issue error, unless ns_returns_not_retained.\n if (!SelMethod->hasAttr<NSReturnsNotRetainedAttr>()) {\n // ...\n Diag(SelLoc, diag::err_arc_perform_selector_retains);"},{S,3307,"/// Build an Objective-C instance message expression.\n///\n/// This routine takes care of both normal instance messages and\n/// instance messages to the superclass instance.\n///\n/// \\param Receiver The expression that computes the object that will\n/// receive this message. This may be empty, in which case we are\n/// sending to the superclass instance and \\p SuperLoc must be a valid\n/// source location.\n///\n/// \\param ReceiverType The (static) type of the object receiving the\n/// message. When a \\p Receiver expression is provided, this is the\n/// same type as that expression. For a superclass instance send, this\n/// is a pointer to the type of the superclass.\n///\n/// \\param SuperLoc The location of the \"super\" keyword in a\n/// superclass instance message.\n///\n/// \\param Sel The selector to which the message is being sent.\n///\n/// \\param Method The method that this instance message is invoking, if\n/// already known.\n///\n/// \\param LBracLoc The location of the opening square bracket \']\'.\n///\n/// \\param RBracLoc The location of the closing square bracket \']\'.\n///\n/// \\param ArgsIn The message arguments.\nExprResult Sema::BuildInstanceMessage(Expr *Receiver, QualType ReceiverType, SourceLocation SuperLoc, Selector Sel, ObjCMethodDecl *Method, SourceLocation LBracLoc, ArrayRef<SourceLocation> SelectorLocs, SourceLocation RBracLoc, MultiExprArg ArgsIn, bool isImplicit) {\n // ...\n // In ARC, forbid the user from sending messages to\n // retain/release/autorelease/dealloc/retainCount explicitly.\n if (getLangOpts().ObjCAutoRefCount) {\n // ...\n case OMF_performSelector:\n if (Method && NumArgs >= 1) {\n if (const auto *SelExp = dyn_cast<ObjCSelectorExpr>(Args[0]->IgnoreParens())) {\n // ...\n if (SelMethod) {\n // ...\n default:\n // +0 call. OK. unless ns_returns_retained.\n if (SelMethod->hasAttr<NSReturnsRetainedAttr>()) {\n // ...\n Diag(SelLoc, diag::err_arc_perform_selector_retains);"}}, [l]={ ["clang/test/SemaObjC/arc-peformselector.m"]={"clang/test/SemaObjC/arc-peformselector.m:28:16: error: performSelector names a selector which retains the object","clang/test/SemaObjC/arc-peformselector.m:29:16: error: performSelector names a selector which retains the object","clang/test/SemaObjC/arc-peformselector.m:30:16: error: performSelector names a selector which retains the object","clang/test/SemaObjC/arc-peformselector.m:37:16: error: performSelector names a selector which retains the object"} } }, ["err_arc_pseudo_dtor_inconstant_quals"]={ [c]="err_arc_pseudo_dtor_inconstant_quals", [d]="pseudo-destructor destroys object of type %0 with inconsistently-qualified type %1", [e]="pseudo-destructor destroys object of type A with inconsistently-qualified type B", [f]=k, [g]="pseudo\\-destructor destroys object of type (.*?) with inconsistently\\-qualified type (.*?)", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{D,7822,"ExprResult Sema::BuildPseudoDestructorExpr(Expr *Base, SourceLocation OpLoc, tok::TokenKind OpKind, const CXXScopeSpec &SS, TypeSourceInfo *ScopeTypeInfo, SourceLocation CCLoc, SourceLocation TildeLoc, PseudoDestructorTypeStorage Destructed) {\n // ...\n // C++ [expr.pseudo]p2:\n // [...] The cv-unqualified versions of the object type and of the type\n // designated by the pseudo-destructor-name shall be the same type.\n if (DestructedTypeInfo) {\n // ...\n if (!DestructedType->isDependentType() && !ObjectType->isDependentType()) {\n if (!Context.hasSameUnqualifiedType(DestructedType, ObjectType)) {\n // ...\n } else if (DestructedType.getObjCLifetime() != ObjectType.getObjCLifetime()) {\n if (DestructedType.getObjCLifetime() == Qualifiers::OCL_None) {\n // ...\n } else {\n Diag(DestructedTypeStart, diag::err_arc_pseudo_dtor_inconstant_quals) << ObjectType << DestructedType << Base->getSourceRange() << DestructedTypeInfo->getTypeLoc().getSourceRange();"}} }, ["err_arc_receiver_forward_class"]={ [c]="err_arc_receiver_forward_class", [d]="receiver %0 for class message is a forward declaration", [e]="receiver A for class message is a forward declaration", [f]=k, [g]="receiver (.*?) for class message is a forward declaration", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{S,2663,"/// \\param ReceiverType The type of the object receiving the\n/// message. When \\p ReceiverTypeInfo is non-NULL, this is the same\n/// type as that refers to. For a superclass send, this is the type of\n/// the superclass.\n///\n/// \\param SuperLoc The location of the \"super\" keyword in a\n/// superclass message.\n///\n/// \\param Sel The selector to which the message is being sent.\n///\n/// \\param Method The method that this class message is invoking, if\n/// already known.\n///\n/// \\param LBracLoc The location of the opening square bracket \']\'.\n///\n/// \\param RBracLoc The location of the closing square bracket \']\'.\n///\n/// \\param ArgsIn The message arguments.\nExprResult Sema::BuildClassMessage(TypeSourceInfo *ReceiverTypeInfo, QualType ReceiverType, SourceLocation SuperLoc, Selector Sel, ObjCMethodDecl *Method, SourceLocation LBracLoc, ArrayRef<SourceLocation> SelectorLocs, SourceLocation RBracLoc, MultiExprArg ArgsIn, bool isImplicit) {\n // ...\n // Find the method we are messaging.\n if (!Method) {\n // ...\n if (RequireCompleteType(Loc, Context.getObjCInterfaceType(Class), (getLangOpts().ObjCAutoRefCount ? diag::err_arc_receiver_forward_class : diag::warn_receiver_forward_class), TypeRange)) {"}}, [l]={ [nb]={"clang/test/SemaObjC/arc.m:427:4: error: receiver \'Test17\' for class message is a forward declaration"} } }, ["err_arc_receiver_forward_instance"]={ [c]="err_arc_receiver_forward_instance", [d]="receiver type %0 for instance message is a forward declaration", [e]="receiver type A for instance message is a forward declaration", [f]=k, [g]="receiver type (.*?) for instance message is a forward declaration", [h]=a, [i]=J, [b]={G,1308178962,H,F}, [j]={{S,3066,"/// Build an Objective-C instance message expression.\n///\n/// This routine takes care of both normal instance messages and\n/// instance messages to the superclass instance.\n///\n/// \\param Receiver The expression that computes the object that will\n/// receive this message. This may be empty, in which case we are\n/// sending to the superclass instance and \\p SuperLoc must be a valid\n/// source location.\n///\n/// \\param ReceiverType The (static) type of the object receiving the\n/// message. When a \\p Receiver expression is provided, this is the\n/// same type as that expression. For a superclass instance send, this\n/// is a pointer to the type of the superclass.\n///\n/// \\param SuperLoc The location of the \"super\" keyword in a\n/// superclass instance message.\n///\n/// \\param Sel The selector to which the message is being sent.\n///\n/// \\param Method The method that this instance message is invoking, if\n/// already known.\n///\n/// \\param LBracLoc The location of the opening square bracket \']\'.\n///\n/// \\param RBracLoc The location of the closing square bracket \']\'.\n///\n/// \\param ArgsIn The message arguments.\nExprResult Sema::BuildInstanceMessage(Expr *Receiver, QualType ReceiverType, SourceLocation SuperLoc, Selector Sel, ObjCMethodDecl *Method, SourceLocation LBracLoc, ArrayRef<SourceLocation> SelectorLocs, SourceLocation RBracLoc, MultiExprArg ArgsIn, bool isImplicit) {\n // ...\n if (!Method) {\n // ...\n if (receiverIsIdLike || ReceiverType->isBlockPointerType() || (Receiver && Context.isObjCNSObjectType(Receiver->getType()))) {\n // ...\n } else if (ReceiverType->isObjCClassOrClassKindOfType() || ReceiverType->isObjCQualifiedClassType()) {\n // ...\n } else {\n // ...\n // We allow sending a message to a qualified ID (\"id<foo>\"), which is ok as\n // long as one of the protocols implements the selector (if not, warn).\n // And as long as message is not deprecated/unavailable (warn if it is).\n if (const ObjCObjectPointerType *QIdTy = ReceiverType->getAsObjCQualifiedIdType()) {\n // ...\n } else if (const ObjCObjectPointerType *OCIType = ReceiverType->getAsObjCInterfacePointerType()) {\n // ...\n if (RequireCompleteType(Loc, OCIType->getPointeeType(), getLangOpts().ObjCAutoRefCount ? diag::err_arc_receiver_forward_instance : diag::warn_receiver_forward_instance, RecRange)) {"}}, [l]={ [nb]={"clang/test/SemaObjC/arc.m:422:4: error: receiver type \'Test17\' for instance message is a forward declaration","clang/test/SemaObjC/arc.m:425:4: error: receiver type \'Test17<Test17p>\' for instance message is a forward declaration"} } }, ["err_arc_strong_property_ownership"]={ [c]="err_arc_strong_property_ownership", [d]="existing instance variable %1 for strong property %0 may not be %select{|__unsafe_unretained||__weak}2", [e]={{nil,nil,{"existing instance variable B for strong property A may not be ",{a,"__unsafe_unretained",a,"__weak"}}}}, [f]=k, [g]="existing instance variable (.*?) for strong property (.*?) may not be (?:|__unsafe_unretained||__weak)", [h]=a, [i]="ARC and @properties", [b]={jb,1308874139,fb,kb}, [j]={{cb,207,"class PropertiesRewriter {\n // ...\n void removeAssignForDefaultStrong(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n if (I->ImplD)\n Pass.TA.clearDiagnostic(diag::err_arc_strong_property_ownership, diag::err_arc_assign_property_ownership, diag::err_arc_inconsistent_property_ownership, I->IvarD->getLocation());"},{cb,236,"class PropertiesRewriter {\n // ...\n void rewriteAssign(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n // ...\n if (I->ImplD)\n Pass.TA.clearDiagnostic(diag::err_arc_strong_property_ownership, diag::err_arc_assign_property_ownership, diag::err_arc_inconsistent_property_ownership, I->IvarD->getLocation());"},{cb,261,"class PropertiesRewriter {\n // ...\n void maybeAddWeakOrUnsafeUnretainedAttr(PropsTy &props, SourceLocation atLoc) const {\n // ...\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n // ...\n if (I->ImplD) {\n Pass.TA.clearDiagnostic(diag::err_arc_strong_property_ownership, diag::err_arc_assign_property_ownership, diag::err_arc_inconsistent_property_ownership, I->IvarD->getLocation());"},{mb,764,"static void checkARCPropertyImpl(Sema &S, SourceLocation propertyImplLoc, ObjCPropertyDecl *property, ObjCIvarDecl *ivar) {\n // ...\n case Qualifiers::OCL_Strong:\n S.Diag(ivar->getLocation(), diag::err_arc_strong_property_ownership) << property->getDeclName() << ivar->getDeclName() << ivarLifetime;"}}, [l]={ ["clang/test/SemaObjC/arc-property-lifetime.m"]={"clang/test/SemaObjC/arc-property-lifetime.m:6:28: error: existing instance variable \'x\' for strong property \'x\' may not be __unsafe_unretained","clang/test/SemaObjC/arc-property-lifetime.m:23:28: error: existing instance variable \'x\' for strong property \'x\' may not be __unsafe_unretained","clang/test/SemaObjC/arc-property-lifetime.m:40:28: error: existing instance variable \'x\' for strong property \'x\' may not be __unsafe_unretained"} } }, ["err_arc_thread_ownership"]={ [c]="err_arc_thread_ownership", [d]="thread-local variable has non-trivial ownership: type is %0", [e]="thread-local variable has non-trivial ownership: type is A", [f]=k, [g]="thread\\-local variable has non\\-trivial ownership\\: type is (.*?)", [h]=a, [i]=J, [b]={jb,1308874139,fb,kb}, [j]={{o,6893,"bool Sema::inferObjCARCLifetime(ValueDecl *decl) {\n // ...\n if (VarDecl *var = dyn_cast<VarDecl>(decl)) {\n // Thread-local variables cannot have lifetime.\n if (lifetime && lifetime != Qualifiers::OCL_ExplicitNone && var->getTLSKind()) {\n Diag(var->getLocation(), diag::err_arc_thread_ownership) << var->getType();"}}, [l]={ [nb]={"clang/test/SemaObjC/arc.m:448:20: error: thread-local variable has non-trivial ownership: type is \'__strong id\'","clang/test/SemaObjC/arc.m:449:29: error: thread-local variable has non-trivial ownership: type is \'__strong id\'","clang/test/SemaObjC/arc.m:450:27: error: thread-local variable has non-trivial ownership: type is \'__weak id\'","clang/test/SemaObjC/arc.m:451:36: error: thread-local variable has non-trivial ownership: type is \'__autoreleasing id\'","clang/test/SemaObjC/arc.m:454:22: error: thread-local variable has non-trivial ownership: type is \'__strong id\'","clang/test/SemaObjC/arc.m:455:31: error: thread-local variable has non-trivial ownership: type is \'__strong id\'","clang/test/SemaObjC/arc.m:456:29: error: thread-local variable has non-trivial ownership: type is \'__weak id\'","clang/test/SemaObjC/arc.m:457:38: error: thread-local variable has non-trivial ownership: type is \'__autoreleasing id\'"} } }, ["err_arc_typecheck_convert_incompatible_pointer"]={ [c]="err_arc_typecheck_convert_incompatible_pointer", [d]="incompatible pointer types passing retainable parameter of type %0to a CF function expecting %1 type", [e]="incompatible pointer types passing retainable parameter of type Ato a CF function expecting B type", [f]=k, [g]="incompatible pointer types passing retainable parameter of type (.*?)to a CF function expecting (.*?) type", [h]=a, [i]=m, [b]={"3a25d0d59395",1375312774,"ObjectiveC ARC: finishing off issuing error when","ObjectiveC ARC: finishing off issuing error when\nretainable pointer is passed to an audited CF function\nexpecting CF type. // rdar://14569171\n\nllvm-svn: 187543"}, [j]={{Y,17563,"bool Sema::DiagnoseAssignmentResult(AssignConvertType ConvTy, SourceLocation Loc, QualType DstType, QualType SrcType, Expr *SrcExpr, AssignmentAction Action, bool *Complained) {\n // ...\n case IncompatiblePointer:\n if (Action == AA_Passing_CFAudited) {\n DiagKind = diag::err_arc_typecheck_convert_incompatible_pointer;"}}, [l]={ ["clang/test/SemaObjC/arc-cf.m"]={"clang/test/SemaObjC/arc-cf.m:58:35: error: incompatible pointer types passing retainable parameter of type \'NSString *__strong\'to a CF function expecting \'CFStringRef\' (aka \'const struct __CFString *\') type"} } }, ["err_arc_unsupported_on_runtime"]={ [c]="err_arc_unsupported_on_runtime", [d]="-fobjc-arc is not supported on platforms using the legacy runtime", [e]="-fobjc-arc is not supported on platforms using the legacy runtime", [f]=k, [g]="\\-fobjc\\-arc is not supported on platforms using the legacy runtime", [h]=a, [i]=W, [b]={"3deb1ad40ca6",1345517263,"Screw around with ObjCRuntime some more, changing the","Screw around with ObjCRuntime some more, changing the\ndiagnostics for bad deployment targets and adding a few\nmore predicates. Includes a patch by Jonathan Schleifer\nto enable ARC for ObjFW.\n\nllvm-svn: 162252"}, [j]={{bb,3665,"#include \"clang/Driver/Options.inc\"\n // ...\n if (Opts.ObjC) {\n // ...\n if (Args.hasArg(OPT_fobjc_gc_only))\n // ...\n else if (Args.hasArg(OPT_fobjc_gc))\n // ...\n else if (Args.hasArg(OPT_fobjc_arc)) {\n // ...\n if (!Opts.ObjCRuntime.allowsARC())\n Diags.Report(diag::err_arc_unsupported_on_runtime);"}} }, ["err_arc_unsupported_on_toolchain"]={ [c]="err_arc_unsupported_on_toolchain", [d]="-fobjc-arc is not supported on versions of OS X prior to 10.6", [e]="-fobjc-arc is not supported on versions of OS X prior to 10.6", [f]=k, [g]="\\-fobjc\\-arc is not supported on versions of OS X prior to 10\\.6", [h]=a, [i]=W, [b]={"3deb1ad40ca6",1345517263,"Screw around with ObjCRuntime some more, changing the","Screw around with ObjCRuntime some more, changing the\ndiagnostics for bad deployment targets and adding a few\nmore predicates. Includes a patch by Jonathan Schleifer\nto enable ARC for ObjFW.\n\nllvm-svn: 162252"}, [j]={{"clang/lib/Driver/ToolChains/Darwin.cpp",3295,"void Darwin::CheckObjCARC() const {\n // ...\n getDriver().Diag(diag::err_arc_unsupported_on_toolchain);"}} }, ["err_arc_unsupported_weak_class"]={ [c]="err_arc_unsupported_weak_class", [d]="class is incompatible with __weak references", [e]="class is incompatible with __weak references", [f]=k, [g]="class is incompatible with __weak references", [h]=a, [i]=wb, [b]={"1f626d6fd1ca",1309980245,"objc-arc: Support objc_arc_weak_unavailable on those","objc-arc: Support objc_arc_weak_unavailable on those\nclasses which are incompatible with weak references.\n// rdar://9693477\n\nllvm-svn: 134522"}, [j]={{"clang/lib/ARCMigrate/TransGCAttrs.cpp",211,"static void checkWeakGCAttrs(MigrationContext &MigrateCtx) {\n // ...\n for (unsigned i = 0, e = MigrateCtx.GCAttrs.size(); i != e; ++i) {\n // ...\n if (Attr.Kind == MigrationContext::GCAttrOccurrence::Weak) {\n // ...\n if (!canApplyWeak(MigrateCtx.Pass.Ctx, Attr.ModifiedType,\n // ...\n TA.clearDiagnostic(diag::err_arc_weak_no_runtime, diag::err_arc_unsupported_weak_class, Attr.Loc);"},{p,7074,"/// handleObjCOwnershipTypeAttr - Process an objc_ownership\n/// attribute on the specified type.\n///\n/// Returns \'true\' if the attribute was handled.\nstatic bool handleObjCOwnershipTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n // ...\n // Forbid __weak for class objects marked as\n // objc_arc_weak_reference_unavailable\n if (lifetime == Qualifiers::OCL_Weak) {\n if (const ObjCObjectPointerType *ObjT = type->getAs<ObjCObjectPointerType>()) {\n if (ObjCInterfaceDecl *Class = ObjT->getInterfaceDecl()) {\n if (Class->isArcWeakrefUnavailable()) {\n S.Diag(AttrLoc, diag::err_arc_unsupported_weak_class);"}}, [l]={ ["clang/test/SemaObjCXX/objc-weak.mm"]={"clang/test/SemaObjCXX/objc-weak.mm:21:34: error: class is incompatible with __weak references","clang/test/SemaObjCXX/objc-weak.mm:25:29: error: class is incompatible with __weak references"} } }, ["err_arc_unused_init_message"]={ [c]="err_arc_unused_init_message", [d]="the result of a delegate init call must be immediately returned or assigned to \'self\'", [e]="the result of a delegate init call must be immediately returned or assigned to \'self\'", [f]=k, [g]="the result of a delegate init call must be immediately returned or assigned to \'self\'", [h]=a, [i]=ob, [b]={G,1308178962,H,F}, [j]={{"clang/lib/ARCMigrate/TransUnusedInitDelegate.cpp",53,"class UnusedInitRewriter : public RecursiveASTVisitor<UnusedInitRewriter> {\n // ...\n bool VisitObjCMessageExpr(ObjCMessageExpr *ME) {\n if (ME->isDelegateInitCall() && isRemovable(ME) && Pass.TA.hasDiagnostic(diag::err_arc_unused_init_message, ME->getExprLoc())) {"},{"clang/lib/ARCMigrate/TransUnusedInitDelegate.cpp",56,"class UnusedInitRewriter : public RecursiveASTVisitor<UnusedInitRewriter> {\n // ...\n bool VisitObjCMessageExpr(ObjCMessageExpr *ME) {\n if (ME->isDelegateInitCall() && isRemovable(ME) && Pass.TA.hasDiagnostic(diag::err_arc_unused_init_message, ME->getExprLoc())) {\n // ...\n Pass.TA.clearDiagnostic(diag::err_arc_unused_init_message, ME->getExprLoc());"},{"clang/lib/Sema/SemaStmt.cpp",328,"void Sema::DiagnoseUnusedExprResult(const Stmt *S, unsigned DiagID) {\n // ...\n if (const ObjCMessageExpr *ME = dyn_cast<ObjCMessageExpr>(E)) {\n if (getLangOpts().ObjCAutoRefCount && ME->isDelegateInitCall()) {\n Diag(Loc, diag::err_arc_unused_init_message) << R1;"}}, [l]={ [nb]={"clang/test/SemaObjC/arc.m:528:3: error: the result of a delegate init call must be immediately returned or assigned to \'self\'"} } }, ["err_arc_weak_disabled"]={ [c]="err_arc_weak_disabled", [d]="cannot create __weak reference in file using manual reference counting", [e]="cannot create __weak reference in file using manual reference counting", [f]=k, [g]="cannot create __weak reference in file using manual reference counting", [h]=a, [i]=wb, [b]={"460ce58fa6a1",1445539097,"Define weak and __weak to mean ARC-style weak references, even in MRC.","Define weak and __weak to mean ARC-style weak references, even in MRC.\n\nPreviously, __weak was silently accepted and ignored in MRC mode.\nThat makes this a potentially source-breaking change that we have to\nroll out cautiously. Accordingly, for the time being, actual support\nfor __weak references in MRC is experimental, and the compiler will\nreject attempts to actually form such references. The intent is to\neventually enable the feature by default in all non-GC modes.\n(It is, of course, incompatible with ObjC GC\'s interpretation of\n__weak.)\n\nIf you like, you can enable this feature with\n -Xclang -fobjc-weak\nbut like any -Xclang option, this option may be removed at any point,\ne.g. if/when it is eventually enabled by default.\n\nThis patch also enables the use of the ARC __unsafe_unretained qualifier\nin MRC. Unlike __weak, this is being enabled immediately. Since\nvariables are essentially __unsafe_unretained by default in MRC,\nthe only practical uses are (1) communication and (2) changing the\ndefault behavior of by-value block capture.\n\nAs an implementation matter, this means that the ObjC ownership\nqualifiers may appear in any ObjC language mode, and so this patch\nremoves a number of checks for getLangOpts().ObjCAutoRefCount\nthat were guarding the processing of these qualifiers. I don\'t\nexpect this to be a significant drain on performance; it may even\nbe faster to just check for these qualifiers directly on a type\n(since it\'s probably in a register anyway) than to do N dependent\nloads to grab the LangOptions.\n\nrdar://9674298\n\nllvm-svn: 251041"}, [j]={{n,9802,"/// Is the given declaration allowed to use a forbidden type?\n/// If so, it\'ll still be annotated with an attribute that makes it\n/// illegal to actually use.\nstatic bool isForbiddenTypeAllowed(Sema &S, Decl *D, const DelayedDiagnostic &diag, UnavailableAttr::ImplicitReason &reason) {\n // ...\n // Silently accept unsupported uses of __weak in both user and system\n // declarations when it\'s been disabled, for ease of integration with\n // -fno-objc-arc files. We do have to take some care against attempts\n // to define such things; for now, we\'ve only done that for ivars\n // and properties.\n if ((isa<ObjCIvarDecl>(D) || isa<ObjCPropertyDecl>(D))) {\n if (diag.getForbiddenTypeDiagnostic() == diag::err_arc_weak_disabled || diag.getForbiddenTypeDiagnostic() == diag::err_arc_weak_no_runtime) {"},{ib,3794,"/// Diagnose attempts to define ARC-__weak ivars when __weak is disabled.\nstatic void DiagnoseWeakIvars(Sema &S, ObjCImplementationDecl *ID) {\n // ...\n for (auto ivar = ID->getClassInterface()->all_declared_ivar_begin(); ivar; ivar = ivar->getNextIvar()) {\n // ...\n if (ivar->getType().getObjCLifetime() == Qualifiers::OCL_Weak) {\n if (S.getLangOpts().ObjCWeakRuntime) {\n S.Diag(ivar->getLocation(), diag::err_arc_weak_disabled);"},{p,7057,"/// handleObjCOwnershipTypeAttr - Process an objc_ownership\n/// attribute on the specified type.\n///\n/// Returns \'true\' if the attribute was handled.\nstatic bool handleObjCOwnershipTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n // ...\n // Sometimes, __weak isn\'t allowed.\n if (lifetime == Qualifiers::OCL_Weak && !S.getLangOpts().ObjCWeak && !NonObjCPointer) {\n // ...\n unsigned diagnostic = (S.getLangOpts().ObjCWeakRuntime ? diag::err_arc_weak_disabled : diag::err_arc_weak_no_runtime);"}}, [l]={ ["clang/test/SemaObjC/mrc-no-weak.m"]={"clang/test/SemaObjC/mrc-no-weak.m:15:13: error: cannot create __weak reference in file using manual reference counting"} } }, ["err_arc_weak_ivar_access"]={ [c]="err_arc_weak_ivar_access", [d]="dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first", [e]="dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first", [f]=k, [g]="dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first", [h]=a, [i]=m, [b]={"f881267db9a9",1480718311,"Mass-rename the handful of error_* diagnostics to err_*.","Mass-rename the handful of error_* diagnostics to err_*.\n\nllvm-svn: 288545"}, [j]={{"clang/lib/Sema/SemaExprMember.cpp",1462,"/// Look up the given member of the given non-type-dependent\n/// expression. This can return in one of two ways:\n/// * If it returns a sentinel null-but-valid result, the caller will\n/// assume that lookup was performed and the results written into\n/// the provided structure. It will take over from there.\n/// * Otherwise, the returned expression will be produced in place of\n/// an ordinary member expression.\n///\n/// The ObjCImpDecl bit is a gross hack that will need to be properly\n/// fixed for ObjC++.\nstatic ExprResult LookupMemberExpr(Sema &S, LookupResult &R, ExprResult &BaseExpr, bool &IsArrow, SourceLocation OpLoc, CXXScopeSpec &SS, Decl *ObjCImpDecl, bool HasTemplateArgs, SourceLocation TemplateKWLoc) {\n // ...\n // Handle ivar access to Objective-C objects.\n if (const ObjCObjectType *OTy = BaseType->getAs<ObjCObjectType>()) {\n // ...\n if (S.getLangOpts().ObjCWeak) {\n // ...\n if (DeclRefExpr *DE = dyn_cast<DeclRefExpr>(BaseExp))\n if (DE->getType().getObjCLifetime() == Qualifiers::OCL_Weak) {\n S.Diag(DE->getLocation(), diag::err_arc_weak_ivar_access);"}}, [l]={ ["clang/test/SemaObjC/warn-direct-ivar-access.m"]={"clang/test/SemaObjC/warn-direct-ivar-access.m:52:3: error: dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first","clang/test/SemaObjC/warn-direct-ivar-access.m:53:14: error: dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first","clang/test/SemaObjC/warn-direct-ivar-access.m:54:16: error: dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first"} } }, ["err_arc_weak_no_runtime"]={ [c]="err_arc_weak_no_runtime", [d]="cannot create __weak reference because the current deployment target does not support weak references", [e]="cannot create __weak reference because the current deployment target does not support weak references", [f]=k, [g]="cannot create __weak reference because the current deployment target does not support weak references", [h]=a, [i]=wb, [b]={G,1308178962,H,F}, [j]={{"clang/lib/ARCMigrate/TransGCAttrs.cpp",210,"static void checkWeakGCAttrs(MigrationContext &MigrateCtx) {\n // ...\n for (unsigned i = 0, e = MigrateCtx.GCAttrs.size(); i != e; ++i) {\n // ...\n if (Attr.Kind == MigrationContext::GCAttrOccurrence::Weak) {\n // ...\n if (!canApplyWeak(MigrateCtx.Pass.Ctx, Attr.ModifiedType,\n // ...\n TA.clearDiagnostic(diag::err_arc_weak_no_runtime, diag::err_arc_unsupported_weak_class, Attr.Loc);"},{n,9803,"/// Is the given declaration allowed to use a forbidden type?\n/// If so, it\'ll still be annotated with an attribute that makes it\n/// illegal to actually use.\nstatic bool isForbiddenTypeAllowed(Sema &S, Decl *D, const DelayedDiagnostic &diag, UnavailableAttr::ImplicitReason &reason) {\n // ...\n // Silently accept unsupported uses of __weak in both user and system\n // declarations when it\'s been disabled, for ease of integration with\n // -fno-objc-arc files. We do have to take some care against attempts\n // to define such things; for now, we\'ve only done that for ivars\n // and properties.\n if ((isa<ObjCIvarDecl>(D) || isa<ObjCPropertyDecl>(D))) {\n if (diag.getForbiddenTypeDiagnostic() == diag::err_arc_weak_disabled || diag.getForbiddenTypeDiagnostic() == diag::err_arc_weak_no_runtime) {"},{ib,3796,"/// Diagnose attempts to define ARC-__weak ivars when __weak is disabled.\nstatic void DiagnoseWeakIvars(Sema &S, ObjCImplementationDecl *ID) {\n // ...\n for (auto ivar = ID->getClassInterface()->all_declared_ivar_begin(); ivar; ivar = ivar->getNextIvar()) {\n // ...\n if (ivar->getType().getObjCLifetime() == Qualifiers::OCL_Weak) {\n if (S.getLangOpts().ObjCWeakRuntime) {\n // ...\n } else {\n S.Diag(ivar->getLocation(), diag::err_arc_weak_no_runtime);"},{p,7058,"/// handleObjCOwnershipTypeAttr - Process an objc_ownership\n/// attribute on the specified type.\n///\n/// Returns \'true\' if the attribute was handled.\nstatic bool handleObjCOwnershipTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n // ...\n // Sometimes, __weak isn\'t allowed.\n if (lifetime == Qualifiers::OCL_Weak && !S.getLangOpts().ObjCWeak && !NonObjCPointer) {\n // ...\n unsigned diagnostic = (S.getLangOpts().ObjCWeakRuntime ? diag::err_arc_weak_disabled : diag::err_arc_weak_no_runtime);"}}, [l]={ ["clang/test/SemaObjC/arc-no-runtime.m"]={"clang/test/SemaObjC/arc-no-runtime.m:5:3: error: cannot create __weak reference because the current deployment target does not support weak references"} } }, ["err_arc_weak_unavailable_assign"]={ [c]="err_arc_weak_unavailable_assign", [d]="assignment of a weak-unavailable object to a __weak object", [e]="assignment of a weak-unavailable object to a __weak object", [f]=k, [g]="assignment of a weak\\-unavailable object to a __weak object", [h]=a, [i]=wb, [b]={"6f472e803bf8",1310064947,"objc-arc: diagnose assignment/cast of a weak-unavailable","objc-arc: diagnose assignment/cast of a weak-unavailable\nobject to a __weak object/type. // rdar://9732636.\nThis is objc side of things. objc++ side tbd.\n\nllvm-svn: 134624"}, [j]={{Y,17705,"bool Sema::DiagnoseAssignmentResult(AssignConvertType ConvTy, SourceLocation Loc, QualType DstType, QualType SrcType, Expr *SrcExpr, AssignmentAction Action, bool *Complained) {\n // ...\n case IncompatibleObjCWeakRef:\n DiagKind = diag::err_arc_weak_unavailable_assign;"},{D,4495,"/// PerformImplicitConversion - Perform an implicit conversion of the\n/// expression From to the type ToType by following the standard\n/// conversion sequence SCS. Returns the converted\n/// expression. Flavor is the context in which we\'re performing this\n/// conversion, for use in error messages.\nExprResult Sema::PerformImplicitConversion(Expr *From, QualType ToType, const StandardConversionSequence &SCS, AssignmentAction Action, CheckedConversionKind CCK) {\n // ...\n case ICK_Writeback_Conversion:\n case ICK_Pointer_Conversion: {\n if (SCS.IncompatibleObjC && Action != AA_Casting) {\n // ...\n } else if (getLangOpts().allowsNonTrivialObjCLifetimeQualifiers() && !CheckObjCARCUnavailableWeakConversion(ToType, From->getType())) {\n if (Action == AA_Initializing)\n Diag(From->getBeginLoc(), diag::err_arc_weak_unavailable_assign);"}}, [l]={ ["clang/test/SemaObjCXX/objc-weak.mm"]={"clang/test/SemaObjCXX/objc-weak.mm:21:17: error: assignment of a weak-unavailable object to a __weak object","clang/test/SemaObjCXX/objc-weak.mm:25:17: error: assignment of a weak-unavailable object to a __weak object"} } }, ["err_arc_weak_unavailable_property"]={ [c]="err_arc_weak_unavailable_property", [d]="synthesizing __weak instance variable of type %0, which does not support weak references", [e]="synthesizing __weak instance variable of type A, which does not support weak references", [f]=k, [g]="synthesizing __weak instance variable of type (.*?), which does not support weak references", [h]=a, [i]=wb, [b]={"e283346d0bf4",1323460511,"objc-arc: diagnose synthesis of a \'weak unavailable\' property.","objc-arc: diagnose synthesis of a \'weak unavailable\' property.\n// rdar://10535245\n\nllvm-svn: 146272"}, [j]={{mb,1265,"/// ActOnPropertyImplDecl - This routine performs semantic checks and\n/// builds the AST node for a property implementation declaration; declared\n/// as \\@synthesize or \\@dynamic.\n///\nDecl *Sema::ActOnPropertyImplDecl(Scope *S, SourceLocation AtLoc, SourceLocation PropertyLoc, bool Synthesize, IdentifierInfo *PropertyId, IdentifierInfo *PropertyIvar, SourceLocation PropertyIvarLoc, ObjCPropertyQueryKind QueryKind) {\n // ...\n // Check that we have a valid, previously declared ivar for @synthesize\n if (Synthesize) {\n // ...\n if (kind & ObjCPropertyAttribute::kind_weak) {\n // Add GC __weak to the ivar type if the property is weak.\n if (getLangOpts().getGC() != LangOptions::NonGC) {\n // ...\n } else {\n if (!getLangOpts().ObjCWeak) {\n // ...\n } else {\n // ...\n if (const ObjCObjectPointerType *ObjT = PropertyIvarType->getAs<ObjCObjectPointerType>()) {\n // ...\n if (ObjI && ObjI->isArcWeakrefUnavailable()) {\n Diag(property->getLocation(), diag::err_arc_weak_unavailable_property) << PropertyIvarType;"}}, [l]={ ["clang/test/SemaObjC/arc-unavailable-for-weakref.m"]={"clang/test/SemaObjC/arc-unavailable-for-weakref.m:60:26: error: synthesizing __weak instance variable of type \'NSFont *\', which does not support weak references","clang/test/SemaObjC/arc-unavailable-for-weakref.m:69:26: error: synthesizing __weak instance variable of type \'NSFont *\', which does not support weak references","clang/test/SemaObjC/arc-unavailable-for-weakref.m:80:26: error: synthesizing __weak instance variable of type \'NSFont *\', which does not support weak references"} } }, ["err_arch_unsupported_isa"]={ [c]={{nil,X,"err_arch_unsupported_isa"}}, [d]={{nil,x,"architecture \'%0\' does not support \'%1\' execution mode"},{y,X,"Architecture \'%0\' does not support \'%1\' execution mode"}}, [e]={{nil,x,"architecture \'A\' does not support \'B\' execution mode"},{y,X,"Architecture \'A\' does not support \'B\' execution mode"}}, [f]=k, [g]="architecture \'(.*?)\' does not support \'(.*?)\' execution mode", [h]=a, [i]={{nil,X,W}}, [b]={"83e57c232702",1501843218,"[Driver] Error if ARM mode was selected explicitly for M-profile CPUs.","[Driver] Error if ARM mode was selected explicitly for M-profile CPUs.\n\nSummary:\nM-class profiles do not support ARM execution mode, so providing\n-marm/-mno-thumb does not make sense in combination with -mcpu/-march\noptions that support the M-profile.\n\nThis is a follow-up patch to D35569 and it seemed pretty clear that we\nshould emit an error in the driver in this case.\n\nWe probably also should warn/error if the provided -mcpu/-march options\ndo not match, e.g. -mcpu=cortex-m0 -march=armv8-a is invalid, as\ncortex-m0 does not support armv8-a. But that should be a separate patch\nI think.\n\n\nReviewers: echristo, richard.barton.arm, rengolin, labrinea, charles.baylis\n\nReviewed By: rengolin\n\nSubscribers: aemerson, javed.absar, kristof.beyls, cfe-commits\n\nDifferential Revision: https://reviews.llvm.org/D35826\n\nllvm-svn: 310047"}, [j]={{"clang/lib/Driver/ToolChains/Arch/ARM.cpp",267,"void arm::setArchNameInTriple(const Driver &D, const ArgList &Args, types::ID InputType, llvm::Triple &Triple) {\n // ...\n if (IsMProfile && ARMModeRequested) {\n if (MCPU.size())\n // ...\n else\n D.Diag(diag::err_arch_unsupported_isa) << tools::arm::getARMArch(MArch, Triple) << \"ARM\";"}} }, ["err_arcmt_nsinvocation_ownership"]={ [c]="err_arcmt_nsinvocation_ownership", [d]="NSInvocation\'s %0 is not safe to be used with an object with ownership other than __unsafe_unretained", [e]="NSInvocation\'s A is not safe to be used with an object with ownership other than __unsafe_unretained", [f]=k, [g]="NSInvocation\'s (.*?) is not safe to be used with an object with ownership other than __unsafe_unretained", [h]=a, [i]=W, [b]={"42aa21222d37",1390712852,"ARCMigrate: Introduce proper diagnostics for TransformActions","ARCMigrate: Introduce proper diagnostics for TransformActions\n\nThis starts to switch ARCMT to use proper diagnostic messages. The old use was\nbased on incorrect example code from the documentation.\n\nThe logic of the previous report() functions has been retained to support any\nexternal consumers that might be intercepting diagnostic messages through the\nold interface.\n\nNote that the change in test/Misc/warning-flags.c isn\'t a new warning without a\nflag, rather one that was previously invisible to the test. Adding a flag might\nbe a good idea though.\n\nllvm-svn: 200124"}, [j]={{"clang/lib/ARCMigrate/TransAPIUses.cpp",79,"class APIChecker : public RecursiveASTVisitor<APIChecker> {\n // ...\n bool VisitObjCMessageExpr(ObjCMessageExpr *E) {\n // NSInvocation.\n if (E->isInstanceMessage() && E->getReceiverInterface() && E->getReceiverInterface()->getName() == \"NSInvocation\") {\n // ...\n if (pointee.getObjCLifetime() > Qualifiers::OCL_ExplicitNone)\n Pass.TA.report(parm->getBeginLoc(), diag::err_arcmt_nsinvocation_ownership, parm->getSourceRange()) << selName;"}}, [l]={ ["clang/test/ARCMT/check-api.m"]={"clang/test/ARCMT/check-api.m:23:25: error: NSInvocation\'s getReturnValue is not safe to be used with an object with ownership other than __unsafe_unretained","clang/test/ARCMT/check-api.m:24:25: error: NSInvocation\'s getReturnValue is not safe to be used with an object with ownership other than __unsafe_unretained","clang/test/ARCMT/check-api.m:28:25: error: NSInvocation\'s setReturnValue is not safe to be used with an object with ownership other than __unsafe_unretained","clang/test/ARCMT/check-api.m:29:25: error: NSInvocation\'s setReturnValue is not safe to be used with an object with ownership other than __unsafe_unretained","clang/test/ARCMT/check-api.m:33:22: error: NSInvocation\'s getArgument is not safe to be used with an object with ownership other than __unsafe_unretained","clang/test/ARCMT/check-api.m:34:22: error: NSInvocation\'s getArgument is not safe to be used with an object with ownership other than __unsafe_unretained","clang/test/ARCMT/check-api.m:38:22: error: NSInvocation\'s setArgument is not safe to be used with an object with ownership other than __unsafe_unretained","clang/test/ARCMT/check-api.m:39:22: error: NSInvocation\'s setArgument is not safe to be used with an object with ownership other than __unsafe_unretained"} } }, ["err_arg_with_address_space"]={ [c]="err_arg_with_address_space", [d]="parameter may not be qualified with an address space", [e]="parameter may not be qualified with an address space", [f]=k, [g]="parameter may not be qualified with an address space", [h]=a, [i]=m, [b]={"fd2dcba7f3a6",1254343663,"Add an error for function parameters that have a qualified address space since this is not allowed b...","Add an error for function parameters that have a qualified address space since this is not allowed by the embedded c extension spec.\n\nllvm-svn: 83165"}, [j]={{o,14958,"ParmVarDecl *Sema::CheckParameter(DeclContext *DC, SourceLocation StartLoc, SourceLocation NameLoc, IdentifierInfo *Name, QualType T, TypeSourceInfo *TSInfo, StorageClass SC) {\n // ...\n // ISO/IEC TR 18037 S6.7.3: \"The type of an object with automatic storage\n // duration shall not be qualified by an address-space qualifier.\"\n // Since all parameters have automatic store duration, they can not have\n // an address space.\n if (T.getAddressSpace() != LangAS::Default &&\n // ...\n Diag(NameLoc, diag::err_arg_with_address_space);"},{ib,5151,"/// Build a type-check a new Objective-C exception variable declaration.\nVarDecl *Sema::BuildObjCExceptionDecl(TypeSourceInfo *TInfo, QualType T, SourceLocation StartLoc, SourceLocation IdLoc, IdentifierInfo *Id, bool Invalid) {\n // ISO/IEC TR 18037 S6.7.3: \"The type of an object with automatic storage\n // duration shall not be qualified by an address-space qualifier.\"\n // Since all parameters have automatic store duration, they can not have\n // an address space.\n if (T.getAddressSpace() != LangAS::Default) {\n Diag(IdLoc, diag::err_arg_with_address_space);"}}, [l]={ ["clang/test/SemaHLSL/group_shared.hlsl"]={"clang/test/SemaHLSL/group_shared.hlsl:52:32: error: parameter may not be qualified with an address space","clang/test/SemaHLSL/group_shared.hlsl:73:30: error: parameter may not be qualified with an address space","clang/test/SemaHLSL/group_shared.hlsl:107:29: error: parameter may not be qualified with an address space"} } }, ["err_argument_invalid_range"]={ [c]="err_argument_invalid_range", [d]={{nil,A,"argument value %0 is outside the valid range [%1, %2]"},{X,nil,"argument should be a value from %0 to %1"}}, [e]={{nil,A,"argument value A is outside the valid range [B, C]"},{X,nil,"argument should be a value from A to B"}}, [f]=k, [g]="argument value (.*?) is outside the valid range \\[(.*?), (.*?)\\]", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{t,8809,"/// SemaBuiltinConstantArgRange - Handle a check if argument ArgNum of CallExpr\n/// TheCall is a constant expression in the range [Low, High].\nbool Sema::SemaBuiltinConstantArgRange(CallExpr *TheCall, int ArgNum, int Low, int High, bool RangeIsError) {\n // ...\n if (Result.getSExtValue() < Low || Result.getSExtValue() > High) {\n if (RangeIsError)\n return Diag(TheCall->getBeginLoc(), diag::err_argument_invalid_range) << toString(Result, 10) << Low << High << Arg->getSourceRange();"}}, [l]={ ["clang/test/Sema/builtin-stackaddress.c"]={"clang/test/Sema/builtin-stackaddress.c:13:8: error: argument value 4294967295 is outside the valid range [0, 65535]","clang/test/Sema/builtin-stackaddress.c:18:8: error: argument value 1048575 is outside the valid range [0, 65535]","clang/test/Sema/builtin-stackaddress.c:32:8: error: argument value 4294967295 is outside the valid range [0, 65535]","clang/test/Sema/builtin-stackaddress.c:37:8: error: argument value 1048575 is outside the valid range [0, 65535]"} } }, ["err_argument_not_contiguous_bit_field"]={ [c]={{nil,y,"err_argument_not_contiguous_bit_field"}}, [d]={{nil,y,"argument %0 value should represent a contiguous bit field"}}, [e]={{nil,y,"argument A value should represent a contiguous bit field"}}, [f]=k, [g]="argument (.*?) value should represent a contiguous bit field", [h]=a, [i]={{nil,y,m}}, [b]={"3dbcea8b957a",1615397021,"Reland [clang] Check unsupported types in expressions","Reland [clang] Check unsupported types in expressions\n\nThis was committed as ec6c847179fd, but then reverted after a failure\nin: https://lab.llvm.org/buildbot/#/builders/84/builds/13983\n\nI was not able to reproduce the problem, but I added an extra check\nfor a NULL QualType just in case.\n\nOriginal comit message:\n\nThe patch adds missing diagnostics for cases like:\n\n float F3 = ((__float128)F1 * (__float128)F2) / 2.0f;\n\nSema::checkDeviceDecl (renamed to checkTypeSupport) is changed to work\nwith a type without the corresponding ValueDecl. It is also refactored\nso that host diagnostics for unsupported types can be added here as\nwell.\n\nDifferential Revision: https://reviews.llvm.org/D109315"}, [j]={{t,4238,"/// Returns true if the argument consists of one contiguous run of 1s with any\n/// number of 0s on either side. The 1s are allowed to wrap from LSB to MSB, so\n/// 0x000FFF0, 0x0000FFFF, 0xFF0000FF, 0x0 are all runs. 0x0F0F0000 is not,\n/// since all 1s are not contiguous.\nbool Sema::SemaValueIsRunOfOnes(CallExpr *TheCall, unsigned ArgNum) {\n // ...\n return Diag(TheCall->getBeginLoc(), diag::err_argument_not_contiguous_bit_field) << ArgNum << Arg->getSourceRange();"}}, [l]={ ["clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c"]={"clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:32:9: error: argument 3 value should represent a contiguous bit field","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:40:9: error: argument 3 value should represent a contiguous bit field","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:46:9: error: argument 2 value should represent a contiguous bit field","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:73:10: error: argument 2 value should represent a contiguous bit field"} } }, ["err_argument_not_multiple"]={ [c]="err_argument_not_multiple", [d]="argument should be a multiple of %0", [e]="argument should be a multiple of A", [f]=k, [g]="argument should be a multiple of (.*?)", [h]=a, [i]=m, [b]={"1f90f2d33f72",1476899452,"[mips][msa] Range check MSA intrinsics with immediates","[mips][msa] Range check MSA intrinsics with immediates\n\nThis patch teaches clang to range check immediates for MIPS MSA instrinsics.\nThis checking is done strictly in comparison to some existing GCC\nimplementations. E.g. msa_andvi_b(var, 257) does not result in andvi $wX, 1.\nSimilarily msa_ldi_b takes a range of -128 to 127.\n\nAs part of this effort, correct the existing MSA test as it has both illegal\ntypes and immediates.\n\nReviewers: vkalintiris\n\nDifferential Revision: https://reviews.llvm.org/D25017\n\nllvm-svn: 284620"}, [j]={{t,8839,"/// SemaBuiltinConstantArgMultiple - Handle a check if argument ArgNum of CallExpr\n/// TheCall is a constant expression is a multiple of Num..\nbool Sema::SemaBuiltinConstantArgMultiple(CallExpr *TheCall, int ArgNum, unsigned Num) {\n // ...\n if (Result.getSExtValue() % Num != 0)\n return Diag(TheCall->getBeginLoc(), diag::err_argument_not_multiple) << Num << Arg->getSourceRange();"}}, [l]={ ["clang/test/CodeGen/hexagon-check-builtins.c"]={"clang/test/CodeGen/hexagon-check-builtins.c:19:10: error: argument should be a multiple of 4","clang/test/CodeGen/hexagon-check-builtins.c:22:10: error: argument should be a multiple of 4","clang/test/CodeGen/hexagon-check-builtins.c:28:10: error: argument should be a multiple of 4"} } }, ["err_argument_not_power_of_2"]={ [c]={{nil,s,"err_argument_not_power_of_2"}}, [d]={{nil,s,"argument should be a power of 2"}}, [e]={{nil,s,"argument should be a power of 2"}}, [f]=k, [g]="argument should be a power of 2", [h]=a, [i]={{nil,s,m}}, [b]={"08074cc96557",1567435850,"[clang,ARM] Initial ACLE intrinsics for MVE.","[clang,ARM] Initial ACLE intrinsics for MVE.\n\nThis commit sets up the infrastructure for auto-generating <arm_mve.h>\nand doing clang-side code generation for the builtins it relies on,\nand demonstrates that it works by implementing a representative sample\nof the ACLE intrinsics, more or less matching the ones introduced in\nLLVM IR by D67158,D68699,D68700.\n\nLike NEON, that header file will provide a set of vector types like\nuint16x8_t and C functions with names like vaddq_u32(). Unlike NEON,\nthe ACLE spec for <arm_mve.h> includes a polymorphism system, so that\nyou can write plain vaddq() and disambiguate by the vector types you\npass to it.\n\nUnlike the corresponding NEON code, I\'ve arranged to make every user-\nfacing ACLE intrinsic into a clang builtin, and implement all the code\ngeneration inside clang. So <arm_mve.h> itself contains nothing but\ntypedefs and function declarations, with the latter all using the new\n`__attribute__((__clang_builtin))` system to arrange that the user-\nfacing function names correspond to the right internal BuiltinIDs.\n\nSo the new MveEmitter tablegen system specifies the full sequence of\nIRBuilder operations that each user-facing ACLE intrinsic should\ntranslate into. Where possible, the ACLE intrinsics map to standard IR\noperations such as vector-typed `add` and `fadd`; where no standard\nrepresentation exists, I call down to the sample IR intrinsics\nintroduced in an earlier commit.\n\nDoing it like this means that you get the polymorphism for free just\nby using __attribute__((overloadable)): the clang overload resolution\ndecides which function declaration is the relevant one, and _then_ its\nBuiltinID is looked up, so by the time we\'re doing code generation,\nthat\'s all been resolved by the standard system. It also means that\nyou get really nice error messages if the user passes the wrong\ncombination of types: clang will show the declarations from the header\nfile and explain why each one doesn\'t match.\n\n(The obvious alternative approach would be to have wrapper functions\nin <arm_mve.h> which pass their arguments to the underlying builtins.\nBut that doesn\'t work in the case where one of the arguments has to be\na constant integer: the wrapper function can\'t pass the constantness\nthrough. So you\'d have to do that case using a macro instead, and then\nuse C11 `_Generic` to handle the polymorphism. Then you have to add\nhorrible workarounds because `_Generic` requires even the untaken\nbranches to type-check successfully, and //then// if the user gets the\ntypes wrong, the error message is totally unreadable!)\n\nReviewers: dmgreen, miyuki, ostannard\n\nSubscribers: mgorny, javed.absar, kristof.beyls, cfe-commits\n\nTags: #clang\n\nDifferential Revision: https://reviews.llvm.org/D67161"}, [j]={{t,8864,"/// SemaBuiltinConstantArgPower2 - Check if argument ArgNum of TheCall is a\n/// constant expression representing a power of 2.\nbool Sema::SemaBuiltinConstantArgPower2(CallExpr *TheCall, int ArgNum) {\n // ...\n return Diag(TheCall->getBeginLoc(), diag::err_argument_not_power_of_2) << Arg->getSourceRange();"}}, [l]={ ["clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c"]={"clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:80:3: error: argument should be a power of 2","clang/test/CodeGen/PowerPC/builtins-ppc-xlcompat-error.c:82:3: error: argument should be a power of 2"} } }, ["err_argument_not_shifted_byte"]={ [c]={{nil,s,"err_argument_not_shifted_byte"}}, [d]={{nil,s,"argument should be an 8-bit value shifted by a multiple of 8 bits"}}, [e]={{nil,s,"argument should be an 8-bit value shifted by a multiple of 8 bits"}}, [f]=k, [g]="argument should be an 8\\-bit value shifted by a multiple of 8 bits", [h]=a, [i]={{nil,s,m}}, [b]={"08074cc96557",1567435850,"[clang,ARM] Initial ACLE intrinsics for MVE.","[clang,ARM] Initial ACLE intrinsics for MVE.\n\nThis commit sets up the infrastructure for auto-generating <arm_mve.h>\nand doing clang-side code generation for the builtins it relies on,\nand demonstrates that it works by implementing a representative sample\nof the ACLE intrinsics, more or less matching the ones introduced in\nLLVM IR by D67158,D68699,D68700.\n\nLike NEON, that header file will provide a set of vector types like\nuint16x8_t and C functions with names like vaddq_u32(). Unlike NEON,\nthe ACLE spec for <arm_mve.h> includes a polymorphism system, so that\nyou can write plain vaddq() and disambiguate by the vector types you\npass to it.\n\nUnlike the corresponding NEON code, I\'ve arranged to make every user-\nfacing ACLE intrinsic into a clang builtin, and implement all the code\ngeneration inside clang. So <arm_mve.h> itself contains nothing but\ntypedefs and function declarations, with the latter all using the new\n`__attribute__((__clang_builtin))` system to arrange that the user-\nfacing function names correspond to the right internal BuiltinIDs.\n\nSo the new MveEmitter tablegen system specifies the full sequence of\nIRBuilder operations that each user-facing ACLE intrinsic should\ntranslate into. Where possible, the ACLE intrinsics map to standard IR\noperations such as vector-typed `add` and `fadd`; where no standard\nrepresentation exists, I call down to the sample IR intrinsics\nintroduced in an earlier commit.\n\nDoing it like this means that you get the polymorphism for free just\nby using __attribute__((overloadable)): the clang overload resolution\ndecides which function declaration is the relevant one, and _then_ its\nBuiltinID is looked up, so by the time we\'re doing code generation,\nthat\'s all been resolved by the standard system. It also means that\nyou get really nice error messages if the user passes the wrong\ncombination of types: clang will show the declarations from the header\nfile and explain why each one doesn\'t match.\n\n(The obvious alternative approach would be to have wrapper functions\nin <arm_mve.h> which pass their arguments to the underlying builtins.\nBut that doesn\'t work in the case where one of the arguments has to be\na constant integer: the wrapper function can\'t pass the constantness\nthrough. So you\'d have to do that case using a macro instead, and then\nuse C11 `_Generic` to handle the polymorphism. Then you have to add\nhorrible workarounds because `_Generic` requires even the untaken\nbranches to type-check successfully, and //then// if the user gets the\ntypes wrong, the error message is totally unreadable!)\n\nReviewers: dmgreen, miyuki, ostannard\n\nSubscribers: mgorny, javed.absar, kristof.beyls, cfe-commits\n\nTags: #clang\n\nDifferential Revision: https://reviews.llvm.org/D67161"}, [j]={{t,8913,"/// SemaBuiltinConstantArgShiftedByte - Check if argument ArgNum of TheCall is\n/// a constant expression representing an arbitrary byte value shifted left by\n/// a multiple of 8 bits.\nbool Sema::SemaBuiltinConstantArgShiftedByte(CallExpr *TheCall, int ArgNum, unsigned ArgBits) {\n // ...\n return Diag(TheCall->getBeginLoc(), diag::err_argument_not_shifted_byte) << Arg->getSourceRange();"}}, [l]={ ["clang/test/Sema/arm-mve-immediates.c"]={"clang/test/Sema/arm-mve-immediates.c:215:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits","clang/test/Sema/arm-mve-immediates.c:216:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits","clang/test/Sema/arm-mve-immediates.c:228:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits","clang/test/Sema/arm-mve-immediates.c:229:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits","clang/test/Sema/arm-mve-immediates.c:235:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits","clang/test/Sema/arm-mve-immediates.c:236:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits","clang/test/Sema/arm-mve-immediates.c:248:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits","clang/test/Sema/arm-mve-immediates.c:249:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits"} } }, ["err_argument_not_shifted_byte_or_xxff"]={ [c]={{nil,s,"err_argument_not_shifted_byte_or_xxff"}}, [d]={{nil,s,"argument should be an 8-bit value shifted by a multiple of 8 bits, or in the form 0x??FF"}}, [e]={{nil,s,"argument should be an 8-bit value shifted by a multiple of 8 bits, or in the form 0x??FF"}}, [f]=k, [g]="argument should be an 8\\-bit value shifted by a multiple of 8 bits, or in the form 0x\\?\\?FF", [h]=a, [i]={{nil,s,m}}, [b]={"08074cc96557",1567435850,"[clang,ARM] Initial ACLE intrinsics for MVE.","[clang,ARM] Initial ACLE intrinsics for MVE.\n\nThis commit sets up the infrastructure for auto-generating <arm_mve.h>\nand doing clang-side code generation for the builtins it relies on,\nand demonstrates that it works by implementing a representative sample\nof the ACLE intrinsics, more or less matching the ones introduced in\nLLVM IR by D67158,D68699,D68700.\n\nLike NEON, that header file will provide a set of vector types like\nuint16x8_t and C functions with names like vaddq_u32(). Unlike NEON,\nthe ACLE spec for <arm_mve.h> includes a polymorphism system, so that\nyou can write plain vaddq() and disambiguate by the vector types you\npass to it.\n\nUnlike the corresponding NEON code, I\'ve arranged to make every user-\nfacing ACLE intrinsic into a clang builtin, and implement all the code\ngeneration inside clang. So <arm_mve.h> itself contains nothing but\ntypedefs and function declarations, with the latter all using the new\n`__attribute__((__clang_builtin))` system to arrange that the user-\nfacing function names correspond to the right internal BuiltinIDs.\n\nSo the new MveEmitter tablegen system specifies the full sequence of\nIRBuilder operations that each user-facing ACLE intrinsic should\ntranslate into. Where possible, the ACLE intrinsics map to standard IR\noperations such as vector-typed `add` and `fadd`; where no standard\nrepresentation exists, I call down to the sample IR intrinsics\nintroduced in an earlier commit.\n\nDoing it like this means that you get the polymorphism for free just\nby using __attribute__((overloadable)): the clang overload resolution\ndecides which function declaration is the relevant one, and _then_ its\nBuiltinID is looked up, so by the time we\'re doing code generation,\nthat\'s all been resolved by the standard system. It also means that\nyou get really nice error messages if the user passes the wrong\ncombination of types: clang will show the declarations from the header\nfile and explain why each one doesn\'t match.\n\n(The obvious alternative approach would be to have wrapper functions\nin <arm_mve.h> which pass their arguments to the underlying builtins.\nBut that doesn\'t work in the case where one of the arguments has to be\na constant integer: the wrapper function can\'t pass the constantness\nthrough. So you\'d have to do that case using a macro instead, and then\nuse C11 `_Generic` to handle the polymorphism. Then you have to add\nhorrible workarounds because `_Generic` requires even the untaken\nbranches to type-check successfully, and //then// if the user gets the\ntypes wrong, the error message is totally unreadable!)\n\nReviewers: dmgreen, miyuki, ostannard\n\nSubscribers: mgorny, javed.absar, kristof.beyls, cfe-commits\n\nTags: #clang\n\nDifferential Revision: https://reviews.llvm.org/D67161"}, [j]={{t,8946,"/// SemaBuiltinConstantArgShiftedByteOr0xFF - Check if argument ArgNum of\n/// TheCall is a constant expression representing either a shifted byte value,\n/// or a value of the form 0x??FF (i.e. a member of the arithmetic progression\n/// 0x00FF, 0x01FF, ..., 0xFFFF). This strange range check is needed for some\n/// Arm MVE intrinsics.\nbool Sema::SemaBuiltinConstantArgShiftedByteOrXXFF(CallExpr *TheCall, int ArgNum, unsigned ArgBits) {\n // ...\n return Diag(TheCall->getBeginLoc(), diag::err_argument_not_shifted_byte_or_xxff) << Arg->getSourceRange();"}}, [l]={ ["clang/test/Sema/arm-mve-immediates.c"]={"clang/test/Sema/arm-mve-immediates.c:259:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits, or in the form 0x??FF","clang/test/Sema/arm-mve-immediates.c:273:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits, or in the form 0x??FF","clang/test/Sema/arm-mve-immediates.c:274:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits, or in the form 0x??FF","clang/test/Sema/arm-mve-immediates.c:275:9: error: argument should be an 8-bit value shifted by a multiple of 8 bits, or in the form 0x??FF"} } }, ["err_argument_required_after_attribute"]={ [c]="err_argument_required_after_attribute", [d]="argument required after attribute", [e]="argument required after attribute", [f]=k, [g]="argument required after attribute", [h]=a, [i]=V, [b]={N,1236199783,O,P}, [j]={{Bb,1569,"void Parser::ParseSwiftNewTypeAttribute(IdentifierInfo &AttrName, SourceLocation AttrNameLoc, ParsedAttributes &Attrs, SourceLocation *EndLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n // ...\n if (Tok.is(tok::r_paren)) {\n Diag(Tok.getLocation(), diag::err_argument_required_after_attribute);"},{Bb,7006,"/// ParseFunctionDeclarator - We are after the identifier and have parsed the\n/// declarator D up to a paren, which indicates that we are parsing function\n/// arguments.\n///\n/// If FirstArgAttrs is non-null, then the caller parsed those attributes\n/// immediately after the open paren - they will be applied to the DeclSpec\n/// of the first parameter.\n///\n/// If RequiresArg is true, then the first argument of the function is required\n/// to be present and required to not be an identifier list.\n///\n/// For C++, after the parameter-list, it also parses the cv-qualifier-seq[opt],\n/// (C++11) ref-qualifier[opt], exception-specification[opt],\n/// (C++11) attribute-specifier-seq[opt], (C++11) trailing-return-type[opt] and\n/// (C++2a) the trailing requires-clause.\n///\n/// [C++11] exception-specification:\n/// dynamic-exception-specification\n/// noexcept-specification\n///\nvoid Parser::ParseFunctionDeclarator(Declarator &D, ParsedAttributes &FirstArgAttrs, BalancedDelimiterTracker &Tracker, bool IsAmbiguous, bool RequiresArg) {\n // ...\n if (isFunctionDeclaratorIdentifierList()) {\n if (RequiresArg)\n Diag(Tok, diag::err_argument_required_after_attribute);"},{Bb,7023,"/// ParseFunctionDeclarator - We are after the identifier and have parsed the\n/// declarator D up to a paren, which indicates that we are parsing function\n/// arguments.\n///\n/// If FirstArgAttrs is non-null, then the caller parsed those attributes\n/// immediately after the open paren - they will be applied to the DeclSpec\n/// of the first parameter.\n///\n/// If RequiresArg is true, then the first argument of the function is required\n/// to be present and required to not be an identifier list.\n///\n/// For C++, after the parameter-list, it also parses the cv-qualifier-seq[opt],\n/// (C++11) ref-qualifier[opt], exception-specification[opt],\n/// (C++11) attribute-specifier-seq[opt], (C++11) trailing-return-type[opt] and\n/// (C++2a) the trailing requires-clause.\n///\n/// [C++11] exception-specification:\n/// dynamic-exception-specification\n/// noexcept-specification\n///\nvoid Parser::ParseFunctionDeclarator(Declarator &D, ParsedAttributes &FirstArgAttrs, BalancedDelimiterTracker &Tracker, bool IsAmbiguous, bool RequiresArg) {\n // ...\n if (isFunctionDeclaratorIdentifierList()) {\n // ...\n } else {\n if (Tok.isNot(tok::r_paren))\n // ...\n else if (RequiresArg)\n Diag(Tok, diag::err_argument_required_after_attribute);"}}, [l]={ ["clang/test/SemaObjC/attr-swift_newtype.m"]={"clang/test/SemaObjC/attr-swift_newtype.m:5:47: error: argument required after attribute"} } }, ["err_arithmetic_nonfragile_interface"]={ [c]="err_arithmetic_nonfragile_interface", [d]="arithmetic on pointer to interface %0, which is not a constant size for this architecture and platform", [e]="arithmetic on pointer to interface A, which is not a constant size for this architecture and platform", [f]=k, [g]="arithmetic on pointer to interface (.*?), which is not a constant size for this architecture and platform", [h]=a, [i]=m, [b]={"12bdebbbf7ff",1240617008,"reject explicit pointer arithmetic on interface pointers in 64-bit objc ABI","reject explicit pointer arithmetic on interface pointers in 64-bit objc ABI\n\nllvm-svn: 70004"}, [j]={{Y,4986,"/// Diagnose if arithmetic on the given ObjC pointer is illegal.\n///\n/// \\return true on error\nstatic bool checkArithmeticOnObjCPointer(Sema &S, SourceLocation opLoc, Expr *op) {\n // ...\n S.Diag(opLoc, diag::err_arithmetic_nonfragile_interface) << op->getType()->castAs<ObjCObjectPointerType>()->getPointeeType() << op->getSourceRange();"}}, [l]={ ["clang/test/SemaObjC/sizeof-interface.m"]={"clang/test/SemaObjC/sizeof-interface.m:54:8: error: arithmetic on pointer to interface \'I0\', which is not a constant size for this architecture and platform","clang/test/SemaObjC/sizeof-interface.m:55:8: error: arithmetic on pointer to interface \'I0\', which is not a constant size for this architecture and platform","clang/test/SemaObjC/sizeof-interface.m:56:8: error: arithmetic on pointer to interface \'I0\', which is not a constant size for this architecture and platform","clang/test/SemaObjC/sizeof-interface.m:88:3: error: arithmetic on pointer to interface \'Foo\', which is not a constant size for this architecture and platform","clang/test/SemaObjC/sizeof-interface.m:89:3: error: arithmetic on pointer to interface \'Foo\', which is not a constant size for this architecture and platform"} } }, ["err_arm_invalid_coproc"]={ [c]={{nil,q,"err_arm_invalid_coproc"}}, [d]={{nil,q,"coprocessor %0 must be configured as %select{GCP|CDE}1"}}, [e]={{nil,q,{"coprocessor A must be configured as ",{"GCP","CDE"}}}}, [f]=k, [g]="coprocessor (.*?) must be configured as (?:GCP|CDE)", [h]=a, [i]={{nil,q,m}}, [b]={Fb,1576908663,Gb,Hb}, [j]={{t,3142,"bool Sema::CheckARMCoprocessorImmediate(const TargetInfo &TI, const Expr *CoprocArg, bool WantCDE) {\n // ...\n if (IsCDECoproc != WantCDE)\n return Diag(CoprocArg->getBeginLoc(), diag::err_arm_invalid_coproc) << (int)CoprocNo << (int)WantCDE << CoprocArg->getSourceRange();"}}, [l]={ ["clang/test/Sema/arm-cde-immediates.c"]={"clang/test/Sema/arm-cde-immediates.c:9:21: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:10:22: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:11:21: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:12:22: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:13:21: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:14:22: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:15:22: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:16:23: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:17:22: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:18:23: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:19:21: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:20:22: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:21:22: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:22:23: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:23:21: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:24:22: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:25:22: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:26:23: error: coprocessor 0 must be configured as GCP","clang/test/Sema/arm-cde-immediates.c:34:13: error: coprocessor 1 must be configured as CDE"} } }, ["err_arm_invalid_specialreg"]={ [c]="err_arm_invalid_specialreg", [d]="invalid special register for builtin", [e]="invalid special register for builtin", [f]=k, [g]="invalid special register for builtin", [h]=a, [i]=m, [b]={"59b2d8390941",1434390661,"This patch implements clang support for the ACLE special register intrinsics","This patch implements clang support for the ACLE special register intrinsics\nin section 10.1, __arm_{w,r}sr{,p,64}.\n\nThis includes arm_acle.h definitions with builtins and codegen to support\nthese, the intrinsics are implemented by generating read/write_register calls\nwhich get appropriately lowered in the backend based on the register string\nprovided. SemaChecking is also implemented to fault invalid parameters.\n\nDifferential Revision: http://reviews.llvm.org/D9697\n\nllvm-svn: 239737"}, [j]={{t,9141,"/// SemaBuiltinARMSpecialReg - Handle a check if argument ArgNum of CallExpr\n/// TheCall is an ARM/AArch64 special register string literal.\nbool Sema::SemaBuiltinARMSpecialReg(unsigned BuiltinID, CallExpr *TheCall, int ArgNum, unsigned ExpectedFieldNum, bool AllowName) {\n // ...\n if (Fields.size() != ExpectedFieldNum && !(AllowName && Fields.size() == 1))\n return Diag(TheCall->getBeginLoc(), diag::err_arm_invalid_specialreg) << Arg->getSourceRange();"},{t,9183,"/// SemaBuiltinARMSpecialReg - Handle a check if argument ArgNum of CallExpr\n/// TheCall is an ARM/AArch64 special register string literal.\nbool Sema::SemaBuiltinARMSpecialReg(unsigned BuiltinID, CallExpr *TheCall, int ArgNum, unsigned ExpectedFieldNum, bool AllowName) {\n // ...\n // If the string is the name of a register then we cannot check that it is\n // valid here but if the string is of one the forms described in ACLE then we\n // can check that the supplied fields are integers and within the valid\n // ranges.\n if (Fields.size() > 1) {\n // ...\n if (!ValidString)\n return Diag(TheCall->getBeginLoc(), diag::err_arm_invalid_specialreg) << Arg->getSourceRange();"}}, [l]={ ["clang/test/Sema/arm-special-register.c"]={"clang/test/Sema/arm-special-register.c:16:3: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:28:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:40:3: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:52:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:56:3: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:60:3: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:68:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:72:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:80:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:84:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:88:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:92:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:96:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:100:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:104:10: error: invalid special register for builtin","clang/test/Sema/arm-special-register.c:108:10: error: invalid special register for builtin"} } }, ["err_array_designator_empty_range"]={ [c]="err_array_designator_empty_range", [d]="array designator range [%0, %1] is empty", [e]="array designator range [A, B] is empty", [f]=k, [g]="array designator range \\[(.*?), (.*?)\\] is empty", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{L,3400,"ExprResult Sema::ActOnDesignatedInitializer(Designation &Desig, SourceLocation EqualOrColonLoc, bool GNUSyntax, ExprResult Init) {\n // ...\n // Build designators and check array designator expressions.\n for (unsigned Idx = 0; Idx < Desig.getNumDesignators(); ++Idx) {\n // ...\n if (D.isFieldDesignator()) {\n // ...\n } else if (D.isArrayDesignator()) {\n // ...\n } else if (D.isArrayRangeDesignator()) {\n // ...\n if (!StartIndex || !EndIndex)\n // ...\n else {\n // ...\n if (!StartDependent && !EndDependent && EndValue < StartValue) {\n Diag(D.getEllipsisLoc(), diag::err_array_designator_empty_range) << toString(StartValue, 10) << toString(EndValue, 10) << StartIndex->getSourceRange() << EndIndex->getSourceRange();"}}, [l]={ ["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:11:7: error: array designator range [8, 7] is empty"} } }, ["err_array_designator_negative"]={ [c]="err_array_designator_negative", [d]="array designator value \'%0\' is negative", [e]="array designator value \'A\' is negative", [f]=k, [g]="array designator value \'(.*?)\' is negative", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{L,3337,"/// Check that the given Index expression is a valid array designator\n/// value. This is essentially just a wrapper around\n/// VerifyIntegerConstantExpression that also checks for negative values\n/// and produces a reasonable diagnostic if there is a\n/// failure. Returns the index expression, possibly with an implicit cast\n/// added, on success. If everything went okay, Value will receive the\n/// value of the constant expression.\nstatic ExprResult CheckArrayDesignatorExpr(Sema &S, Expr *Index, llvm::APSInt &Value) {\n // ...\n if (Value.isSigned() && Value.isNegative())\n return S.Diag(Loc, diag::err_array_designator_negative) << toString(Value, 10) << Index->getSourceRange();"}}, [l]={ ["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:13:4: error: array designator value \'-1\' is negative"} } }, ["err_array_designator_non_array"]={ [c]="err_array_designator_non_array", [d]="array designator cannot initialize non-array type %0", [e]="array designator cannot initialize non-array type A", [f]=k, [g]="array designator cannot initialize non\\-array type (.*?)", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{L,3001,"/// Check the well-formedness of a C99 designated initializer.\n///\n/// Determines whether the designated initializer @p DIE, which\n/// resides at the given @p Index within the initializer list @p\n/// IList, is well-formed for a current object of type @p DeclType\n/// (C99 6.7.8). The actual subobject that this designator refers to\n/// within the current subobject is returned in either\n/// @p NextField or @p NextElementIndex (whichever is appropriate).\n///\n/// @param IList The initializer list in which this designated\n/// initializer occurs.\n///\n/// @param DIE The designated initializer expression.\n///\n/// @param DesigIdx The index of the current designator.\n///\n/// @param CurrentObjectType The type of the \"current object\" (C99 6.7.8p17),\n/// into which the designation in @p DIE should refer.\n///\n/// @param NextField If non-NULL and the first designator in @p DIE is\n/// a field, this will be set to the field declaration corresponding\n/// to the field named by the designator. On input, this is expected to be\n/// the next field that would be initialized in the absence of designation,\n/// if the complete object being initialized is a struct.\n///\n/// @param NextElementIndex If non-NULL and the first designator in @p\n/// DIE is an array designator or GNU array-range designator, this\n/// will be set to the last index initialized by this designator.\n///\n/// @param Index Index into @p IList where the designated initializer\n/// @p DIE occurs.\n///\n/// @param StructuredList The initializer list expression that\n/// describes all of the subobject initializers in the order they\'ll\n/// actually be initialized.\n///\n/// @returns true if there was an error, false otherwise.\nbool InitListChecker::CheckDesignatedInitializer(const InitializedEntity &Entity, InitListExpr *IList, DesignatedInitExpr *DIE, unsigned DesigIdx, QualType &CurrentObjectType, RecordDecl::field_iterator *NextField, llvm::APSInt *NextElementIndex, unsigned &Index, InitListExpr *StructuredList, unsigned &StructuredIndex, bool FinishSubobjectInit, bool TopLevelObject) {\n // ...\n if (!AT) {\n if (!VerifyOnly)\n SemaRef.Diag(D->getLBracketLoc(), diag::err_array_designator_non_array) << CurrentObjectType;"}}, [l]={ ["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:37:3: error: array designator cannot initialize non-array type \'struct point\'"} } }, ["err_array_designator_too_large"]={ [c]="err_array_designator_too_large", [d]="array designator index (%0) exceeds array bounds (%1)", [e]="array designator index (A) exceeds array bounds (B)", [f]=k, [g]="array designator index \\((.*?)\\) exceeds array bounds \\((.*?)\\)", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{L,3043,"/// Check the well-formedness of a C99 designated initializer.\n///\n/// Determines whether the designated initializer @p DIE, which\n/// resides at the given @p Index within the initializer list @p\n/// IList, is well-formed for a current object of type @p DeclType\n/// (C99 6.7.8). The actual subobject that this designator refers to\n/// within the current subobject is returned in either\n/// @p NextField or @p NextElementIndex (whichever is appropriate).\n///\n/// @param IList The initializer list in which this designated\n/// initializer occurs.\n///\n/// @param DIE The designated initializer expression.\n///\n/// @param DesigIdx The index of the current designator.\n///\n/// @param CurrentObjectType The type of the \"current object\" (C99 6.7.8p17),\n/// into which the designation in @p DIE should refer.\n///\n/// @param NextField If non-NULL and the first designator in @p DIE is\n/// a field, this will be set to the field declaration corresponding\n/// to the field named by the designator. On input, this is expected to be\n/// the next field that would be initialized in the absence of designation,\n/// if the complete object being initialized is a struct.\n///\n/// @param NextElementIndex If non-NULL and the first designator in @p\n/// DIE is an array designator or GNU array-range designator, this\n/// will be set to the last index initialized by this designator.\n///\n/// @param Index Index into @p IList where the designated initializer\n/// @p DIE occurs.\n///\n/// @param StructuredList The initializer list expression that\n/// describes all of the subobject initializers in the order they\'ll\n/// actually be initialized.\n///\n/// @returns true if there was an error, false otherwise.\nbool InitListChecker::CheckDesignatedInitializer(const InitializedEntity &Entity, InitListExpr *IList, DesignatedInitExpr *DIE, unsigned DesigIdx, QualType &CurrentObjectType, RecordDecl::field_iterator *NextField, llvm::APSInt *NextElementIndex, unsigned &Index, InitListExpr *StructuredList, unsigned &StructuredIndex, bool FinishSubobjectInit, bool TopLevelObject) {\n // ...\n if (isa<ConstantArrayType>(AT)) {\n // ...\n if (DesignatedEndIndex >= MaxElements) {\n if (!VerifyOnly)\n SemaRef.Diag(IndexExpr->getBeginLoc(), diag::err_array_designator_too_large) << toString(DesignatedEndIndex, 10) << toString(MaxElements, 10) << IndexExpr->getSourceRange();"}}, [l]={ ["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:17:4: error: array designator index (10) exceeds array bounds (10)","clang/test/Sema/designated-initializers.c:22:10: error: array designator index (12) exceeds array bounds (10)","clang/test/Sema/designated-initializers.c:47:4: error: array designator index (10) exceeds array bounds (10)"} } }, ["err_array_element_alignment"]={ [c]={{nil,I,"err_array_element_alignment"}}, [d]={{nil,I,"size of array element of type %0 (%1 bytes) isn\'t a multiple of its alignment (%2 bytes)"}}, [e]={{nil,I,"size of array element of type A (B bytes) isn\'t a multiple of its alignment (C bytes)"}}, [f]=k, [g]="size of array element of type (.*?) \\((.*?) bytes\\) isn\'t a multiple of its alignment \\((.*?) bytes\\)", [h]=a, [i]={{nil,I,m}}, [b]={eb,1625925174,gb,hb}, [j]={{p,2448,"bool Sema::checkArrayElementAlignment(QualType EltTy, SourceLocation Loc) {\n // ...\n Diag(Loc, diag::err_array_element_alignment) << EltTy << Size.getQuantity() << Alignment.getQuantity();"}}, [l]={ ["clang/test/Sema/align-x86-64.c"]={"clang/test/Sema/align-x86-64.c:9:19: error: size of array element of type \'UINT192\' (24 bytes) isn\'t a multiple of its alignment (16 bytes)"} } }, ["err_array_incomplete_or_sizeless_type"]={ [c]={{nil,q,"err_array_incomplete_or_sizeless_type"}}, [d]={{nil,q,"array has %select{incomplete|sizeless}0 element type %1"}}, [e]={{nil,q,{"array has ",{"incomplete","sizeless"}," element type B"}}}, [f]=k, [g]="array has (?:incomplete|sizeless) element type (.*?)", [h]=a, [i]={{nil,q,m}}, [b]={Fb,1576908663,Gb,Hb}, [j]={{o,13802,"void Sema::ActOnUninitializedDecl(Decl *RealDecl) {\n // ...\n if (VarDecl *Var = dyn_cast<VarDecl>(RealDecl)) {\n // ...\n case VarDecl::TentativeDefinition:\n // File scope. C99 6.9.2p2: A declaration of an identifier for an\n // object that has file scope without an initializer, and without a\n // storage-class specifier or with the storage-class specifier \"static\",\n // constitutes a tentative definition. Note: A tentative definition with\n // external linkage is valid (C99 6.2.2p5).\n if (!Var->isInvalidDecl()) {\n if (const IncompleteArrayType *ArrayT = Context.getAsIncompleteArrayType(Type)) {\n if (RequireCompleteSizedType(Var->getLocation(), ArrayT->getElementType(), diag::err_array_incomplete_or_sizeless_type))"},{Y,7674,"ExprResult Sema::BuildCompoundLiteralExpr(SourceLocation LParenLoc, TypeSourceInfo *TInfo, SourceLocation RParenLoc, Expr *LiteralExpr) {\n // ...\n if (literalType->isArrayType()) {\n if (RequireCompleteSizedType(LParenLoc, Context.getBaseElementType(literalType), diag::err_array_incomplete_or_sizeless_type, SourceRange(LParenLoc, LiteralExpr->getSourceRange().getEnd())))"},{p,2492,"/// Build an array type.\n///\n/// \\param T The type of each element in the array.\n///\n/// \\param ASM C99 array size modifier (e.g., \'*\', \'static\').\n///\n/// \\param ArraySize Expression describing the size of the array.\n///\n/// \\param Brackets The range from the opening \'[\' to the closing \']\'.\n///\n/// \\param Entity The name of the entity that involves the array\n/// type, if known.\n///\n/// \\returns A suitable array type, if there are no errors. Otherwise,\n/// returns a NULL type.\nQualType Sema::BuildArrayType(QualType T, ArrayType::ArraySizeModifier ASM, Expr *ArraySize, unsigned Quals, SourceRange Brackets, DeclarationName Entity) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n if (T->isVoidType() || T->isIncompleteArrayType()) {\n Diag(Loc, diag::err_array_incomplete_or_sizeless_type) << 0 << T;"},{p,2512,"/// Build an array type.\n///\n/// \\param T The type of each element in the array.\n///\n/// \\param ASM C99 array size modifier (e.g., \'*\', \'static\').\n///\n/// \\param ArraySize Expression describing the size of the array.\n///\n/// \\param Brackets The range from the opening \'[\' to the closing \']\'.\n///\n/// \\param Entity The name of the entity that involves the array\n/// type, if known.\n///\n/// \\returns A suitable array type, if there are no errors. Otherwise,\n/// returns a NULL type.\nQualType Sema::BuildArrayType(QualType T, ArrayType::ArraySizeModifier ASM, Expr *ArraySize, unsigned Quals, SourceRange Brackets, DeclarationName Entity) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n } else {\n // ...\n if (!T.isWebAssemblyReferenceType() && RequireCompleteSizedType(Loc, T, diag::err_array_incomplete_or_sizeless_type))"},{p,2526,"/// Build an array type.\n///\n/// \\param T The type of each element in the array.\n///\n/// \\param ASM C99 array size modifier (e.g., \'*\', \'static\').\n///\n/// \\param ArraySize Expression describing the size of the array.\n///\n/// \\param Brackets The range from the opening \'[\' to the closing \']\'.\n///\n/// \\param Entity The name of the entity that involves the array\n/// type, if known.\n///\n/// \\returns A suitable array type, if there are no errors. Otherwise,\n/// returns a NULL type.\nQualType Sema::BuildArrayType(QualType T, ArrayType::ArraySizeModifier ASM, Expr *ArraySize, unsigned Quals, SourceRange Brackets, DeclarationName Entity) {\n // ...\n if (T->isSizelessType() && !T.isWebAssemblyReferenceType()) {\n Diag(Loc, diag::err_array_incomplete_or_sizeless_type) << 1 << T;"}}, [l]={ ["clang/test/Parser/typeof.c"]={"clang/test/Parser/typeof.c:13:11: error: array has incomplete element type \'void\'"} } }, ["err_array_init_different_type"]={ [c]="err_array_init_different_type", [d]="cannot initialize array %diff{of type $ with array of type $|with different type of array}0,1", [e]={{nil,nil,{"cannot initialize array ",{"of type A with array of type B","with different type of array"}}}}, [f]=k, [g]="cannot initialize array (?:of type (.*?) with array of type (.*?)|with different type of array)", [h]=a, [i]=m, [b]={"e2f943b5cb44",1298399391,"Implement the GNU C extension which permits the initialization of an","Implement the GNU C extension which permits the initialization of an\narray from a constant array compound literal. Fixes PR9261.\n\nllvm-svn: 126230"}, [j]={{L,9611,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_ArrayTypeMismatch:\n case FK_NonConstantArrayInit:\n S.Diag(Kind.getLocation(), (Failure == FK_ArrayTypeMismatch ? diag::err_array_init_different_type : diag::err_array_init_non_constant_array)) << DestType.getNonReferenceType() << OnlyArg->getType() << Args[0]->getSourceRange();"}}, [l]={ ["clang/test/Sema/array-init.c"]={"clang/test/Sema/array-init.c:290:5: error: cannot initialize array of type \'int[5]\' with array of type \'int[3]\'"} } }, ["err_array_init_incompat_wide_string_into_wchar"]={ [c]="err_array_init_incompat_wide_string_into_wchar", [d]="initializing wide char array with incompatible wide string literal", [e]="initializing wide char array with incompatible wide string literal", [f]=k, [g]="initializing wide char array with incompatible wide string literal", [h]=a, [i]=m, [b]={"8f62c5ca22f4",1368615784,"Better diagnostics for string initialization.","Better diagnostics for string initialization.\n\nThis commit improves Clang\'s diagnostics for string initialization.\nWhere it would previously say:\n\n /tmp/a.c:3:9: error: array initializer must be an initializer list\n wchar_t s[] = \"Hi\";\n ^\n /tmp/a.c:4:6: error: array initializer must be an initializer list or string literal\n char t[] = L\"Hi\";\n ^\n\nIt will now say\n\n /tmp/a.c:3:9: error: initializing wide char array with non-wide string literal\n wchar_t s[] = \"Hi\";\n ^\n /tmp/a.c:4:6: error: initializing char array with wide string literal\n char t[] = L\"Hi\";\n ^\n\nAs a bonus, it also fixes the fact that Clang would previously reject\nthis valid C11 code:\n\n char16_t s[] = u\"hi\";\n char32_t t[] = U\"hi\";\n\nbecause it would only recognize the built-in types for char16_t and\nchar32_t, which do not exist in C.\n\nllvm-svn: 181880"}, [j]={{L,9594,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_IncompatWideStringIntoWideChar:\n S.Diag(Kind.getLocation(), diag::err_array_init_incompat_wide_string_into_wchar);"}}, [l]={ ["clang/test/SemaCXX/string-init.cpp"]={"clang/test/SemaCXX/string-init.cpp:12:11: error: initializing wide char array with incompatible wide string literal","clang/test/SemaCXX/string-init.cpp:13:11: error: initializing wide char array with incompatible wide string literal","clang/test/SemaCXX/string-init.cpp:19:12: error: initializing wide char array with incompatible wide string literal","clang/test/SemaCXX/string-init.cpp:20:12: error: initializing wide char array with incompatible wide string literal","clang/test/SemaCXX/string-init.cpp:24:12: error: initializing wide char array with incompatible wide string literal","clang/test/SemaCXX/string-init.cpp:26:12: error: initializing wide char array with incompatible wide string literal"} } }, ["err_array_init_narrow_string_into_wchar"]={ [c]="err_array_init_narrow_string_into_wchar", [d]="initializing wide char array with non-wide string literal", [e]="initializing wide char array with non-wide string literal", [f]=k, [g]="initializing wide char array with non\\-wide string literal", [h]=a, [i]=m, [b]={"8f62c5ca22f4",1368615784,"Better diagnostics for string initialization.","Better diagnostics for string initialization.\n\nThis commit improves Clang\'s diagnostics for string initialization.\nWhere it would previously say:\n\n /tmp/a.c:3:9: error: array initializer must be an initializer list\n wchar_t s[] = \"Hi\";\n ^\n /tmp/a.c:4:6: error: array initializer must be an initializer list or string literal\n char t[] = L\"Hi\";\n ^\n\nIt will now say\n\n /tmp/a.c:3:9: error: initializing wide char array with non-wide string literal\n wchar_t s[] = \"Hi\";\n ^\n /tmp/a.c:4:6: error: initializing char array with wide string literal\n char t[] = L\"Hi\";\n ^\n\nAs a bonus, it also fixes the fact that Clang would previously reject\nthis valid C11 code:\n\n char16_t s[] = u\"hi\";\n char32_t t[] = U\"hi\";\n\nbecause it would only recognize the built-in types for char16_t and\nchar32_t, which do not exist in C.\n\nllvm-svn: 181880"}, [j]={{L,9587,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_NarrowStringIntoWideCharArray:\n S.Diag(Kind.getLocation(), diag::err_array_init_narrow_string_into_wchar);"}}, [l]={ ["clang/test/SemaCXX/string-init.cpp"]={"clang/test/SemaCXX/string-init.cpp:10:11: error: initializing wide char array with non-wide string literal","clang/test/SemaCXX/string-init.cpp:11:11: error: initializing wide char array with non-wide string literal","clang/test/SemaCXX/string-init.cpp:16:12: error: initializing wide char array with non-wide string literal","clang/test/SemaCXX/string-init.cpp:17:12: error: initializing wide char array with non-wide string literal","clang/test/SemaCXX/string-init.cpp:22:12: error: initializing wide char array with non-wide string literal","clang/test/SemaCXX/string-init.cpp:23:12: error: initializing wide char array with non-wide string literal"} } }, ["err_array_init_non_constant_array"]={ [c]="err_array_init_non_constant_array", [d]="cannot initialize array %diff{of type $ with non-constant array of type $|with different type of array}0,1", [e]={{nil,nil,{"cannot initialize array ",{"of type A with non-constant array of type B","with different type of array"}}}}, [f]=k, [g]="cannot initialize array (?:of type (.*?) with non\\-constant array of type (.*?)|with different type of array)", [h]=a, [i]=m, [b]={"e2f943b5cb44",1298399391,"Implement the GNU C extension which permits the initialization of an","Implement the GNU C extension which permits the initialization of an\narray from a constant array compound literal. Fixes PR9261.\n\nllvm-svn: 126230"}, [j]={{L,9612,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_ArrayTypeMismatch:\n case FK_NonConstantArrayInit:\n S.Diag(Kind.getLocation(), (Failure == FK_ArrayTypeMismatch ? diag::err_array_init_different_type : diag::err_array_init_non_constant_array)) << DestType.getNonReferenceType() << OnlyArg->getType() << Args[0]->getSourceRange();"}} }, ["err_array_init_not_init_list"]={ [c]="err_array_init_not_init_list", [d]="array initializer must be an initializer list%select{| or string literal| or wide string literal}0", [e]={{nil,nil,{"array initializer must be an initializer list",{a," or string literal"," or wide string literal"}}}}, [f]=k, [g]="array initializer must be an initializer list(?:| or string literal| or wide string literal)", [h]=a, [i]=m, [b]={"3e1e52782604",1260399737,"Reimplement reference initialization (C++ [dcl.init.ref]) using the","Reimplement reference initialization (C++ [dcl.init.ref]) using the\nnew notion of an \"initialization sequence\", which encapsulates the\ncomputation of the initialization sequence along with diagnostic\ninformation and the capability to turn the computed sequence into an\nexpression. At present, I\'ve only switched one CheckReferenceInit\ncallers over to this new mechanism; more will follow.\n\nAside from (hopefully) being much more true to the standard, the\ndiagnostics provided by this reference-initialization code are a bit\nbetter than before. Some examples:\n\np5-var.cpp:54:12: error: non-const lvalue reference to type \'struct\nDerived\'\n cannot bind to a value of unrelated type \'struct Base\'\n Derived &dr2 = b; // expected-error{{non-const lvalue reference to\n ...\n ^ ~\np5-var.cpp:55:9: error: binding of reference to type \'struct Base\' to\na value of\n type \'struct Base const\' drops qualifiers\n Base &br3 = bc; // expected-error{{drops qualifiers}}\n ^ ~~\n\np5-var.cpp:57:15: error: ambiguous conversion from derived class\n \'struct Diamond\' to base class \'struct Base\':\n struct Diamond -> struct Derived -> struct Base\n struct Diamond -> struct Derived2 -> struct Base\n Base &br5 = diamond; // expected-error{{ambiguous conversion from\n ...\n ^~~~~~~\np5-var.cpp:59:9: error: non-const lvalue reference to type \'long\'\n cannot bind to\n a value of unrelated type \'int\'\n long &lr = i; // expected-error{{non-const lvalue reference to type\n ...\n ^ ~\n\np5-var.cpp:74:9: error: non-const lvalue reference to type \'struct\nBase\' cannot\n bind to a temporary of type \'struct Base\'\n Base &br1 = Base(); // expected-error{{non-const lvalue reference to\n ...\n ^ ~~~~~~\n\np5-var.cpp:102:9: error: non-const reference cannot bind to bit-field\n\'i\'\n int & ir1 = (ib.i); // expected-error{{non-const reference cannot\n ...\n ^ ~~~~~~\np5-var.cpp:98:7: note: bit-field is declared here\n int i : 17; // expected-note{{bit-field is declared here}}\n ^\n\nllvm-svn: 90992"}, [j]={{L,9578,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_ArrayNeedsInitList:\n S.Diag(Kind.getLocation(), diag::err_array_init_not_init_list) << 0;"},{L,9581,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_ArrayNeedsInitListOrStringLiteral:\n S.Diag(Kind.getLocation(), diag::err_array_init_not_init_list) << 1;"},{L,9584,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_ArrayNeedsInitListOrWideStringLiteral:\n S.Diag(Kind.getLocation(), diag::err_array_init_not_init_list) << 2;"}}, [l]={ ["clang/test/SemaCXX/string-init.cpp"]={"clang/test/SemaCXX/string-init.cpp:28:7: error: array initializer must be an initializer list","clang/test/SemaCXX/string-init.cpp:29:7: error: array initializer must be an initializer list","clang/test/SemaCXX/string-init.cpp:30:7: error: array initializer must be an initializer list","clang/test/SemaCXX/string-init.cpp:31:7: error: array initializer must be an initializer list","clang/test/SemaCXX/string-init.cpp:32:7: error: array initializer must be an initializer list","clang/test/SemaCXX/string-init.cpp:36:8: error: array initializer must be an initializer list or string literal","clang/test/SemaCXX/string-init.cpp:37:11: error: array initializer must be an initializer list or wide string literal","clang/test/SemaCXX/string-init.cpp:38:12: error: array initializer must be an initializer list or wide string literal","clang/test/SemaCXX/string-init.cpp:39:12: error: array initializer must be an initializer list or wide string literal"} } }, ["err_array_init_plain_string_into_char8_t"]={ [c]={{nil,A,"err_array_init_plain_string_into_char8_t"}}, [d]={{nil,A,"initializing \'char8_t\' array with plain string literal"}}, [e]={{nil,A,"initializing \'char8_t\' array with plain string literal"}}, [f]=k, [g]="initializing \'char8_t\' array with plain string literal", [h]=a, [i]={{nil,A,m}}, [b]={"3a8244df6fb8",1525150965,"Implement P0482R2, support for char8_t type.","Implement P0482R2, support for char8_t type.\n\nThis is not yet part of any C++ working draft, and so is controlled by the flag\n-fchar8_t rather than a -std= flag. (The GCC implementation is controlled by a\nflag with the same name.)\n\nThis implementation is experimental, and will be removed or revised\nsubstantially to match the proposal as it makes its way through the C++\ncommittee.\n\nllvm-svn: 331244"}, [j]={{L,9598,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_PlainStringIntoUTF8Char:\n S.Diag(Kind.getLocation(), diag::err_array_init_plain_string_into_char8_t);"}}, [l]={ ["clang/test/SemaCXX/char8_t.cpp"]={"clang/test/SemaCXX/char8_t.cpp:9:9: error: initializing \'char8_t\' array with plain string literal"} } }, ["err_array_init_utf8_string_into_char"]={ [c]={{nil,A,"err_array_init_utf8_string_into_char"}}, [d]={{nil,I,"initialization of %select{|signed }0char array with UTF-8 string literal is not permitted by %select{\'-fchar8_t\'|C++20}1"},{E,B,"%select{|ISO C++20 does not permit }0initialization of char array with UTF-8 string literal%select{ is not permitted by \'-fchar8_t\'|}0"},{"7.1",A,"initialization of char array with UTF-8 string literal is not permitted by \'-fchar8_t\'"}}, [e]={{nil,I,{"initialization of ",{a,"signed "},"char array with UTF-8 string literal is not permitted by ",{"\'-fchar8_t\'","C++20"}}},{E,B,{{a,"ISO C++20 does not permit "},"initialization of char array with UTF-8 string literal",{" is not permitted by \'-fchar8_t\'",a}}},{"7.1",A,"initialization of char array with UTF-8 string literal is not permitted by \'-fchar8_t\'"}}, [f]=k, [g]="initialization of (?:|signed )char array with UTF\\-8 string literal is not permitted by (?:\'\\-fchar8_t\'|C\\+\\+20)", [h]=a, [i]={{nil,A,m}}, [b]={"3a8244df6fb8",1525150965,"Implement P0482R2, support for char8_t type.","Implement P0482R2, support for char8_t type.\n\nThis is not yet part of any C++ working draft, and so is controlled by the flag\n-fchar8_t rather than a -std= flag. (The GCC implementation is controlled by a\nflag with the same name.)\n\nThis implementation is experimental, and will be removed or revised\nsubstantially to match the proposal as it makes its way through the C++\ncommittee.\n\nllvm-svn: 331244"}, [j]={{L,9604,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_UTF8StringIntoPlainChar:\n S.Diag(Kind.getLocation(), diag::err_array_init_utf8_string_into_char) << DestType->isSignedIntegerType() << S.getLangOpts().CPlusPlus20;"}}, [l]={ ["clang/test/SemaCXX/char8_t.cpp"]={"clang/test/SemaCXX/char8_t.cpp:19:13: error: initialization of char array with UTF-8 string literal is not permitted by C++20"} } }, ["err_array_init_wide_string_into_char"]={ [c]="err_array_init_wide_string_into_char", [d]="initializing char array with wide string literal", [e]="initializing char array with wide string literal", [f]=k, [g]="initializing char array with wide string literal", [h]=a, [i]=m, [b]={"8f62c5ca22f4",1368615784,"Better diagnostics for string initialization.","Better diagnostics for string initialization.\n\nThis commit improves Clang\'s diagnostics for string initialization.\nWhere it would previously say:\n\n /tmp/a.c:3:9: error: array initializer must be an initializer list\n wchar_t s[] = \"Hi\";\n ^\n /tmp/a.c:4:6: error: array initializer must be an initializer list or string literal\n char t[] = L\"Hi\";\n ^\n\nIt will now say\n\n /tmp/a.c:3:9: error: initializing wide char array with non-wide string literal\n wchar_t s[] = \"Hi\";\n ^\n /tmp/a.c:4:6: error: initializing char array with wide string literal\n char t[] = L\"Hi\";\n ^\n\nAs a bonus, it also fixes the fact that Clang would previously reject\nthis valid C11 code:\n\n char16_t s[] = u\"hi\";\n char32_t t[] = U\"hi\";\n\nbecause it would only recognize the built-in types for char16_t and\nchar32_t, which do not exist in C.\n\nllvm-svn: 181880"}, [j]={{L,9590,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n // ...\n case FK_WideStringIntoCharArray:\n S.Diag(Kind.getLocation(), diag::err_array_init_wide_string_into_char);"}}, [l]={ ["clang/test/SemaCXX/string-init.cpp"]={"clang/test/SemaCXX/string-init.cpp:6:8: error: initializing char array with wide string literal","clang/test/SemaCXX/string-init.cpp:7:8: error: initializing char array with wide string literal","clang/test/SemaCXX/string-init.cpp:8:8: error: initializing char array with wide string literal"} } }, ["err_array_new_needs_size"]={ [c]="err_array_new_needs_size", [d]={{nil,K,"array size must be specified in new expression with no initializer"},{B,nil,"array size must be specified in new expressions"}}, [e]={{nil,K,"array size must be specified in new expression with no initializer"},{B,nil,"array size must be specified in new expressions"}}, [f]=k, [g]="array size must be specified in new expression with no initializer", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{D,1869,"/// Parsed a C++ \'new\' expression (C++ 5.3.4).\n///\n/// E.g.:\n/// @code new (memory) int[size][4] @endcode\n/// or\n/// @code ::new Foo(23, \"hello\") @endcode\n///\n/// \\param StartLoc The first location of the expression.\n/// \\param UseGlobal True if \'new\' was prefixed with \'::\'.\n/// \\param PlacementLParen Opening paren of the placement arguments.\n/// \\param PlacementArgs Placement new arguments.\n/// \\param PlacementRParen Closing paren of the placement arguments.\n/// \\param TypeIdParens If the type is in parens, the source range.\n/// \\param D The type to be allocated, as well as array dimensions.\n/// \\param Initializer The initializing expression or initializer-list, or null\n/// if there is none.\nExprResult Sema::ActOnCXXNew(SourceLocation StartLoc, bool UseGlobal, SourceLocation PlacementLParen, MultiExprArg PlacementArgs, SourceLocation PlacementRParen, SourceRange TypeIdParens, Declarator &D, Expr *Initializer) {\n // ...\n // If the specified type is an array, unwrap it and save the expression.\n if (D.getNumTypeObjects() > 0 && D.getTypeObject(0).Kind == DeclaratorChunk::Array) {\n // ...\n if (!Chunk.Arr.NumElts && !Initializer)\n return ExprError(Diag(Chunk.Loc, diag::err_array_new_needs_size) << D.getSourceRange());"}}, [l]={ ["clang/test/SemaCXX/new-delete.cpp"]={"clang/test/SemaCXX/new-delete.cpp:139:17: error: array size must be specified in new expression with no initializer","clang/test/SemaCXX/new-delete.cpp:141:16: error: array size must be specified in new expression with no initializer"} } }, ["err_array_of_abstract_type"]={ [c]="err_array_of_abstract_type", [d]="array of abstract class type %0", [e]="array of abstract class type A", [f]=k, [g]="array of abstract class type (.*?)", [h]=a, [i]=m, [b]={"7d8072e03860",1272397094,"Diagnose the use of abstract types as array element types. Previously,","Diagnose the use of abstract types as array element types. Previously,\nwe were relying on checking for abstract class types when an array\ntype was actually used to declare a variable, parameter, etc. However,\nwe need to check when the construct the array for, e.g., SFINAE\npurposes (see DR337). Fixes problems with Boost\'s is_abstract type\ntrait. \n\nllvm-svn: 102452"}, [j]={{M,6095,"#include \"clang/AST/TypeLocNodes.def\"\n // ...\n CheckPolymorphic(PointerTypeLoc) CheckPolymorphic(ReferenceTypeLoc) CheckPolymorphic(MemberPointerTypeLoc) CheckPolymorphic(BlockPointerTypeLoc) CheckPolymorphic(AtomicTypeLoc)\n // ...\n // It matched; do some magic.\n // FIXME: These should be at most warnings. See P0929R2, CWG1640, CWG1646.\n if (Sel == Sema::AbstractArrayType) {\n Info.S.Diag(Ctx->getLocation(), diag::err_array_of_abstract_type) << T << TL.getSourceRange();"},{p,2497,"/// Build an array type.\n///\n/// \\param T The type of each element in the array.\n///\n/// \\param ASM C99 array size modifier (e.g., \'*\', \'static\').\n///\n/// \\param ArraySize Expression describing the size of the array.\n///\n/// \\param Brackets The range from the opening \'[\' to the closing \']\'.\n///\n/// \\param Entity The name of the entity that involves the array\n/// type, if known.\n///\n/// \\returns A suitable array type, if there are no errors. Otherwise,\n/// returns a NULL type.\nQualType Sema::BuildArrayType(QualType T, ArrayType::ArraySizeModifier ASM, Expr *ArraySize, unsigned Quals, SourceRange Brackets, DeclarationName Entity) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n if (RequireNonAbstractType(Brackets.getBegin(), T, diag::err_array_of_abstract_type))"}}, [l]={ ["clang/test/CXX/class.derived/class.abstract/p3.cpp"]={"clang/test/CXX/class.derived/class.abstract/p3.cpp:39:9: error: array of abstract class type \'A\'","clang/test/CXX/class.derived/class.abstract/p3.cpp:41:9: error: array of abstract class type \'B\' (aka \'SecretlyAbstract<int>\')","clang/test/CXX/class.derived/class.abstract/p3.cpp:45:9: error: array of abstract class type \'SecretlyAbstract<char>\'","clang/test/CXX/class.derived/class.abstract/p3.cpp:51:13: error: array of abstract class type \'A\'","clang/test/CXX/class.derived/class.abstract/p3.cpp:53:13: error: array of abstract class type \'B\' (aka \'SecretlyAbstract<int>\')"} } }, ["err_array_section_does_not_specify_contiguous_storage"]={ [c]="err_array_section_does_not_specify_contiguous_storage", [d]="array section does not specify contiguous storage", [e]="array section does not specify contiguous storage", [f]=k, [g]="array section does not specify contiguous storage", [h]=a, [i]="OpenMP Issue", [b]={"a9f35cb7d665",1457538365,"[OpenMP] Add support for multidimensional array sections in map clause SEMA.","[OpenMP] Add support for multidimensional array sections in map clause SEMA.\n\nSummary: In some cases it can be proved statically that multidimensional array section refer to contiguous storage and can therefore be allowed in a map clause. This patch adds support for those cases in SEMA.\n\nReviewers: hfinkel, carlo.bertolli, arpith-jacob, kkwli0, ABataev\n\nSubscribers: cfe-commits, fraggamuffin, caomhin\n\nDifferential Revision: http://reviews.llvm.org/D17547\n\nllvm-svn: 263019"}, [j]={{"clang/lib/Sema/SemaOpenMP.cpp",21302,"class MapBaseChecker final : public StmtVisitor<MapBaseChecker, bool> {\n // ...\n bool VisitOMPArraySectionExpr(OMPArraySectionExpr *OASE) {\n // ...\n if (AllowWholeSizeArraySection) {\n // ...\n } else if (DKind == OMPD_target_update && SemaRef.getLangOpts().OpenMP >= 50) {\n // ...\n } else if (AllowUnitySizeArraySection && NotUnity) {\n // ...\n SemaRef.Diag(ELoc, diag::err_array_section_does_not_specify_contiguous_storage) << OASE->getSourceRange();"}}, [l]={ ["clang/test/OpenMP/target_update_to_messages.cpp"]={"clang/test/OpenMP/target_update_to_messages.cpp:82:30: error: array section does not specify contiguous storage"} } }, ["err_array_section_does_not_specify_length"]={ [c]={{nil,r,"err_array_section_does_not_specify_length"}}, [d]={{nil,r,"array section does not specify length for outermost dimension"}}, [e]={{nil,r,"array section does not specify length for outermost dimension"}}, [f]=k, [g]="array section does not specify length for outermost dimension", [h]=a, [i]={{nil,r,"OpenMP Issue"}}, [b]={"61d065e21ff3",1590001902,"Let clang atomic builtins fetch add/sub support floating point types","Let clang atomic builtins fetch add/sub support floating point types\n\nRecently atomicrmw started to support fadd/fsub:\n\nhttps://reviews.llvm.org/D53965\n\nHowever clang atomic builtins fetch add/sub still does not support\nemitting atomicrmw fadd/fsub.\n\nThis patch adds that.\n\nReviewed by: John McCall, Artem Belevich, Matt Arsenault, JF Bastien,\nJames Y Knight, Louis Dionne, Olivier Giroux\n\nDifferential Revision: https://reviews.llvm.org/D71726"}, [j]={{"clang/lib/Sema/SemaOpenMP.cpp",21437,"/// Return the expression of the base of the mappable expression or null if it\n/// cannot be determined and do all the necessary checks to see if the\n/// expression is valid as a standalone mappable expression. In the process,\n/// record all the components of the expression.\nstatic const Expr *checkMapClauseExpressionBase(Sema &SemaRef, Expr *E, OMPClauseMappableExprCommon::MappableExprComponentList &CurComponents, OpenMPClauseKind CKind, OpenMPDirectiveKind DKind, bool NoDiagnose) {\n // ...\n if (Checker.Visit(E->IgnoreParens())) {\n // Check if the highest dimension array section has length specified\n if (SemaRef.getLangOpts().OpenMP >= 50 && !CurComponents.empty() && (CKind == OMPC_to || CKind == OMPC_from)) {\n // ...\n for (; CI != CE; ++CI) {\n // ...\n SemaRef.Diag(ELoc, diag::err_array_section_does_not_specify_length) << ERange;"}}, [l]={ ["clang/test/OpenMP/target_update_messages.cpp"]={"clang/test/OpenMP/target_update_messages.cpp:160:30: error: array section does not specify length for outermost dimension","clang/test/OpenMP/target_update_messages.cpp:162:32: error: array section does not specify length for outermost dimension","clang/test/OpenMP/target_update_messages.cpp:192:30: error: array section does not specify length for outermost dimension","clang/test/OpenMP/target_update_messages.cpp:199:32: error: array section does not specify length for outermost dimension"} } }, ["err_array_size_ambiguous_conversion"]={ [c]="err_array_size_ambiguous_conversion", [d]="ambiguous conversion of array size expression of type %0 to an integral or enumeration type", [e]="ambiguous conversion of array size expression of type A to an integral or enumeration type", [f]=k, [g]="ambiguous conversion of array size expression of type (.*?) to an integral or enumeration type", [h]=a, [i]=m, [b]={"4799d03ce841",1277857243,"Implement C++ DR299, which allows an implicit conversion from a class","Implement C++ DR299, which allows an implicit conversion from a class\ntype to an integral or enumeration type in the size of an array new\nexpression, e.g.,\n\n new int[ConvertibleToInt(10)];\n\nThis is a GNU and C++0x extension.\n\nllvm-svn: 107229"}, [j]={{D,2172,"ExprResult Sema::BuildCXXNew(SourceRange Range, bool UseGlobal, SourceLocation PlacementLParen, MultiExprArg PlacementArgs, SourceLocation PlacementRParen, SourceRange TypeIdParens, QualType AllocType, TypeSourceInfo *AllocTypeInfo, std::optional<Expr *> ArraySize, SourceRange DirectInitRange, Expr *Initializer) {\n // ...\n if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n // ...\n if (getLangOpts().CPlusPlus14) {\n // ...\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n // ...\n SemaDiagnosticBuilder diagnoseAmbiguous(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_ambiguous_conversion) << T; }"}}, [l]={ ["clang/test/SemaCXX/cxx1y-contextual-conversion-tweaks.cpp"]={"clang/test/SemaCXX/cxx1y-contextual-conversion-tweaks.cpp:168:14: error: ambiguous conversion of array size expression of type \'X\' to an integral or enumeration type"} } }, ["err_array_size_explicit_conversion"]={ [c]="err_array_size_explicit_conversion", [d]="array size expression of type %0 requires explicit conversion to type %1", [e]="array size expression of type A requires explicit conversion to type B", [f]=k, [g]="array size expression of type (.*?) requires explicit conversion to type (.*?)", [h]=a, [i]=m, [b]={"4799d03ce841",1277857243,"Implement C++ DR299, which allows an implicit conversion from a class","Implement C++ DR299, which allows an implicit conversion from a class\ntype to an integral or enumeration type in the size of an array new\nexpression, e.g.,\n\n new int[ConvertibleToInt(10)];\n\nThis is a GNU and C++0x extension.\n\nllvm-svn: 107229"}, [j]={{D,2161,"ExprResult Sema::BuildCXXNew(SourceRange Range, bool UseGlobal, SourceLocation PlacementLParen, MultiExprArg PlacementArgs, SourceLocation PlacementRParen, SourceRange TypeIdParens, QualType AllocType, TypeSourceInfo *AllocTypeInfo, std::optional<Expr *> ArraySize, SourceRange DirectInitRange, Expr *Initializer) {\n // ...\n if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n // ...\n if (getLangOpts().CPlusPlus14) {\n // ...\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n // ...\n SemaDiagnosticBuilder diagnoseExplicitConv(Sema &S, SourceLocation Loc, QualType T, QualType ConvTy) override { return S.Diag(Loc, diag::err_array_size_explicit_conversion) << T << ConvTy; }"}}, [l]={ ["clang/test/SemaCXX/explicit.cpp"]={"clang/test/SemaCXX/explicit.cpp:219:5: error: array size expression of type \'NotInt\' requires explicit conversion to type \'int\'"} } }, ["err_array_size_incomplete_type"]={ [c]="err_array_size_incomplete_type", [d]="array size expression has incomplete class type %0", [e]="array size expression has incomplete class type A", [f]=k, [g]="array size expression has incomplete class type (.*?)", [h]=a, [i]=m, [b]={"4799d03ce841",1277857243,"Implement C++ DR299, which allows an implicit conversion from a class","Implement C++ DR299, which allows an implicit conversion from a class\ntype to an integral or enumeration type in the size of an array new\nexpression, e.g.,\n\n new int[ConvertibleToInt(10)];\n\nThis is a GNU and C++0x extension.\n\nllvm-svn: 107229"}, [j]={{D,2155,"ExprResult Sema::BuildCXXNew(SourceRange Range, bool UseGlobal, SourceLocation PlacementLParen, MultiExprArg PlacementArgs, SourceLocation PlacementRParen, SourceRange TypeIdParens, QualType AllocType, TypeSourceInfo *AllocTypeInfo, std::optional<Expr *> ArraySize, SourceRange DirectInitRange, Expr *Initializer) {\n // ...\n if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n // ...\n if (getLangOpts().CPlusPlus14) {\n // ...\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n // ...\n SemaDiagnosticBuilder diagnoseIncomplete(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_incomplete_type) << T << ArraySize->getSourceRange(); }"}} }, ["err_array_size_non_int"]={ [c]="err_array_size_non_int", [d]="size of array has non-integer type %0", [e]="size of array has non-integer type A", [f]=k, [g]="size of array has non\\-integer type (.*?)", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{p,2414,"/// Check whether the specified array bound can be evaluated using the relevant\n/// language rules. If so, returns the possibly-converted expression and sets\n/// SizeVal to the size. If not, but the expression might be a VLA bound,\n/// returns ExprResult(). Otherwise, produces a diagnostic and returns\n/// ExprError().\nstatic ExprResult checkArraySize(Sema &S, Expr *&ArraySize, llvm::APSInt &SizeVal, unsigned VLADiag, bool VLAIsError) {\n // ...\n // If the size is an ICE, it certainly isn\'t a VLA. If we\'re in a GNU mode\n // (like gnu99, but not c99) accept any evaluatable value as an extension.\n class VLADiagnoser : public Sema::VerifyICEDiagnoser {\n // ...\n Sema::SemaDiagnosticBuilder diagnoseNotICEType(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_non_int) << T; }"},{p,2570,"/// Build an array type.\n///\n/// \\param T The type of each element in the array.\n///\n/// \\param ASM C99 array size modifier (e.g., \'*\', \'static\').\n///\n/// \\param ArraySize Expression describing the size of the array.\n///\n/// \\param Brackets The range from the opening \'[\' to the closing \']\'.\n///\n/// \\param Entity The name of the entity that involves the array\n/// type, if known.\n///\n/// \\returns A suitable array type, if there are no errors. Otherwise,\n/// returns a NULL type.\nQualType Sema::BuildArrayType(QualType T, ArrayType::ArraySizeModifier ASM, Expr *ArraySize, unsigned Quals, SourceRange Brackets, DeclarationName Entity) {\n // ...\n // C99 6.7.5.2p1: The size expression shall have integer type.\n // C++11 allows contextual conversions to such types.\n if (!getLangOpts().CPlusPlus11 && ArraySize && !ArraySize->isTypeDependent() && !ArraySize->getType()->isIntegralOrUnscopedEnumerationType()) {\n Diag(ArraySize->getBeginLoc(), diag::err_array_size_non_int) << ArraySize->getType() << ArraySize->getSourceRange();"}}, [l]={ ["clang/test/Sema/vector-ops.c"]={"clang/test/Sema/vector-ops.c:20:14: error: size of array has non-integer type \'v2u\' (vector of 2 \'unsigned int\' values)"} } }, ["err_array_size_not_integral"]={ [c]="err_array_size_not_integral", [d]="array size expression must have integral or %select{|unscoped }0enumeration type, not %1", [e]={{nil,nil,{"array size expression must have integral or ",{a,"unscoped "},"enumeration type, not B"}}}, [f]=k, [g]="array size expression must have integral or (?:|unscoped )enumeration type, not (.*?)", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{D,2149,"ExprResult Sema::BuildCXXNew(SourceRange Range, bool UseGlobal, SourceLocation PlacementLParen, MultiExprArg PlacementArgs, SourceLocation PlacementRParen, SourceRange TypeIdParens, QualType AllocType, TypeSourceInfo *AllocTypeInfo, std::optional<Expr *> ArraySize, SourceRange DirectInitRange, Expr *Initializer) {\n // ...\n if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n // ...\n if (getLangOpts().CPlusPlus14) {\n // ...\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n // ...\n SemaDiagnosticBuilder diagnoseNotInt(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_not_integral) << S.getLangOpts().CPlusPlus11 << T; }"}}, [l]={ ["clang/test/SemaCXX/enum-scoped.cpp"]={"clang/test/SemaCXX/enum-scoped.cpp:44:11: error: array size expression must have integral or unscoped enumeration type, not \'E1\'"} } }, ["err_array_star_in_function_definition"]={ [c]="err_array_star_in_function_definition", [d]="variable length array must be bound in function definition", [e]="variable length array must be bound in function definition", [f]=k, [g]="variable length array must be bound in function definition", [h]=a, [i]=m, [b]={"deb55d512333",1265000569,"Fix for PR5185. C99 [*] VLA notation should be disallowed in function definitions.","Fix for PR5185. C99 [*] VLA notation should be disallowed in function definitions.\n\nllvm-svn: 94972"}, [j]={{t,16617,"static void diagnoseArrayStarInParamType(Sema &S, QualType PType, SourceLocation Loc) {\n // ...\n S.Diag(Loc, diag::err_array_star_in_function_definition);"}}, [l]={ ["clang/test/Sema/crash-invalid-array.c"]={"clang/test/Sema/crash-invalid-array.c:18:14: error: variable length array must be bound in function definition","clang/test/Sema/crash-invalid-array.c:19:15: error: variable length array must be bound in function definition","clang/test/Sema/crash-invalid-array.c:20:15: error: variable length array must be bound in function definition","clang/test/Sema/crash-invalid-array.c:21:15: error: variable length array must be bound in function definition","clang/test/Sema/crash-invalid-array.c:22:15: error: variable length array must be bound in function definition"} } }, ["err_array_star_outside_prototype"]={ [c]="err_array_star_outside_prototype", [d]="star modifier used outside of function prototype", [e]="star modifier used outside of function prototype", [f]=k, [g]="star modifier used outside of function prototype", [h]=a, [i]=m, [b]={"4e2ab5550284",1240783071,"Add a bit more handling for declarations like \"int a[*]\".","Add a bit more handling for declarations like \"int a[*]\".\n\nllvm-svn: 70162"}, [j]={{p,5134,"static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, QualType declSpecType, TypeSourceInfo *TInfo) {\n // ...\n for (unsigned i = 0, e = D.getNumTypeObjects(); i != e; ++i) {\n // ...\n case DeclaratorChunk::Array: {\n // ...\n if (ASM == ArrayType::Star && !D.isPrototypeContext()) {\n // ...\n S.Diag(DeclType.Loc, diag::err_array_star_outside_prototype);"}}, [l]={ ["clang/test/Sema/vla.c"]={"clang/test/Sema/vla.c:47:6: error: star modifier used outside of function prototype"} } }, ["err_array_static_not_outermost"]={ [c]="err_array_static_not_outermost", [d]="%0 used in non-outermost array type derivation", [e]="A used in non-outermost array type derivation", [f]=k, [g]="(.*?) used in non\\-outermost array type derivation", [h]=a, [i]=m, [b]={"420052640f7c",1345016550,"Check for improper use of \'static\' and type qualifiers in array","Check for improper use of \'static\' and type qualifiers in array\ndeclarators.\n\nThey are only allowed for function parameters, and then only on the\noutermost array type derivation.\n\nllvm-svn: 161934"}, [j]={{p,5157,"static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, QualType declSpecType, TypeSourceInfo *TInfo) {\n // ...\n for (unsigned i = 0, e = D.getNumTypeObjects(); i != e; ++i) {\n // ...\n case DeclaratorChunk::Array: {\n // ...\n // C99 6.7.5.2p1: The optional type qualifiers and the keyword static\n // shall appear only in a declaration of a function parameter with an\n // array type, ...\n if (ASM == ArrayType::Static || ATI.TypeQuals) {\n // ...\n // C99 6.7.5.2p1: ... and then only in the outermost array type\n // derivation.\n if (hasOuterPointerLikeChunk(D, chunkIndex)) {\n S.Diag(DeclType.Loc, diag::err_array_static_not_outermost) << (ASM == ArrayType::Static ? \"\'static\'\" : \"type qualifier\");"}}, [l]={ ["clang/test/Sema/static-array.c"]={"clang/test/Sema/static-array.c:50:8: error: \'static\' used in non-outermost array type derivation","clang/test/Sema/static-array.c:53:8: error: type qualifier used in non-outermost array type derivation","clang/test/Sema/static-array.c:55:16: error: \'static\' used in non-outermost array type derivation"} } }, ["err_array_static_outside_prototype"]={ [c]="err_array_static_outside_prototype", [d]="%0 used in array declarator outside of function prototype", [e]="A used in array declarator outside of function prototype", [f]=k, [g]="(.*?) used in array declarator outside of function prototype", [h]=a, [i]=m, [b]={"420052640f7c",1345016550,"Check for improper use of \'static\' and type qualifiers in array","Check for improper use of \'static\' and type qualifiers in array\ndeclarators.\n\nThey are only allowed for function parameters, and then only on the\noutermost array type derivation.\n\nllvm-svn: 161934"}, [j]={{p,5145,"static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, QualType declSpecType, TypeSourceInfo *TInfo) {\n // ...\n for (unsigned i = 0, e = D.getNumTypeObjects(); i != e; ++i) {\n // ...\n case DeclaratorChunk::Array: {\n // ...\n // C99 6.7.5.2p1: The optional type qualifiers and the keyword static\n // shall appear only in a declaration of a function parameter with an\n // array type, ...\n if (ASM == ArrayType::Static || ATI.TypeQuals) {\n if (!(D.isPrototypeContext() || D.getContext() == DeclaratorContext::KNRTypeList)) {\n S.Diag(DeclType.Loc, diag::err_array_static_outside_prototype) << (ASM == ArrayType::Static ? \"\'static\'\" : \"type qualifier\");"}}, [l]={ ["clang/test/Sema/static-array.c"]={"clang/test/Sema/static-array.c:34:15: error: \'static\' used in array declarator outside of function prototype","clang/test/Sema/static-array.c:38:8: error: \'static\' used in array declarator outside of function prototype","clang/test/Sema/static-array.c:40:8: error: type qualifier used in array declarator outside of function prototype","clang/test/Sema/static-array.c:41:8: error: type qualifier used in array declarator outside of function prototype","clang/test/Sema/static-array.c:42:8: error: type qualifier used in array declarator outside of function prototype","clang/test/Sema/static-array.c:44:8: error: \'static\' used in array declarator outside of function prototype"} } }, ["err_array_too_large"]={ [c]="err_array_too_large", [d]="array is too large (%0 elements)", [e]="array is too large (A elements)", [f]=k, [g]="array is too large \\((.*?) elements\\)", [h]=a, [i]=m, [b]={"caa1bf434d93",1282091940,"Emit an error if an array is too large. We\'re slightly more strict","Emit an error if an array is too large. We\'re slightly more strict\nthan GCC 4.2 here when building 32-bit (where GCC will allow\nallocation of an array for which we can\'t get a valid past-the-end\npointer), and emulate its odd behavior in 64-bit where it only allows\n63 bits worth of storage in the array. The former is a correctness\nissue; the latter is harmless in practice (you wouldn\'t be able to use\nsuch an array anyway) and helps us pass a GCC DejaGNU test.\n\nFixes <rdar://problem/8212293>.\n\nllvm-svn: 111338"}, [j]={{o,6611,"/// Attempt to fold a variable-sized type to a constant-sized type, returning\n/// true if we were successful.\nbool Sema::tryToFixVariablyModifiedVarType(TypeSourceInfo *&TInfo, QualType &T, SourceLocation Loc, unsigned FailedFoldDiagID) {\n // ...\n if (SizeIsNegative)\n // ...\n else if (Oversized.getBoolValue())\n Diag(Loc, diag::err_array_too_large) << toString(Oversized, 10);"},{o,6730,"void Sema::CheckTypedefForVariablyModifiedType(Scope *S, TypedefNameDecl *NewTD) {\n // ...\n if (T->isVariablyModifiedType()) {\n // ...\n if (S->getFnParent() == nullptr) {\n // ...\n if (FixedTInfo) {\n // ...\n } else {\n if (SizeIsNegative)\n // ...\n else if (T->isVariableArrayType())\n // ...\n else if (Oversized.getBoolValue())\n Diag(NewTD->getLocation(), diag::err_array_too_large) << toString(Oversized, 10);"},{D,2230,"ExprResult Sema::BuildCXXNew(SourceRange Range, bool UseGlobal, SourceLocation PlacementLParen, MultiExprArg PlacementArgs, SourceLocation PlacementRParen, SourceRange TypeIdParens, QualType AllocType, TypeSourceInfo *AllocTypeInfo, std::optional<Expr *> ArraySize, SourceRange DirectInitRange, Expr *Initializer) {\n // ...\n if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n // ...\n // We\'ve already performed any required implicit conversion to integer or\n // unscoped enumeration type.\n // FIXME: Per CWG1464, we are required to check the value prior to\n // converting to size_t. This will never find a negative array size in\n // C++14 onwards, because Value is always unsigned here!\n if (std::optional<llvm::APSInt> Value = (*ArraySize)->getIntegerConstantExpr(Context)) {\n // ...\n if (!AllocType->isDependentType()) {\n // ...\n if (ActiveSizeBits > ConstantArrayType::getMaxSizeBits(Context))\n return ExprError(Diag((*ArraySize)->getBeginLoc(), diag::err_array_too_large) << toString(*Value, 10) << (*ArraySize)->getSourceRange());"},{p,2660,"/// Build an array type.\n///\n/// \\param T The type of each element in the array.\n///\n/// \\param ASM C99 array size modifier (e.g., \'*\', \'static\').\n///\n/// \\param ArraySize Expression describing the size of the array.\n///\n/// \\param Brackets The range from the opening \'[\' to the closing \']\'.\n///\n/// \\param Entity The name of the entity that involves the array\n/// type, if known.\n///\n/// \\returns A suitable array type, if there are no errors. Otherwise,\n/// returns a NULL type.\nQualType Sema::BuildArrayType(QualType T, ArrayType::ArraySizeModifier ASM, Expr *ArraySize, unsigned Quals, SourceRange Brackets, DeclarationName Entity) {\n // ...\n if (!ArraySize) {\n // ...\n } else if (ArraySize->isTypeDependent() || ArraySize->isValueDependent()) {\n // ...\n } else {\n // ...\n if (!R.isUsable()) {\n // ...\n } else if (!T->isDependentType() && !T->isIncompleteType() && !T->isConstantSizeType()) {\n // ...\n } else {\n // ...\n if (ActiveSizeBits > ConstantArrayType::getMaxSizeBits(Context)) {\n Diag(ArraySize->getBeginLoc(), diag::err_array_too_large) << toString(ConstVal, 10) << ArraySize->getSourceRange();"}}, [l]={ ["clang/test/Sema/offsetof-64.c"]={"clang/test/Sema/offsetof-64.c:16:8: error: array is too large (1152921504606846976 elements)"} } }, ["err_as_qualified_auto_decl"]={ [c]="err_as_qualified_auto_decl", [d]="automatic variable qualified with an address space", [e]="automatic variable qualified with an address space", [f]=k, [g]="automatic variable qualified with an(?:| invalid) address space", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{o,8537,"void Sema::CheckVariableDeclarationType(VarDecl *NewVD) {\n // ...\n // Emit an error if an address space was applied to decl with local storage.\n // This includes arrays of objects with address space qualifiers, but not\n // automatic variables that point to other address spaces.\n // ISO/IEC TR 18037 S5.1.2\n if (!getLangOpts().OpenCL && NewVD->hasLocalStorage() && T.getAddressSpace() != LangAS::Default) {\n Diag(NewVD->getLocation(), diag::err_as_qualified_auto_decl) << 0;"},{o,8638,"void Sema::CheckVariableDeclarationType(VarDecl *NewVD) {\n // ...\n if (getLangOpts().OpenCL) {\n // ...\n // FIXME: Adding local AS in C++ for OpenCL might make sense.\n if (NewVD->isFileVarDecl() || NewVD->isStaticLocal() || NewVD->hasExternalStorage()) {\n // ...\n } else {\n // ...\n if (T.getAddressSpace() == LangAS::opencl_constant || T.getAddressSpace() == LangAS::opencl_local) {\n // ...\n } else if (T.getAddressSpace() != LangAS::opencl_private &&\n // ...\n Diag(NewVD->getLocation(), diag::err_as_qualified_auto_decl) << 1;"}}, [l]={ ["clang/test/SemaHLSL/group_shared.hlsl"]={"clang/test/SemaHLSL/group_shared.hlsl:9:22: error: automatic variable qualified with an address space"} } }, ["err_asm_bad_register_type"]={ [c]="err_asm_bad_register_type", [d]="bad type for named register variable", [e]="bad type for named register variable", [f]=k, [g]="bad type for named register variable", [h]=a, [i]=z, [b]={"2e31e4e47b09",1401986722,"Add pointer types to global named register","Add pointer types to global named register\n\nThis patch adds support for pointer types in global named registers variables.\nIt\'ll be lowered as a pair of read/write_register and inttoptr/ptrtoint calls.\nAlso adds some early checks on types on SemaDecl to avoid the assert.\n\nTests changed accordingly. (PR19837)\n\nllvm-svn: 210274"}, [j]={{o,7969,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // ...\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n // ...\n if (S->getFnParent() != nullptr) {\n // ...\n } else if (SC == SC_Register) {\n // ...\n if (!R->isIntegralType(Context) && !R->isPointerType()) {\n Diag(D.getBeginLoc(), diag::err_asm_bad_register_type);"}}, [l]={ [U]={"clang/test/Sema/asm.c:200:1: error: bad type for named register variable","clang/test/Sema/asm.c:201:1: error: bad type for named register variable"} } }, ["err_asm_duplicate_qual"]={ [c]={{nil,q,"err_asm_duplicate_qual"}}, [d]={{nil,q,"duplicate asm qualifier \'%0\'"}}, [e]={{nil,q,"duplicate asm qualifier \'A\'"}}, [f]=k, [g]="duplicate asm qualifier \'(.*?)\'", [h]=a, [i]={{nil,q,z}}, [b]={"f08df464ae89",1582039343,"[OPENMP50]Add initial support for OpenMP 5.0 iterator.","[OPENMP50]Add initial support for OpenMP 5.0 iterator.\n\nAdded basic parsing/semantic analysis/(de)serialization support for\niterator expression introduced in OpenMP 5.0."}, [j]={{"clang/lib/Parse/ParseStmtAsm.cpp",696,"/// parseGNUAsmQualifierListOpt - Parse a GNU extended asm qualifier list.\n/// asm-qualifier:\n/// volatile\n/// inline\n/// goto\n///\n/// asm-qualifier-list:\n/// asm-qualifier\n/// asm-qualifier-list asm-qualifier\nbool Parser::parseGNUAsmQualifierListOpt(GNUAsmQualifiers &AQ) {\n while (true) {\n // ...\n if (AQ.setAsmQualifier(A))\n Diag(Tok.getLocation(), diag::err_asm_duplicate_qual) << GNUAsmQualifiers::getQualifierName(A);"}}, [l]={ ["clang/test/Parser/asm-qualifiers.c"]={"clang/test/Parser/asm-qualifiers.c:43:16: error: duplicate asm qualifier \'volatile\'","clang/test/Parser/asm-qualifiers.c:44:24: error: duplicate asm qualifier \'volatile\'","clang/test/Parser/asm-qualifiers.c:45:14: error: duplicate asm qualifier \'inline\'","clang/test/Parser/asm-qualifiers.c:46:22: error: duplicate asm qualifier \'inline\'","clang/test/Parser/asm-qualifiers.c:47:12: error: duplicate asm qualifier \'goto\'","clang/test/Parser/asm-qualifiers.c:48:16: error: duplicate asm qualifier \'goto\'"} } }, ["err_asm_empty"]={ [c]="err_asm_empty", [d]="__asm used with no assembly instructions", [e]="__asm used with no assembly instructions", [f]=k, [g]="__asm used with no assembly instructions", [h]=a, [i]=z, [b]={"317be45091d7",1348516679,"Replace an assertion with an error for empty __asm statements.","Replace an assertion with an error for empty __asm statements.\n\nllvm-svn: 164551"}, [j]={{"clang/lib/Parse/ParseStmtAsm.cpp",330,"/// Turn a sequence of our tokens back into a string that we can hand\n/// to the MC asm parser.\nstatic bool buildMSAsmString(Preprocessor &PP, SourceLocation AsmLoc, ArrayRef<Token> AsmToks, SmallVectorImpl<unsigned> &TokOffsets, SmallString<512> &Asm) {\n // ...\n for (unsigned i = 0, e = AsmToks.size(); i < e; ++i) {\n // ...\n // Don\'t actually write \'__asm\' into the assembly stream.\n if (Tok.is(tok::kw_asm)) {\n // Complain about __asm at the end of the stream.\n if (i + 1 == e) {\n PP.Diag(AsmLoc, diag::err_asm_empty);"}}, [l]={ ["clang/test/Sema/ms-inline-asm.c"]={"clang/test/Sema/ms-inline-asm.c:5:2: error: __asm used with no assembly instructions"} } }, ["err_asm_empty_symbolic_operand_name"]={ [c]="err_asm_empty_symbolic_operand_name", [d]="empty symbolic operand name in inline assembly string", [e]="empty symbolic operand name in inline assembly string", [f]=k, [g]="empty symbolic operand name in inline assembly string", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{pb,750,"/// AnalyzeAsmString - Analyze the asm string of the current asm, decomposing\n/// it into pieces. If the asm string is erroneous, emit errors and return\n/// true, otherwise return false.\nunsigned GCCAsmStmt::AnalyzeAsmString(SmallVectorImpl<AsmStringPiece> &Pieces, const ASTContext &C, unsigned &DiagOffs) const {\n // ...\n while (true) {\n // ...\n // Handle operands that have asmSymbolicName (e.g., %x[foo]).\n if (EscapedChar == \'[\') {\n // ...\n if (NameEnd == CurPtr)\n return diag::err_asm_empty_symbolic_operand_name;"}}, [l]={ [U]={"clang/test/Sema/asm.c:81:10: error: empty symbolic operand name in inline assembly string"} } }, ["err_asm_incomplete_type"]={ [c]="err_asm_incomplete_type", [d]="asm operand has incomplete type %0", [e]="asm operand has incomplete type A", [f]=k, [g]="asm operand has incomplete type (.*?)", [h]=a, [i]=z, [b]={"f413f5ed44dd",1367539813,"Move parsing of identifiers in MS-style inline assembly into","Move parsing of identifiers in MS-style inline assembly into\nthe actual parser and support arbitrary id-expressions.\n\nWe\'re actually basically set up to do arbitrary expressions here\nif we wanted to.\n\nAssembly operands permit things like A::x to be written regardless\nof language mode, which forces us to embellish the evaluation\ncontext logic somewhat. The logic here under template instantiation\nis incorrect; we need to preserve the fact that an expression was\nunevaluated. Of course, template instantiation in general is fishy\nhere because we have no way of delaying semantic analysis in the\nMC parser. It\'s all just fishy.\n\nI\'ve also fixed the serialization of MS asm statements.\n\nThis commit depends on an LLVM commit.\n\nllvm-svn: 180976"}, [j]={{C,816,"ExprResult Sema::LookupInlineAsmIdentifier(CXXScopeSpec &SS, SourceLocation TemplateKWLoc, UnqualifiedId &Id, bool IsUnevaluatedContext) {\n // ...\n if (RequireCompleteExprType(Result.get(), diag::err_asm_incomplete_type)) {"},{C,864,"bool Sema::LookupInlineAsmField(StringRef Base, StringRef Member, unsigned &Offset, SourceLocation AsmLoc) {\n // ...\n for (StringRef NextMember : Members) {\n // ...\n if (RequireCompleteType(AsmLoc, QualType(RT, 0), diag::err_asm_incomplete_type))"}} }, ["err_asm_input_duplicate_match"]={ [c]="err_asm_input_duplicate_match", [d]="more than one input constraint matches the same output \'%0\'", [e]="more than one input constraint matches the same output \'A\'", [f]=k, [g]="more than one input constraint matches the same output \'(.*?)\'", [h]=a, [i]=z, [b]={"8e261be91106",1442846460,"Fix assertion in inline assembler IR gen","Fix assertion in inline assembler IR gen\nSeveral inputs may not refer to one output constraint in inline assembler\ninsertions, clang was failing on assertion on such test case.\n\nllvm-svn: 248158"}, [j]={{C,606,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = 0, e = InputConstraintInfos.size(); i != e; ++i) {\n // ...\n if (InputMatchedToOutput[TiedTo] != ~0U) {\n targetDiag(NS->getInputExpr(i)->getBeginLoc(), diag::err_asm_input_duplicate_match) << TiedTo;"}}, [l]={ [U]={"clang/test/Sema/asm.c:292:17: error: more than one input constraint matches the same output \'1\'"} } }, ["err_asm_invalid_escape"]={ [c]="err_asm_invalid_escape", [d]="invalid %% escape in inline assembly string", [e]="invalid % escape in inline assembly string", [f]=k, [g]="invalid % escape in inline assembly string", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{pb,663,"/// AnalyzeAsmString - Analyze the asm string of the current asm, decomposing\n/// it into pieces. If the asm string is erroneous, emit errors and return\n/// true, otherwise return false.\nunsigned GCCAsmStmt::AnalyzeAsmString(SmallVectorImpl<AsmStringPiece> &Pieces, const ASTContext &C, unsigned &DiagOffs) const {\n // ...\n while (true) {\n // ...\n // Escaped \"%\" character in asm string.\n if (CurPtr == StrEnd) {\n // ...\n return diag::err_asm_invalid_escape;"},{pb,701,"/// AnalyzeAsmString - Analyze the asm string of the current asm, decomposing\n/// it into pieces. If the asm string is erroneous, emit errors and return\n/// true, otherwise return false.\nunsigned GCCAsmStmt::AnalyzeAsmString(SmallVectorImpl<AsmStringPiece> &Pieces, const ASTContext &C, unsigned &DiagOffs) const {\n // ...\n while (true) {\n // ...\n if (isLetter(EscapedChar)) {\n if (CurPtr == StrEnd) { // Premature end.\n // ...\n return diag::err_asm_invalid_escape;"},{pb,780,"/// AnalyzeAsmString - Analyze the asm string of the current asm, decomposing\n/// it into pieces. If the asm string is erroneous, emit errors and return\n/// true, otherwise return false.\nunsigned GCCAsmStmt::AnalyzeAsmString(SmallVectorImpl<AsmStringPiece> &Pieces, const ASTContext &C, unsigned &DiagOffs) const {\n // ...\n while (true) {\n // ...\n return diag::err_asm_invalid_escape;"}}, [l]={ [U]={"clang/test/Sema/asm.c:75:9: error: invalid % escape in inline assembly string","clang/test/Sema/asm.c:76:12: error: invalid % escape in inline assembly string","clang/test/Sema/asm.c:135:34: error: invalid % escape in inline assembly string"} } }, ["err_asm_invalid_global_var_reg"]={ [c]="err_asm_invalid_global_var_reg", [d]="register \'%0\' unsuitable for global register variables on this target", [e]="register \'A\' unsuitable for global register variables on this target", [f]=k, [g]="register \'(.*?)\' unsuitable for global register variables on this target", [h]=a, [i]=z, [b]={"8c26ea663d43",1447805728,"Produce a better diagnostic for global register variables.","Produce a better diagnostic for global register variables.\n\nCurrently, when there is a global register variable in a program that\nis bound to an invalid register, clang/llvm prints an error message that\nis not very user-friendly.\n\nThis commit improves the diagnostic and moves the check that used to be\nin the backend to Sema. In addition, it makes changes to error out if\nthe size of the register doesn\'t match the declared variable size.\n\ne.g., volatile register int B asm (\"rbp\");\n\nrdar://problem/23084219\n\nDifferential Revision: http://reviews.llvm.org/D13834\n\nllvm-svn: 253405"}, [j]={{o,7963,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // ...\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n // ...\n if (S->getFnParent() != nullptr) {\n // ...\n } else if (SC == SC_Register) {\n // Global Named register\n if (DeclAttrsMatchCUDAMode(getLangOpts(), NewVD)) {\n // ...\n if (!TI.isValidGCCRegisterName(Label))\n // ...\n else if (!TI.validateGlobalRegisterVariable(Label, Context.getTypeSize(R), HasSizeMismatch))\n Diag(E->getExprLoc(), diag::err_asm_invalid_global_var_reg) << Label;"}}, [l]={ [U]={"clang/test/Sema/asm.c:203:22: error: register \'edi\' unsuitable for global register variables on this target"} } }, ["err_asm_invalid_input_constraint"]={ [c]="err_asm_invalid_input_constraint", [d]="invalid input constraint \'%0\' in asm", [e]="invalid input constraint \'A\' in asm", [f]=k, [g]="invalid input constraint \'(.*?)\' in asm", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{C,368,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n // ...\n if (!Context.getTargetInfo().validateInputConstraint(OutputConstraintInfos, Info)) {\n targetDiag(Literal->getBeginLoc(), diag::err_asm_invalid_input_constraint) << Info.getConstraintStr();"}}, [l]={ ["clang/test/CodeGen/avr/avr-unsupported-inline-asm-constraints.c"]={"clang/test/CodeGen/avr/avr-unsupported-inline-asm-constraints.c:6:36: error: invalid input constraint \'fo\' in asm","clang/test/CodeGen/avr/avr-unsupported-inline-asm-constraints.c:7:36: error: invalid input constraint \'Nd\' in asm"} } }, ["err_asm_invalid_input_size"]={ [c]="err_asm_invalid_input_size", [d]="invalid input size for constraint \'%0\'", [e]="invalid input size for constraint \'A\'", [f]=k, [g]="invalid input size for constraint \'(.*?)\'", [h]=a, [i]=z, [b]={"887b485dbe3d",1352702571,"Check that the input size is correct for the given constraint.","Check that the input size is correct for the given constraint.\n\nThe \'a\', \'c\', and \'d\' constraints on i386 mean a 32-bit register. We cannot\nplace a 64-bit value into the 32-bit register. Error out instead of causing the\ncompiler to spew general badness.\n<rdar://problem/12415959>\n\nllvm-svn: 167717"}, [j]={{C,461,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n // ...\n if (!Context.getTargetInfo().validateInputSize(FeatureMap, Literal->getString(), Size))\n return targetDiag(InputExpr->getBeginLoc(), diag::err_asm_invalid_input_size) << Info.getConstraintStr();"}}, [l]={ ["clang/test/CodeGen/X86/mmx-inline-asm-error.c"]={"clang/test/CodeGen/X86/mmx-inline-asm-error.c:7:30: error: invalid input size for constraint \'y\'"} } }, ["err_asm_invalid_lvalue_in_input"]={ [c]="err_asm_invalid_lvalue_in_input", [d]="invalid lvalue in asm input for constraint \'%0\'", [e]="invalid lvalue in asm input for constraint \'A\'", [f]=k, [g]="invalid lvalue in asm input for constraint \'(.*?)\'", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{C,401,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n // ...\n // Only allow void types for memory constraints.\n if (Info.allowsMemory() && !Info.allowsRegister()) {\n if (CheckAsmLValue(InputExpr, *this))\n return StmtError(Diag(InputExpr->getBeginLoc(), diag::err_asm_invalid_lvalue_in_input) << Info.getConstraintStr() << InputExpr->getSourceRange());"}}, [l]={ [U]={"clang/test/Sema/asm.c:58:24: error: invalid lvalue in asm input for constraint \'m\'","clang/test/Sema/asm.c:60:24: error: invalid lvalue in asm input for constraint \'m\'"} } }, ["err_asm_invalid_lvalue_in_output"]={ [c]="err_asm_invalid_lvalue_in_output", [d]="invalid lvalue in asm output", [e]="invalid lvalue in asm output", [f]=k, [g]="invalid lvalue in asm output", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{C,339,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = 0; i != NumOutputs; i++) {\n // ...\n default:\n return StmtError(Diag(OutputExpr->getBeginLoc(), diag::err_asm_invalid_lvalue_in_output) << OutputExpr->getSourceRange());"}}, [l]={ ["clang/test/SemaCXX/statements.cpp"]={"clang/test/SemaCXX/statements.cpp:25:23: error: invalid lvalue in asm output","clang/test/SemaCXX/statements.cpp:31:21: error: invalid lvalue in asm output"} } }, ["err_asm_invalid_operand_number"]={ [c]="err_asm_invalid_operand_number", [d]="invalid operand number in inline asm string", [e]="invalid operand number in inline asm string", [f]=k, [g]="invalid operand number in inline asm string", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{pb,722,"/// AnalyzeAsmString - Analyze the asm string of the current asm, decomposing\n/// it into pieces. If the asm string is erroneous, emit errors and return\n/// true, otherwise return false.\nunsigned GCCAsmStmt::AnalyzeAsmString(SmallVectorImpl<AsmStringPiece> &Pieces, const ASTContext &C, unsigned &DiagOffs) const {\n // ...\n while (true) {\n // ...\n // Handle operands that don\'t have asmSymbolicName (e.g., %x4).\n if (isDigit(EscapedChar)) {\n // ...\n if (N >= NumOperands) {\n // ...\n return diag::err_asm_invalid_operand_number;"}}, [l]={ [U]={"clang/test/Sema/asm.c:84:9: error: invalid operand number in inline asm string","clang/test/Sema/asm.c:314:15: error: invalid operand number in inline asm string"} } }, ["err_asm_invalid_output_constraint"]={ [c]="err_asm_invalid_output_constraint", [d]="invalid output constraint \'%0\' in asm", [e]="invalid output constraint \'A\' in asm", [f]=k, [g]="invalid output constraint \'(.*?)\' in asm", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{C,277,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = 0; i != NumOutputs; i++) {\n // ...\n if (!Context.getTargetInfo().validateOutputConstraint(Info)) {\n targetDiag(Literal->getBeginLoc(), diag::err_asm_invalid_output_constraint) << Info.getConstraintStr();"}}, [l]={ ["clang/test/Sema/arm-asm.c"]={"clang/test/Sema/arm-asm.c:5:37: error: invalid output constraint \'=&b\' in asm"} } }, ["err_asm_invalid_output_size"]={ [c]="err_asm_invalid_output_size", [d]="invalid output size for constraint \'%0\'", [e]="invalid output size for constraint \'A\'", [f]=k, [g]="invalid output size for constraint \'(.*?)\'", [h]=a, [i]=z, [b]={"974131ea8825",1411064238,"[X86, inlineasm] Check that the output size is correct for the given constraint.","[X86, inlineasm] Check that the output size is correct for the given constraint.\n\nllvm-svn: 218064"}, [j]={{C,346,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = 0; i != NumOutputs; i++) {\n // ...\n if (!Context.getTargetInfo().validateOutputSize(FeatureMap, Literal->getString(), Size)) {\n targetDiag(OutputExpr->getBeginLoc(), diag::err_asm_invalid_output_size) << Info.getConstraintStr();"}}, [l]={ ["clang/test/CodeGen/X86/mmx-inline-asm-error.c"]={"clang/test/CodeGen/X86/mmx-inline-asm-error.c:8:29: error: invalid output size for constraint \'=y\'","clang/test/CodeGen/X86/mmx-inline-asm-error.c:9:33: error: invalid output size for constraint \'+y\'"} } }, ["err_asm_invalid_type"]={ [c]={{nil,q,"err_asm_invalid_type"}}, [d]={{nil,q,"invalid type %0 in asm %select{input|output}1"}}, [e]={{nil,q,{"invalid type A in asm ",{"input","output"}}}}, [f]=k, [g]="invalid type (.*?) in asm (?:input|output)", [h]=a, [i]={{nil,q,z}}, [b]={"60ee88599098",1589228634,"[clang][asm goto][slh] Warn if asm goto + SLH","[clang][asm goto][slh] Warn if asm goto + SLH\n\nSummary:\nAsm goto is not supported by SLH. Warn if an instance of asm goto is detected\nwhile SLH is enabled.\n\nTest included.\n\nReviewed By: jyu2\n\nDifferential Revision: https://reviews.llvm.org/D79743"}, [j]={{C,306,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = 0; i != NumOutputs; i++) {\n // ...\n // Disallow bit-precise integer types, since the backends tend to have\n // difficulties with abnormal sizes.\n if (OutputExpr->getType()->isBitIntType())\n return StmtError(Diag(OutputExpr->getBeginLoc(), diag::err_asm_invalid_type) << OutputExpr->getType() << 0 /*Input*/"},{C,442,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n // ...\n if (InputExpr->getType()->isBitIntType())\n return StmtError(Diag(InputExpr->getBeginLoc(), diag::err_asm_invalid_type) << InputExpr->getType() << 1 /*Output*/"},{C,948,"StmtResult Sema::ActOnMSAsmStmt(SourceLocation AsmLoc, SourceLocation LBraceLoc, ArrayRef<Token> AsmToks, StringRef AsmString, unsigned NumOutputs, unsigned NumInputs, ArrayRef<StringRef> Constraints, ArrayRef<StringRef> Clobbers, ArrayRef<Expr *> Exprs, SourceLocation EndLoc) {\n // ...\n for (uint64_t I = 0; I < NumOutputs + NumInputs; ++I) {\n // ...\n if (E->getType()->isBitIntType()) {\n // ...\n Diag(E->getBeginLoc(), diag::err_asm_invalid_type) << E->getType() << (I < NumOutputs) << E->getSourceRange();"}}, [l]={ ["clang/test/SemaCXX/ext-int-asm.cpp"]={"clang/test/SemaCXX/ext-int-asm.cpp:5:20: error: invalid type \'_BitInt(9)\' in asm input","clang/test/SemaCXX/ext-int-asm.cpp:6:15: error: invalid type \'_BitInt(9)\' in asm output","clang/test/SemaCXX/ext-int-asm.cpp:8:18: error: invalid type \'_BitInt(9)\' in asm input","clang/test/SemaCXX/ext-int-asm.cpp:9:18: error: invalid type \'_BitInt(9)\' in asm output"} } }, ["err_asm_invalid_type_in_input"]={ [c]="err_asm_invalid_type_in_input", [d]="invalid type %0 in asm input for constraint \'%1\'", [e]="invalid type A in asm input for constraint \'B\'", [f]=k, [g]="invalid type (.*?) in asm input for constraint \'(.*?)\'", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{"clang/lib/CodeGen/CGStmt.cpp",2565,"void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) {\n // ...\n for (unsigned i = 0, e = S.getNumOutputs(); i != e; i++) {\n // ...\n if (!Info.allowsMemory() && IsScalarOrAggregate) {\n // ...\n if (llvm::Type *AdjTy = getTargetHooks().adjustInlineAsmType(*this, OutputConstraint, ResultRegTypes.back()))\n // ...\n else {\n CGM.getDiags().Report(S.getAsmLoc(), diag::err_asm_invalid_type_in_input) << OutExpr->getType() << OutputConstraint;"},{"clang/lib/CodeGen/CGStmt.cpp",2694,"void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) {\n // ...\n for (unsigned i = 0, e = S.getNumInputs(); i != e; i++) {\n // ...\n if (llvm::Type *AdjTy = getTargetHooks().adjustInlineAsmType(*this, ReplaceConstraint, Arg->getType()))\n // ...\n else\n CGM.getDiags().Report(S.getAsmLoc(), diag::err_asm_invalid_type_in_input) << InputExpr->getType() << InputConstraint;"},{"clang/lib/Frontend/InterfaceStubFunctionsConsumer.cpp",120,"#endif\n // ...\n if (RDO & IsLate) {\n Instance.getDiagnostics().Report(diag::err_asm_invalid_type_in_input) << \"Generating Interface Stubs is not supported with \""},{"clang/lib/Frontend/InterfaceStubFunctionsConsumer.cpp",234,"#endif\n // ...\n bool HandleNamedDecl(const NamedDecl *ND, MangledSymbols &Symbols, int RDO) {\n // ...\n Instance.getDiagnostics().Report(diag::err_asm_invalid_type_in_input) << \"Expected a function or function template decl.\";"},{C,434,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n // ...\n if (Info.allowsRegister()) {\n if (InputExpr->getType()->isVoidType()) {\n return StmtError(Diag(InputExpr->getBeginLoc(), diag::err_asm_invalid_type_in_input) << InputExpr->getType() << Info.getConstraintStr() << InputExpr->getSourceRange());"}}, [l]={ [U]={"clang/test/Sema/asm.c:8:25: error: invalid type \'void\' in asm input for constraint \'a\'","clang/test/Sema/asm.c:53:24: error: invalid type \'const volatile void\' in asm input for constraint \'r\'","clang/test/Sema/asm.c:57:24: error: invalid type \'void\' in asm input for constraint \'r\'"} } }, ["err_asm_naked_parm_ref"]={ [c]="err_asm_naked_parm_ref", [d]="parameter references not allowed in naked functions", [e]="parameter references not allowed in naked functions", [f]=k, [g]="parameter references not allowed in naked functions", [h]=a, [i]=m, [b]={"93dbeae0f734",1409869008,"Don\'t allow inline asm statements to reference parameters in naked functions","Don\'t allow inline asm statements to reference parameters in naked functions\n\nDifferential Revision: http://reviews.llvm.org/D5183\n\nllvm-svn: 217200"}, [j]={{C,149,"static bool CheckNakedParmReference(Expr *E, Sema &S) {\n // ...\n while (WorkList.size()) {\n // ...\n if (DeclRefExpr *DRE = dyn_cast<DeclRefExpr>(E)) {\n if (isa<ParmVarDecl>(DRE->getDecl())) {\n S.Diag(DRE->getBeginLoc(), diag::err_asm_naked_parm_ref);"}}, [l]={ ["clang/test/Sema/attr-naked.c"]={"clang/test/Sema/attr-naked.c:41:19: error: parameter references not allowed in naked functions","clang/test/Sema/attr-naked.c:48:20: error: parameter references not allowed in naked functions"} } }, ["err_asm_naked_this_ref"]={ [c]="err_asm_naked_this_ref", [d]="\'this\' pointer references not allowed in naked functions", [e]="\'this\' pointer references not allowed in naked functions", [f]=k, [g]="\'this\' pointer references not allowed in naked functions", [h]=a, [i]=m, [b]={"71ac240620c4",1423002958,"Diagnose CXX \'this\' pointer reference in funcs with naked attr","Diagnose CXX \'this\' pointer reference in funcs with naked attr\n\nClang asserts for this pointer reference in asms of naked functions.\nThis patch diagnoses if this pointer reference is used.\n\nDifferential Revision: http://reviews.llvm.org/D7329\n\nllvm-svn: 228052"}, [j]={{C,143,"static bool CheckNakedParmReference(Expr *E, Sema &S) {\n // ...\n while (WorkList.size()) {\n // ...\n if (isa<CXXThisExpr>(E)) {\n S.Diag(E->getBeginLoc(), diag::err_asm_naked_this_ref);"}}, [l]={ ["clang/test/Sema/attr-naked.cpp"]={"clang/test/Sema/attr-naked.cpp:12:28: error: \'this\' pointer references not allowed in naked functions"} } }, ["err_asm_non_addr_value_in_memory_constraint"]={ [c]="err_asm_non_addr_value_in_memory_constraint", [d]="reference to a %select{bit-field|vector element|global register variable}0 in asm %select{input|output}1 with a memory constraint \'%2\'", [e]={{nil,nil,{"reference to a ",{"bit-field","vector element","global register variable"}," in asm ",{"input","output"}," with a memory constraint \'C\'"}}}, [f]=k, [g]="reference to a (?:bit\\-field|vector element|global register variable) in asm (?:input|output) with a memory constraint \'(.*?)\'", [h]=a, [i]=z, [b]={"d9eab9cc130d",1438598290,"Additional fix for PR14269: Crash on vector elements / global register vars in inline assembler.","Additional fix for PR14269: Crash on vector elements / global register vars in inline assembler.\n\nCompiler crashed when vector elements / global register vars were used in inline assembler with \"m\" restriction. This patch fixes this.\n\nDifferential Revision: http://reviews.llvm.org/D10476\n\nllvm-svn: 243870"}, [j]={{C,184,"/// Returns true if given expression is not compatible with inline\n/// assembly\'s memory constraint; false otherwise.\nstatic bool checkExprMemoryConstraintCompat(Sema &S, Expr *E, TargetInfo::ConstraintInfo &Info, bool is_input_expr) {\n // ...\n if (EType != ExprSafeType) {\n S.Diag(E->getBeginLoc(), diag::err_asm_non_addr_value_in_memory_constraint) << EType << is_input_expr << Info.getConstraintStr() << E->getSourceRange();"}}, [l]={ [U]={"clang/test/Sema/asm.c:268:20: error: reference to a bit-field in asm input with a memory constraint \'=rm\'","clang/test/Sema/asm.c:271:18: error: reference to a bit-field in asm output with a memory constraint \'m\'","clang/test/Sema/asm.c:273:20: error: reference to a vector element in asm input with a memory constraint \'=rm\'","clang/test/Sema/asm.c:276:18: error: reference to a vector element in asm output with a memory constraint \'m\'","clang/test/Sema/asm.c:278:20: error: reference to a global register variable in asm input with a memory constraint \'=rm\'","clang/test/Sema/asm.c:281:18: error: reference to a global register variable in asm output with a memory constraint \'m\'"} } }, ["err_asm_operand_wide_string_literal"]={ [c]="err_asm_operand_wide_string_literal", [d]={{nil,s,"cannot use %select{unicode|wide|an empty}0 string literal in \'asm\'"},{K,nil,"cannot use %select{unicode|wide}0 string literal in \'asm\'"}}, [e]={{nil,s,{"cannot use ",{"unicode","wide","an empty"}," string literal in \'asm\'"}},{K,nil,{"cannot use ",{"unicode","wide"}," string literal in \'asm\'"}}}, [f]=k, [g]="cannot use (?:unicode|wide|an empty) string literal in \'asm\'", [h]=a, [i]=V, [b]={"65cdbf58a7dc",1322786146,"Diagnose use of wide string literal in \'asm\' instead of crashing. Fixes <rdar://problem/10465079>.","Diagnose use of wide string literal in \'asm\' instead of crashing. Fixes <rdar://problem/10465079>.\n\nllvm-svn: 145656"}, [j]={{"clang/lib/Parse/Parser.cpp",1632,"/// ParseAsmStringLiteral - This is just a normal string-literal, but is not\n/// allowed to be a wide string, and is not subject to character translation.\n/// Unlike GCC, we also diagnose an empty string literal when parsing for an\n/// asm label as opposed to an asm statement, because such a construct does not\n/// behave well.\n///\n/// [GNU] asm-string-literal:\n/// string-literal\n///\nExprResult Parser::ParseAsmStringLiteral(bool ForAsmLabel) {\n // ...\n if (!AsmString.isInvalid()) {\n // ...\n if (!SL->isOrdinary()) {\n Diag(Tok, diag::err_asm_operand_wide_string_literal) << SL->isWide() << SL->getSourceRange();"},{"clang/lib/Parse/Parser.cpp",1638,"/// ParseAsmStringLiteral - This is just a normal string-literal, but is not\n/// allowed to be a wide string, and is not subject to character translation.\n/// Unlike GCC, we also diagnose an empty string literal when parsing for an\n/// asm label as opposed to an asm statement, because such a construct does not\n/// behave well.\n///\n/// [GNU] asm-string-literal:\n/// string-literal\n///\nExprResult Parser::ParseAsmStringLiteral(bool ForAsmLabel) {\n // ...\n if (!AsmString.isInvalid()) {\n // ...\n if (ForAsmLabel && SL->getString().empty()) {\n Diag(Tok, diag::err_asm_operand_wide_string_literal) << 2 /* an empty */ << SL->getSourceRange();"}}, [l]={ ["clang/test/Parser/asm.c"]={"clang/test/Parser/asm.c:20:24: error: cannot use an empty string literal in \'asm\'","clang/test/Parser/asm.c:29:20: error: cannot use wide string literal in \'asm\'"} } }, ["err_asm_pmf_through_constraint_not_permitted"]={ [c]={{nil,I,"err_asm_pmf_through_constraint_not_permitted"}}, [d]={{nil,I,"cannot pass a pointer-to-member through register-constrained inline assembly parameter"}}, [e]={{nil,I,"cannot pass a pointer-to-member through register-constrained inline assembly parameter"}}, [f]=k, [g]="cannot pass a pointer\\-to\\-member through register\\-constrained inline assembly parameter", [h]=a, [i]={{nil,I,z}}, [b]={eb,1625925174,gb,hb}, [j]={{C,385,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n // ...\n if (InputExpr->getType()->isMemberPointerType())\n return StmtError(Diag(InputExpr->getBeginLoc(), diag::err_asm_pmf_through_constraint_not_permitted) << InputExpr->getSourceRange());"}}, [l]={ ["clang/test/Sema/gnu-asm-pmf.cpp"]={"clang/test/Sema/gnu-asm-pmf.cpp:34:36: error: cannot pass a pointer-to-member through register-constrained inline assembly parameter","clang/test/Sema/gnu-asm-pmf.cpp:36:36: error: cannot pass a pointer-to-member through register-constrained inline assembly parameter","clang/test/Sema/gnu-asm-pmf.cpp:38:36: error: cannot pass a pointer-to-member through register-constrained inline assembly parameter","clang/test/Sema/gnu-asm-pmf.cpp:40:36: error: cannot pass a pointer-to-member through register-constrained inline assembly parameter","clang/test/Sema/gnu-asm-pmf.cpp:42:36: error: cannot pass a pointer-to-member through register-constrained inline assembly parameter","clang/test/Sema/gnu-asm-pmf.cpp:44:36: error: cannot pass a pointer-to-member through register-constrained inline assembly parameter"} } }, ["err_asm_qualifier_ignored"]={ [c]={{nil,q,"err_asm_qualifier_ignored"}}, [d]={{nil,q,"expected \'volatile\', \'inline\', \'goto\', or \'(\'"}}, [e]={{nil,q,"expected \'volatile\', \'inline\', \'goto\', or \'(\'"}}, [f]=k, [g]="expected \'volatile\', \'inline\', \'goto\', or \'\\(\'", [h]=a, [i]={{nil,q,z}}, [b]={"f08df464ae89",1582039343,"[OPENMP50]Add initial support for OpenMP 5.0 iterator.","[OPENMP50]Add initial support for OpenMP 5.0 iterator.\n\nAdded basic parsing/semantic analysis/(de)serialization support for\niterator expression introduced in OpenMP 5.0."}, [j]={{"clang/lib/Parse/ParseStmtAsm.cpp",689,"/// parseGNUAsmQualifierListOpt - Parse a GNU extended asm qualifier list.\n/// asm-qualifier:\n/// volatile\n/// inline\n/// goto\n///\n/// asm-qualifier-list:\n/// asm-qualifier\n/// asm-qualifier-list asm-qualifier\nbool Parser::parseGNUAsmQualifierListOpt(GNUAsmQualifiers &AQ) {\n while (true) {\n // ...\n if (A == GNUAsmQualifiers::AQ_unspecified) {\n if (Tok.isNot(tok::l_paren)) {\n Diag(Tok.getLocation(), diag::err_asm_qualifier_ignored);"}}, [l]={ ["clang/test/Parser/asm-qualifiers.c"]={"clang/test/Parser/asm-qualifiers.c:12:7: error: expected \'volatile\', \'inline\', \'goto\', or \'(\'","clang/test/Parser/asm-qualifiers.c:13:12: error: expected \'volatile\', \'inline\', \'goto\', or \'(\'","clang/test/Parser/asm-qualifiers.c:14:16: error: expected \'volatile\', \'inline\', \'goto\', or \'(\'"} } }, ["err_asm_register_size_mismatch"]={ [c]="err_asm_register_size_mismatch", [d]="size of register \'%0\' does not match variable size", [e]="size of register \'A\' does not match variable size", [f]=k, [g]="size of register \'(.*?)\' does not match variable size", [h]=a, [i]=z, [b]={"8c26ea663d43",1447805728,"Produce a better diagnostic for global register variables.","Produce a better diagnostic for global register variables.\n\nCurrently, when there is a global register variable in a program that\nis bound to an invalid register, clang/llvm prints an error message that\nis not very user-friendly.\n\nThis commit improves the diagnostic and moves the check that used to be\nin the backend to Sema. In addition, it makes changes to error out if\nthe size of the register doesn\'t match the declared variable size.\n\ne.g., volatile register int B asm (\"rbp\");\n\nrdar://problem/23084219\n\nDifferential Revision: http://reviews.llvm.org/D13834\n\nllvm-svn: 253405"}, [j]={{o,7965,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // ...\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n // ...\n if (S->getFnParent() != nullptr) {\n // ...\n } else if (SC == SC_Register) {\n // Global Named register\n if (DeclAttrsMatchCUDAMode(getLangOpts(), NewVD)) {\n // ...\n if (!TI.isValidGCCRegisterName(Label))\n // ...\n else if (!TI.validateGlobalRegisterVariable(Label, Context.getTypeSize(R), HasSizeMismatch))\n // ...\n else if (HasSizeMismatch)\n Diag(E->getExprLoc(), diag::err_asm_register_size_mismatch) << Label;"}}, [l]={ [U]={"clang/test/Sema/asm.c:204:28: error: size of register \'esp\' does not match variable size"} } }, ["err_asm_tying_incompatible_types"]={ [c]="err_asm_tying_incompatible_types", [d]="unsupported inline asm: input with type %diff{$ matching output with type $|}0,1", [e]={{nil,nil,{"unsupported inline asm: input with type ",{"A matching output with type B",a}}}}, [f]=k, [g]="unsupported inline asm\\: input with type (?:(.*?) matching output with type (.*?)|)", [h]=a, [i]=z, [b]={"574428e4db41",1240770144,"implement PR4077: [Linux kernel] inscrutable error on inline asm input/output constraint mismatch","implement PR4077: [Linux kernel] inscrutable error on inline asm input/output constraint mismatch\nBefore we emitted:\n\n$ clang t.c -S -m64 \nllvm: error: Unsupported asm: input constraint with a matching output constraint of incompatible type!\n\nNow we produce:\n$ clang t.c -S -m64 \nt.c:5:40: error: unsupported inline asm: input with type \'unsigned long\' matching output with type \'int\'\n asm volatile(\"foo \" : \"=a\" (a) :\"0\" (b));\n ~~~ ~^~\n\nllvm-svn: 70142"}, [j]={{C,705,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = 0, e = InputConstraintInfos.size(); i != e; ++i) {\n // ...\n targetDiag(InputExpr->getBeginLoc(), diag::err_asm_tying_incompatible_types) << InTy << OutTy << OutputExpr->getSourceRange() << InputExpr->getSourceRange();"}}, [l]={ [U]={"clang/test/Sema/asm.c:91:45: error: unsupported inline asm: input with type \'unsigned long long\' matching output with type \'int\'","clang/test/Sema/asm.c:359:29: error: unsupported inline asm: input with type \'st_size64\' (aka \'struct _st_size64\') matching output with type \'long long\'","clang/test/Sema/asm.c:361:29: error: unsupported inline asm: input with type \'st_size32\' (aka \'struct _st_size32\') matching output with type \'st_size64\' (aka \'struct _st_size64\')","clang/test/Sema/asm.c:366:29: error: unsupported inline asm: input with type \'st_size128\' (aka \'struct _st_size128\') matching output with type \'long long\'"} } }, ["err_asm_unexpected_constraint_alternatives"]={ [c]="err_asm_unexpected_constraint_alternatives", [d]="asm constraint has an unexpected number of alternatives: %0 vs %1", [e]="asm constraint has an unexpected number of alternatives: A vs B", [f]=k, [g]="asm constraint has an unexpected number of alternatives\\: (.*?) vs (.*?)", [h]=a, [i]=z, [b]={"c63fa612e46e",1419826199,"Sema: Forbid inconsistent constraint alternatives","Sema: Forbid inconsistent constraint alternatives\n\nVerify that asm constraints have the same number of alternatives\n\nllvm-svn: 224911"}, [j]={{C,572,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = 0, e = OutputConstraintInfos.size(); i != e; ++i) {\n // ...\n if (NumAlternatives == ~0U) {\n // ...\n } else if (NumAlternatives != AltCount) {\n targetDiag(NS->getOutputExpr(i)->getBeginLoc(), diag::err_asm_unexpected_constraint_alternatives) << NumAlternatives << AltCount;"},{C,587,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n for (unsigned i = 0, e = InputConstraintInfos.size(); i != e; ++i) {\n // ...\n if (NumAlternatives == ~0U) {\n // ...\n } else if (NumAlternatives != AltCount) {\n targetDiag(NS->getInputExpr(i)->getBeginLoc(), diag::err_asm_unexpected_constraint_alternatives) << NumAlternatives << AltCount;"}}, [l]={ [U]={"clang/test/Sema/asm.c:217:21: error: asm constraint has an unexpected number of alternatives: 1 vs 2"} } }, ["err_asm_unknown_register_name"]={ [c]="err_asm_unknown_register_name", [d]="unknown register name \'%0\' in asm", [e]="unknown register name \'A\' in asm", [f]=k, [g]="unknown register name \'(.*?)\' in asm", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{o,7945,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // ...\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n // ...\n if (S->getFnParent() != nullptr) {\n // ...\n case SC_Register:\n // Local Named register\n if (!Context.getTargetInfo().isValidGCCRegisterName(Label) && DeclAttrsMatchCUDAMode(getLangOpts(), getCurFunctionDecl()))\n Diag(E->getExprLoc(), diag::err_asm_unknown_register_name) << Label;"},{o,7959,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // ...\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n // ...\n if (S->getFnParent() != nullptr) {\n // ...\n } else if (SC == SC_Register) {\n // Global Named register\n if (DeclAttrsMatchCUDAMode(getLangOpts(), NewVD)) {\n // ...\n if (!TI.isValidGCCRegisterName(Label))\n Diag(E->getExprLoc(), diag::err_asm_unknown_register_name) << Label;"},{C,475,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n // Check that the clobbers are valid.\n for (unsigned i = 0; i != NumClobbers; i++) {\n // ...\n if (!Context.getTargetInfo().isValidClobber(Clobber)) {\n targetDiag(Literal->getBeginLoc(), diag::err_asm_unknown_register_name) << Clobber;"}}, [l]={ [U]={"clang/test/Sema/asm.c:26:20: error: unknown register name \'foo\' in asm","clang/test/Sema/asm.c:28:20: error: unknown register name \'204\' in asm","clang/test/Sema/asm.c:29:20: error: unknown register name \'-1\' in asm","clang/test/Sema/asm.c:30:20: error: unknown register name \'+1\' in asm","clang/test/Sema/asm.c:116:24: error: unknown register name \'rr_asm\' in asm","clang/test/Sema/asm.c:117:25: error: unknown register name \'%\' in asm","clang/test/Sema/asm.c:129:26: error: unknown register name \'cc\' in asm"} } }, ["err_asm_unknown_symbolic_operand_name"]={ [c]="err_asm_unknown_symbolic_operand_name", [d]="unknown symbolic operand name in inline assembly string", [e]="unknown symbolic operand name in inline assembly string", [f]=k, [g]="unknown symbolic operand name in inline assembly string", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{pb,758,"/// AnalyzeAsmString - Analyze the asm string of the current asm, decomposing\n/// it into pieces. If the asm string is erroneous, emit errors and return\n/// true, otherwise return false.\nunsigned GCCAsmStmt::AnalyzeAsmString(SmallVectorImpl<AsmStringPiece> &Pieces, const ASTContext &C, unsigned &DiagOffs) const {\n // ...\n while (true) {\n // ...\n // Handle operands that have asmSymbolicName (e.g., %x[foo]).\n if (EscapedChar == \'[\') {\n // ...\n if (N == -1) {\n // ...\n return diag::err_asm_unknown_symbolic_operand_name;"}}, [l]={ [U]={"clang/test/Sema/asm.c:79:11: error: unknown symbolic operand name in inline assembly string"} } }, ["err_asm_unterminated_symbolic_operand_name"]={ [c]="err_asm_unterminated_symbolic_operand_name", [d]="unterminated symbolic operand name in inline assembly string", [e]="unterminated symbolic operand name in inline assembly string", [f]=k, [g]="unterminated symbolic operand name in inline assembly string", [h]=a, [i]=z, [b]={v,1237025389,w,u}, [j]={{pb,748,"/// AnalyzeAsmString - Analyze the asm string of the current asm, decomposing\n/// it into pieces. If the asm string is erroneous, emit errors and return\n/// true, otherwise return false.\nunsigned GCCAsmStmt::AnalyzeAsmString(SmallVectorImpl<AsmStringPiece> &Pieces, const ASTContext &C, unsigned &DiagOffs) const {\n // ...\n while (true) {\n // ...\n // Handle operands that have asmSymbolicName (e.g., %x[foo]).\n if (EscapedChar == \'[\') {\n // ...\n if (NameEnd == nullptr)\n return diag::err_asm_unterminated_symbolic_operand_name;"}}, [l]={ [U]={"clang/test/Sema/asm.c:80:10: error: unterminated symbolic operand name in inline assembly string"} } }, ["err_asm_unwind_and_goto"]={ [c]={{nil,y,"err_asm_unwind_and_goto"}}, [d]={{nil,y,"unwind clobber can\'t be used with asm goto"}}, [e]={{nil,y,"unwind clobber can\'t be used with asm goto"}}, [f]=k, [g]="unwind clobber can\'t be used with asm goto", [h]=a, [i]={{nil,y,z}}, [b]={"3dbcea8b957a",1615397021,"Reland [clang] Check unsupported types in expressions","Reland [clang] Check unsupported types in expressions\n\nThis was committed as ec6c847179fd, but then reverted after a failure\nin: https://lab.llvm.org/buildbot/#/builders/84/builds/13983\n\nI was not able to reproduce the problem, but I added an extra check\nfor a NULL QualType just in case.\n\nOriginal comit message:\n\nThe patch adds missing diagnostics for cases like:\n\n float F3 = ((__float128)F1 * (__float128)F2) / 2.0f;\n\nSema::checkDeviceDecl (renamed to checkTypeSupport) is changed to work\nwith a type without the corresponding ValueDecl. It is also refactored\nso that host diagnostics for unsupported types can be added here as\nwell.\n\nDifferential Revision: https://reviews.llvm.org/D109315"}, [j]={{C,490,"StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple, bool IsVolatile, unsigned NumOutputs, unsigned NumInputs, IdentifierInfo **Names, MultiExprArg constraints, MultiExprArg Exprs, Expr *asmString, MultiExprArg clobbers, unsigned NumLabels, SourceLocation RParenLoc) {\n // ...\n // Using unwind clobber and asm-goto together is not supported right now.\n if (UnwindClobberLoc && NumLabels > 0) {\n targetDiag(*UnwindClobberLoc, diag::err_asm_unwind_and_goto);"}} }, ["err_assoc_compatible_types"]={ [c]="err_assoc_compatible_types", [d]="type %0 in generic association compatible with previously specified type %1", [e]="type A in generic association compatible with previously specified type B", [f]=k, [g]="type (.*?) in generic association compatible with previously specified type (.*?)", [h]=a, [i]=m, [b]={"91147596414d",1302827748,"C1X: implement generic selections","C1X: implement generic selections\n\nAs an extension, generic selection support has been added for all\nsupported languages. The syntax is the same as for C1X.\n\nllvm-svn: 129554"}, [j]={{Y,1778,"ExprResult Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc, SourceLocation DefaultLoc, SourceLocation RParenLoc, bool PredicateIsExpr, void *ControllingExprOrType, ArrayRef<TypeSourceInfo *> Types, ArrayRef<Expr *> Exprs) {\n // ...\n for (unsigned i = 0; i < NumAssocs; ++i) {\n // ...\n if (Types[i]) {\n // ...\n if (Types[i]->getType()->isDependentType()) {\n // ...\n } else {\n // ...\n // C11 6.5.1.1p2 \"No two generic associations in the same generic\n // selection shall specify compatible types.\"\n for (unsigned j = i + 1; j < NumAssocs; ++j)\n if (Types[j] && !Types[j]->getType()->isDependentType() && Context.typesAreCompatible(Types[i]->getType(), Types[j]->getType())) {\n Diag(Types[j]->getTypeLoc().getBeginLoc(), diag::err_assoc_compatible_types) << Types[j]->getTypeLoc().getSourceRange() << Types[j]->getType() << Types[i]->getType();"}}, [l]={ ["clang/test/Sema/attr-btf_type_tag.c"]={"clang/test/Sema/attr-btf_type_tag.c:32:19: error: type \'int *\' in generic association compatible with previously specified type \'int __attribute__((btf_type_tag(\"tag1\")))*\' (aka \'int *\')"} } }, ["err_assoc_type_incomplete"]={ [c]="err_assoc_type_incomplete", [d]="type %0 in generic association incomplete", [e]="type A in generic association incomplete", [f]=k, [g]="type (.*?) in generic association incomplete", [h]=a, [i]=m, [b]={"91147596414d",1302827748,"C1X: implement generic selections","C1X: implement generic selections\n\nAs an extension, generic selection support has been added for all\nsupported languages. The syntax is the same as for C1X.\n\nllvm-svn: 129554"}, [j]={{Y,1726,"ExprResult Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc, SourceLocation DefaultLoc, SourceLocation RParenLoc, bool PredicateIsExpr, void *ControllingExprOrType, ArrayRef<TypeSourceInfo *> Types, ArrayRef<Expr *> Exprs) {\n // ...\n for (unsigned i = 0; i < NumAssocs; ++i) {\n // ...\n if (Types[i]) {\n // ...\n if (Types[i]->getType()->isDependentType()) {\n // ...\n } else {\n // ...\n if (ControllingExpr && Types[i]->getType()->isIncompleteType())\n D = diag::err_assoc_type_incomplete;"}}, [l]={ ["clang/test/SemaCXX/generic-selection.cpp"]={"clang/test/SemaCXX/generic-selection.cpp:87:21: error: type \'struct T\' in generic association incomplete"} } }, ["err_assoc_type_nonobject"]={ [c]="err_assoc_type_nonobject", [d]="type %0 in generic association not an object type", [e]="type A in generic association not an object type", [f]=k, [g]="type (.*?) in generic association not an object type", [h]=a, [i]=m, [b]={"91147596414d",1302827748,"C1X: implement generic selections","C1X: implement generic selections\n\nAs an extension, generic selection support has been added for all\nsupported languages. The syntax is the same as for C1X.\n\nllvm-svn: 129554"}, [j]={{Y,1728,"ExprResult Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc, SourceLocation DefaultLoc, SourceLocation RParenLoc, bool PredicateIsExpr, void *ControllingExprOrType, ArrayRef<TypeSourceInfo *> Types, ArrayRef<Expr *> Exprs) {\n // ...\n for (unsigned i = 0; i < NumAssocs; ++i) {\n // ...\n if (Types[i]) {\n // ...\n if (Types[i]->getType()->isDependentType()) {\n // ...\n } else {\n // ...\n if (ControllingExpr && Types[i]->getType()->isIncompleteType())\n // ...\n else if (ControllingExpr && !Types[i]->getType()->isObjectType())\n D = diag::err_assoc_type_nonobject;"}}, [l]={ ["clang/test/Sema/generic-selection.c"]={"clang/test/Sema/generic-selection.c:9:7: error: type \'void ()\' in generic association not an object type"} } }, ["err_assoc_type_variably_modified"]={ [c]="err_assoc_type_variably_modified", [d]="type %0 in generic association is a variably modified type", [e]="type A in generic association is a variably modified type", [f]=k, [g]="type (.*?) in generic association is a variably modified type", [h]=a, [i]=m, [b]={"91147596414d",1302827748,"C1X: implement generic selections","C1X: implement generic selections\n\nAs an extension, generic selection support has been added for all\nsupported languages. The syntax is the same as for C1X.\n\nllvm-svn: 129554"}, [j]={{Y,1730,"ExprResult Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc, SourceLocation DefaultLoc, SourceLocation RParenLoc, bool PredicateIsExpr, void *ControllingExprOrType, ArrayRef<TypeSourceInfo *> Types, ArrayRef<Expr *> Exprs) {\n // ...\n for (unsigned i = 0; i < NumAssocs; ++i) {\n // ...\n if (Types[i]) {\n // ...\n if (Types[i]->getType()->isDependentType()) {\n // ...\n } else {\n // ...\n if (ControllingExpr && Types[i]->getType()->isIncompleteType())\n // ...\n else if (ControllingExpr && !Types[i]->getType()->isObjectType())\n // ...\n else if (Types[i]->getType()->isVariablyModifiedType())\n D = diag::err_assoc_type_variably_modified;"}}, [l]={ ["clang/test/Sema/generic-selection.c"]={"clang/test/Sema/generic-selection.c:10:7: error: type \'int[n]\' in generic association is a variably modified type"} } }, ["err_ast_file_invalid"]={ [c]={{nil,r,"err_ast_file_invalid"}}, [d]={{nil,r,"file \'%1\' is not a valid precompiled %select{PCH|module|AST}0 file"}}, [e]={{nil,r,{"file \'B\' is not a valid precompiled ",{"PCH","module","AST"}," file"}}}, [f]="fatal error\\: ", [g]="file \'(.*?)\' is not a valid precompiled (?:PCH|module|AST) file", [h]=a, [i]={{nil,r,"AST Deserialization Issue"}}, [b]={"a2f2c2f3a463",1605203629,"Serialization: Merge three diagnostics to simplify ASTReader::getInputFile, NFC","Serialization: Merge three diagnostics to simplify ASTReader::getInputFile, NFC\n\nClean up the logic for `err_fe_{pch,module,ast}_file_modified` to use a\n`select` like other ASTReader diagnostics. There should be no\nfunctionality change here, just a cleanup.\n\nDifferential Revision: https://reviews.llvm.org/D91367"}, [j]={{"clang/lib/Serialization/ASTReader.cpp",4643,"ASTReader::ASTReadResult ASTReader::ReadASTCore(StringRef FileName, ModuleKind Type, SourceLocation ImportLoc, ModuleFile *ImportedBy, SmallVectorImpl<ImportedModule> &Loaded, off_t ExpectedSize, time_t ExpectedModTime, ASTFileSignature ExpectedSignature, unsigned ClientLoadCapabilities) {\n // ...\n // Sniff for the signature.\n if (llvm::Error Err = doesntStartWithASTFileMagic(Stream)) {\n Diag(diag::err_ast_file_invalid) << moduleKindForDiagnostic(Type) << FileName << std::move(Err);"}}, [l]={ ["clang/test/Modules/fatal-module-loader-error.m"]={"clang/test/Modules/fatal-module-loader-error.m:12:2: fatal error: file \'/var/jenkins/workspace/llvm_stripf_diag_2/misc/llvm-warnings/llvmorg-17.0.6/build/tools/clang/test/Modules/Output/fatal-module-loader-error.m.tmp/Module.pcm\' is not a valid precompiled module file"} } }, ["err_ast_file_not_found"]={ [c]={{nil,r,"err_ast_file_not_found"}}, [d]={{nil,r,"%select{PCH|module|AST}0 file \'%1\' not found%select{|: %3}2"}}, [e]={{nil,r,{{"PCH","module","AST"}," file \'B\' not found",{a,": D"}}}}, [f]="fatal error\\: ", [g]="(?:PCH|module|AST) file \'(.*?)\' not found(?:|\\: (.*?))", [h]=a, [i]={{nil,r,"AST Deserialization Issue"}}, [b]={"a2f2c2f3a463",1605203629,"Serialization: Merge three diagnostics to simplify ASTReader::getInputFile, NFC","Serialization: Merge three diagnostics to simplify ASTReader::getInputFile, NFC\n\nClean up the logic for `err_fe_{pch,module,ast}_file_modified` to use a\n`select` like other ASTReader diagnostics. There should be no\nfunctionality change here, just a cleanup.\n\nDifferential Revision: https://reviews.llvm.org/D91367"}, [j]={{"clang/lib/Serialization/ASTReader.cpp",4608,"ASTReader::ASTReadResult ASTReader::ReadASTCore(StringRef FileName, ModuleKind Type, SourceLocation ImportLoc, ModuleFile *ImportedBy, SmallVectorImpl<ImportedModule> &Loaded, off_t ExpectedSize, time_t ExpectedModTime, ASTFileSignature ExpectedSignature, unsigned ClientLoadCapabilities) {\n // ...\n case ModuleManager::Missing:\n // ...\n Diag(diag::err_ast_file_not_found) << moduleKindForDiagnostic(Type) << FileName << !ErrorStr.empty() << ErrorStr;"}}, [l]={ ["clang/test/PCH/cxx-chain-function-template.cpp"]={"fatal error: PCH file \'/var/jenkins/workspace/llvm_stripf_diag_2/misc/llvm-warnings/llvmorg-17.0.6/clang/test/PCH/cxx-chain-function-template.cpp.pch0\' not found: module file not found"} } }, ["err_ast_file_out_of_date"]={ [c]={{nil,r,"err_ast_file_out_of_date"}}, [d]={{nil,r,"%select{PCH|module|AST}0 file \'%1\' is out of date and needs to be rebuilt%select{|: %3}2"}}, [e]={{nil,r,{{"PCH","module","AST"}," file \'B\' is out of date and needs to be rebuilt",{a,": D"}}}}, [f]="fatal error\\: ", [g]="(?:PCH|module|AST) file \'(.*?)\' is out of date and needs to be rebuilt(?:|\\: (.*?))", [h]=a, [i]={{nil,r,"AST Deserialization Issue"}}, [b]={"a2f2c2f3a463",1605203629,"Serialization: Merge three diagnostics to simplify ASTReader::getInputFile, NFC","Serialization: Merge three diagnostics to simplify ASTReader::getInputFile, NFC\n\nClean up the logic for `err_fe_{pch,module,ast}_file_modified` to use a\n`select` like other ASTReader diagnostics. There should be no\nfunctionality change here, just a cleanup.\n\nDifferential Revision: https://reviews.llvm.org/D91367"}, [j]={{"clang/lib/Serialization/ASTReader.cpp",4620,"ASTReader::ASTReadResult ASTReader::ReadASTCore(StringRef FileName, ModuleKind Type, SourceLocation ImportLoc, ModuleFile *ImportedBy, SmallVectorImpl<ImportedModule> &Loaded, off_t ExpectedSize, time_t ExpectedModTime, ASTFileSignature ExpectedSignature, unsigned ClientLoadCapabilities) {\n // ...\n case ModuleManager::OutOfDate:\n // ...\n Diag(diag::err_ast_file_out_of_date) << moduleKindForDiagnostic(Type) << FileName << !ErrorStr.empty() << ErrorStr;"}}, [l]={ ["clang/test/Modules/explicit-build.cpp"]={"fatal error: module file \'/var/jenkins/workspace/llvm_stripf_diag_2/misc/llvm-warnings/llvmorg-17.0.6/build/tools/clang/test/Modules/Output/explicit-build.cpp.tmp/b.pcm\' is out of date and needs to be rebuilt: module file out of date"} } }, ["err_at_defs_cxx"]={ [c]="err_at_defs_cxx", [d]="@defs is not supported in Objective-C++", [e]="@defs is not supported in Objective-C++", [f]=k, [g]="@defs is not supported in Objective\\-C\\+\\+", [h]=a, [i]=V, [b]={"23c84767484c",1302801679,"Parse an \'@\' in an Objective-C++ class member specification,","Parse an \'@\' in an Objective-C++ class member specification,\ndiagnosing it as an error rather than looping infinitely. Also,\nexplicitly disallow @defs in Objective-C++. Fixes <rdar://problem/9260136>.\n\nllvm-svn: 129521"}, [j]={{db,2682,"/// ParseCXXClassMemberDeclaration - Parse a C++ class member declaration.\n///\n/// member-declaration:\n/// decl-specifier-seq[opt] member-declarator-list[opt] \';\'\n/// function-definition \';\'[opt]\n/// ::[opt] nested-name-specifier template[opt] unqualified-id \';\'[TODO]\n/// using-declaration [TODO]\n/// [C++0x] static_assert-declaration\n/// template-declaration\n/// [GNU] \'__extension__\' member-declaration\n///\n/// member-declarator-list:\n/// member-declarator\n/// member-declarator-list \',\' member-declarator\n///\n/// member-declarator:\n/// declarator virt-specifier-seq[opt] pure-specifier[opt]\n/// [C++2a] declarator requires-clause\n/// declarator constant-initializer[opt]\n/// [C++11] declarator brace-or-equal-initializer[opt]\n/// identifier[opt] \':\' constant-expression\n///\n/// virt-specifier-seq:\n/// virt-specifier\n/// virt-specifier-seq virt-specifier\n///\n/// virt-specifier:\n/// override\n/// final\n/// [MS] sealed\n///\n/// pure-specifier:\n/// \'= 0\'\n///\n/// constant-initializer:\n/// \'=\' constant-expression\n///\nParser::DeclGroupPtrTy Parser::ParseCXXClassMemberDeclaration(AccessSpecifier AS, ParsedAttributes &AccessAttrs, const ParsedTemplateInfo &TemplateInfo, ParsingDeclRAIIObject *TemplateDiags) {\n if (Tok.is(tok::at)) {\n if (getLangOpts().ObjC && NextToken().isObjCAtKeyword(tok::objc_defs))\n Diag(Tok, diag::err_at_defs_cxx);"}}, [l]={ ["clang/test/Parser/objcxx-at.mm"]={"clang/test/Parser/objcxx-at.mm:9:3: error: @defs is not supported in Objective-C++"} } }, ["err_at_in_class"]={ [c]="err_at_in_class", [d]="unexpected \'@\' in member specification", [e]="unexpected \'@\' in member specification", [f]=k, [g]="unexpected \'@\' in member specification", [h]=a, [i]=V, [b]={"23c84767484c",1302801679,"Parse an \'@\' in an Objective-C++ class member specification,","Parse an \'@\' in an Objective-C++ class member specification,\ndiagnosing it as an error rather than looping infinitely. Also,\nexplicitly disallow @defs in Objective-C++. Fixes <rdar://problem/9260136>.\n\nllvm-svn: 129521"}, [j]={{db,2684,"/// ParseCXXClassMemberDeclaration - Parse a C++ class member declaration.\n///\n/// member-declaration:\n/// decl-specifier-seq[opt] member-declarator-list[opt] \';\'\n/// function-definition \';\'[opt]\n/// ::[opt] nested-name-specifier template[opt] unqualified-id \';\'[TODO]\n/// using-declaration [TODO]\n/// [C++0x] static_assert-declaration\n/// template-declaration\n/// [GNU] \'__extension__\' member-declaration\n///\n/// member-declarator-list:\n/// member-declarator\n/// member-declarator-list \',\' member-declarator\n///\n/// member-declarator:\n/// declarator virt-specifier-seq[opt] pure-specifier[opt]\n/// [C++2a] declarator requires-clause\n/// declarator constant-initializer[opt]\n/// [C++11] declarator brace-or-equal-initializer[opt]\n/// identifier[opt] \':\' constant-expression\n///\n/// virt-specifier-seq:\n/// virt-specifier\n/// virt-specifier-seq virt-specifier\n///\n/// virt-specifier:\n/// override\n/// final\n/// [MS] sealed\n///\n/// pure-specifier:\n/// \'= 0\'\n///\n/// constant-initializer:\n/// \'=\' constant-expression\n///\nParser::DeclGroupPtrTy Parser::ParseCXXClassMemberDeclaration(AccessSpecifier AS, ParsedAttributes &AccessAttrs, const ParsedTemplateInfo &TemplateInfo, ParsingDeclRAIIObject *TemplateDiags) {\n if (Tok.is(tok::at)) {\n if (getLangOpts().ObjC && NextToken().isObjCAtKeyword(tok::objc_defs))\n // ...\n else\n Diag(Tok, diag::err_at_in_class);"}}, [l]={ ["clang/test/Parser/objcxx-at.mm"]={"clang/test/Parser/objcxx-at.mm:14:5: error: unexpected \'@\' in member specification"} } }, ["err_atdef_nonfragile_interface"]={ [c]="err_atdef_nonfragile_interface", [d]="use of @defs is not supported on this architecture and platform", [e]="use of @defs is not supported on this architecture and platform", [f]=k, [g]="use of @defs is not supported on this architecture and platform", [h]=a, [i]=m, [b]={"ece1b2b0e156",1240345721,"Patch to diagnose use of objc\'s @defs in nonfragile abi.","Patch to diagnose use of objc\'s @defs in nonfragile abi.\n\nllvm-svn: 69710"}, [j]={{ib,5110,"/// Called whenever \\@defs(ClassName) is encountered in the source. Inserts the\n/// instance variables of ClassName into Decls.\nvoid Sema::ActOnDefs(Scope *S, Decl *TagD, SourceLocation DeclStart, IdentifierInfo *ClassName, SmallVectorImpl<Decl *> &Decls) {\n // ...\n if (LangOpts.ObjCRuntime.isNonFragile()) {\n Diag(DeclStart, diag::err_atdef_nonfragile_interface);"}}, [l]={ ["clang/test/SemaObjC/sizeof-interface.m"]={"clang/test/SemaObjC/sizeof-interface.m:46:24: error: use of @defs is not supported on this architecture and platform"} } }, ["err_atimport"]={ [c]="err_atimport", [d]="use of \'@import\' when modules are disabled", [e]="use of \'@import\' when modules are disabled", [f]=k, [g]="use of \'@import\' when modules are disabled", [h]=a, [i]=V, [b]={"a773d0861800",1395871363,"Objective-C. Improve diagnostic error for \'@import\' ","Objective-C. Improve diagnostic error for \'@import\' \nwhen modules are disabled. // rdar://15505492\n\nllvm-svn: 204862"}, [j]={{"clang/lib/Parse/ParseObjc.cpp",103,"/// ParseObjCAtDirectives - Handle parts of the external-declaration production:\n/// external-declaration: [C99 6.9]\n/// [OBJC] objc-class-definition\n/// [OBJC] objc-class-declaration\n/// [OBJC] objc-alias-declaration\n/// [OBJC] objc-protocol-definition\n/// [OBJC] objc-method-definition\n/// [OBJC] \'@\' \'end\'\nParser::DeclGroupPtrTy Parser::ParseObjCAtDirectives(ParsedAttributes &DeclAttrs, ParsedAttributes &DeclSpecAttrs) {\n // ...\n case tok::objc_import:\n // ...\n Diag(AtLoc, diag::err_atimport);"}}, [l]={ ["clang/test/Parser/check-objc2-syntax-1.m"]={"clang/test/Parser/check-objc2-syntax-1.m:4:1: error: use of \'@import\' when modules are disabled"} } }, ["err_atomic_builtin_bit_int_prohibit"]={ [c]={{nil,x,"err_atomic_builtin_bit_int_prohibit"}}, [d]={{nil,x,"argument to atomic builtin of type \'_BitInt\' is not supported"}}, [e]={{nil,x,"argument to atomic builtin of type \'_BitInt\' is not supported"}}, [f]=k, [g]="argument to atomic builtin of type \'_BitInt\' is not supported", [h]=a, [i]={{nil,x,m}}, [b]={"f9c3310d32c6",1616787805,"[OPENMP]Fix PR49366: crash on VLAs in task untied regions.","[OPENMP]Fix PR49366: crash on VLAs in task untied regions.\n\nWe need to capture the local variables into a record in task untied\nregions but clang does not support record with VLA data members.\n\nDifferential Revision: https://reviews.llvm.org/D99436"}, [j]={{t,7460,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n if (ValType->isBitIntType()) {\n Diag(Ptr->getExprLoc(), diag::err_atomic_builtin_bit_int_prohibit);"}}, [l]={ ["clang/test/Sema/builtins.c"]={"clang/test/Sema/builtins.c:289:22: error: argument to atomic builtin of type \'_BitInt\' is not supported","clang/test/Sema/builtins.c:297:22: error: argument to atomic builtin of type \'_BitInt\' is not supported"} } }, ["err_atomic_builtin_cannot_be_const"]={ [c]={{nil,A,"err_atomic_builtin_cannot_be_const"}}, [d]={{nil,A,"address argument to atomic builtin cannot be const-qualified (%0 invalid)"}}, [e]={{nil,A,"address argument to atomic builtin cannot be const-qualified (A invalid)"}}, [f]=k, [g]="address argument to atomic builtin cannot be const\\-qualified \\((.*?) invalid\\)", [h]=a, [i]={{nil,A,m}}, [b]={"a383c94ccd63",1525541922,"Disallow pointers to const in __sync_fetch_and_xxx.","Disallow pointers to const in __sync_fetch_and_xxx.\n\nDiagnoses code like:\n\nvoid f(const int *ptr) {\n __sync_fetch_and_add(ptr, 1);\n}\n\nwhich matches the behavior of GCC and ICC.\n\nllvm-svn: 331598"}, [j]={{t,7568,"/// We have a call to a function like __sync_fetch_and_add, which is an\n/// overloaded function based on the pointer type of its first argument.\n/// The main BuildCallExpr routines have already promoted the types of\n/// arguments because all of these calls are prototyped as void(...).\n///\n/// This function goes through and does final semantic checking for these\n/// builtins, as well as generating any warnings.\nExprResult Sema::SemaBuiltinAtomicOverloaded(ExprResult TheCallResult) {\n // ...\n if (ValType.isConstQualified()) {\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_cannot_be_const) << FirstArg->getType() << FirstArg->getSourceRange();"}}, [l]={ ["clang/test/Sema/builtins.c"]={"clang/test/Sema/builtins.c:280:3: error: address argument to atomic builtin cannot be const-qualified (\'const int *\' invalid)"} } }, ["err_atomic_builtin_ext_int_size"]={ [c]={{nil,q,"err_atomic_builtin_ext_int_size"}}, [d]={{nil,q,"Atomic memory operand must have a power-of-two size"}}, [e]={{nil,q,"Atomic memory operand must have a power-of-two size"}}, [f]=k, [g]="Atomic memory operand must have a power\\-of\\-two size", [h]=a, [i]={{nil,q,m}}, [b]={sb,1582847864,Ab,xb}, [j]={{t,7890,"/// We have a call to a function like __sync_fetch_and_add, which is an\n/// overloaded function based on the pointer type of its first argument.\n/// The main BuildCallExpr routines have already promoted the types of\n/// arguments because all of these calls are prototyped as void(...).\n///\n/// This function goes through and does final semantic checking for these\n/// builtins, as well as generating any warnings.\nExprResult Sema::SemaBuiltinAtomicOverloaded(ExprResult TheCallResult) {\n // ...\n if (BitIntValType && !llvm::isPowerOf2_64(BitIntValType->getNumBits())) {\n Diag(FirstArg->getExprLoc(), diag::err_atomic_builtin_ext_int_size);"}}, [l]={ ["clang/test/Sema/builtins.c"]={"clang/test/Sema/builtins.c:285:24: error: Atomic memory operand must have a power-of-two size","clang/test/Sema/builtins.c:287:25: error: Atomic memory operand must have a power-of-two size","clang/test/Sema/builtins.c:313:24: error: Atomic memory operand must have a power-of-two size","clang/test/Sema/builtins.c:315:25: error: Atomic memory operand must have a power-of-two size"} } }, ["err_atomic_builtin_must_be_pointer"]={ [c]="err_atomic_builtin_must_be_pointer", [d]="address argument to atomic builtin must be a pointer (%0 invalid)", [e]="address argument to atomic builtin must be a pointer (A invalid)", [f]=k, [g]="address argument to atomic builtin must be a pointer \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"dc04654697fb",1241765902,"reimplement __sync_* builtins to be variadic and to follow the same","reimplement __sync_* builtins to be variadic and to follow the same\nsemantic rules that gcc and icc use. This implements the variadic\nand concrete versions as builtins and has sema do the \ndisambiguation. There are probably a bunch of details to finish up\nbut this seems like a large monotonic step forward :)\n\nllvm-svn: 71212"}, [j]={{t,3182,"bool Sema::CheckARMBuiltinExclusiveCall(unsigned BuiltinID, CallExpr *TheCall, unsigned MaxWidth) {\n // ...\n if (!pointerType) {\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_must_be_pointer) << PointerArg->getType() << PointerArg->getSourceRange();"},{t,7153,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n if (!pointerType) {\n Diag(ExprRange.getBegin(), diag::err_atomic_builtin_must_be_pointer) << Ptr->getType() << Ptr->getSourceRange();"},{t,7554,"/// We have a call to a function like __sync_fetch_and_add, which is an\n/// overloaded function based on the pointer type of its first argument.\n/// The main BuildCallExpr routines have already promoted the types of\n/// arguments because all of these calls are prototyped as void(...).\n///\n/// This function goes through and does final semantic checking for these\n/// builtins, as well as generating any warnings.\nExprResult Sema::SemaBuiltinAtomicOverloaded(ExprResult TheCallResult) {\n // ...\n if (!pointerType) {\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_must_be_pointer) << FirstArg->getType() << FirstArg->getSourceRange();"}}, [l]={ ["clang/test/SemaCUDA/atomic-ops.cu"]={"clang/test/SemaCUDA/atomic-ops.cu:8:9: error: address argument to atomic builtin must be a pointer (\'int\' invalid)","clang/test/SemaCUDA/atomic-ops.cu:33:3: error: address argument to atomic builtin must be a pointer (\'int\' invalid)","clang/test/SemaCUDA/atomic-ops.cu:67:10: error: address argument to atomic builtin must be a pointer (\'int\' invalid)"} } }, ["err_atomic_builtin_must_be_pointer_intfltptr"]={ [c]="err_atomic_builtin_must_be_pointer_intfltptr", [d]="address argument to atomic builtin must be a pointer to integer, floating-point or pointer (%0 invalid)", [e]="address argument to atomic builtin must be a pointer to integer, floating-point or pointer (A invalid)", [f]=k, [g]="address argument to atomic builtin must be a pointer to integer, floating\\-point or pointer \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"6aacd49094bc",1373968073,"ARM: implement low-level intrinsics for the atomic exclusive operations.","ARM: implement low-level intrinsics for the atomic exclusive operations.\n\nThis adds three overloaded intrinsics to Clang:\n T __builtin_arm_ldrex(const volatile T *addr)\n int __builtin_arm_strex(T val, volatile T *addr)\n void __builtin_arm_clrex()\n\nThe intent is that these do what users would expect when given most sensible\ntypes. Currently, \"sensible\" translates to ints, floats and pointers.\n\nllvm-svn: 186394"}, [j]={{t,3216,"bool Sema::CheckARMBuiltinExclusiveCall(unsigned BuiltinID, CallExpr *TheCall, unsigned MaxWidth) {\n // ...\n // In general, we allow ints, floats and pointers to be loaded and stored.\n if (!ValType->isIntegerType() && !ValType->isAnyPointerType() && !ValType->isBlockPointerType() && !ValType->isFloatingType()) {\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_must_be_pointer_intfltptr) << PointerArg->getType() << PointerArg->getSourceRange();"}}, [l]={ ["clang/test/Sema/builtins-arm64-exclusive.c"]={"clang/test/Sema/builtins-arm64-exclusive.c:23:10: error: address argument to atomic builtin must be a pointer to integer, floating-point or pointer (\'const volatile struct Simple *\' invalid)","clang/test/Sema/builtins-arm64-exclusive.c:47:10: error: address argument to atomic builtin must be a pointer to integer, floating-point or pointer (\'volatile struct Simple *\' invalid)","clang/test/Sema/builtins-arm64-exclusive.c:72:10: error: address argument to atomic builtin must be a pointer to integer, floating-point or pointer (\'const volatile struct Simple *\' invalid)","clang/test/Sema/builtins-arm64-exclusive.c:96:10: error: address argument to atomic builtin must be a pointer to integer, floating-point or pointer (\'volatile struct Simple *\' invalid)"} } }, ["err_atomic_builtin_must_be_pointer_intptr"]={ [c]="err_atomic_builtin_must_be_pointer_intptr", [d]="address argument to atomic builtin must be a pointer to integer or pointer (%0 invalid)", [e]="address argument to atomic builtin must be a pointer to integer or pointer (A invalid)", [f]=k, [g]="address argument to atomic builtin must be a pointer to integer or pointer \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"dc04654697fb",1241765902,"reimplement __sync_* builtins to be variadic and to follow the same","reimplement __sync_* builtins to be variadic and to follow the same\nsemantic rules that gcc and icc use. This implements the variadic\nand concrete versions as builtins and has sema do the \ndisambiguation. There are probably a bunch of details to finish up\nbut this seems like a large monotonic step forward :)\n\nllvm-svn: 71212"}, [j]={{t,7562,"/// We have a call to a function like __sync_fetch_and_add, which is an\n/// overloaded function based on the pointer type of its first argument.\n/// The main BuildCallExpr routines have already promoted the types of\n/// arguments because all of these calls are prototyped as void(...).\n///\n/// This function goes through and does final semantic checking for these\n/// builtins, as well as generating any warnings.\nExprResult Sema::SemaBuiltinAtomicOverloaded(ExprResult TheCallResult) {\n // ...\n if (!ValType->isIntegerType() && !ValType->isAnyPointerType() && !ValType->isBlockPointerType()) {\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_must_be_pointer_intptr) << FirstArg->getType() << FirstArg->getSourceRange();"}} }, ["err_atomic_builtin_pointer_size"]={ [c]="err_atomic_builtin_pointer_size", [d]="address argument to atomic builtin must be a pointer to 1,2,4,8 or 16 byte type (%0 invalid)", [e]="address argument to atomic builtin must be a pointer to 1,2,4,8 or 16 byte type (A invalid)", [f]=k, [g]="address argument to atomic builtin must be a pointer to 1,2,4,8 or 16 byte type \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"dc04654697fb",1241765902,"reimplement __sync_* builtins to be variadic and to follow the same","reimplement __sync_* builtins to be variadic and to follow the same\nsemantic rules that gcc and icc use. This implements the variadic\nand concrete versions as builtins and has sema do the \ndisambiguation. There are probably a bunch of details to finish up\nbut this seems like a large monotonic step forward :)\n\nllvm-svn: 71212"}, [j]={{t,7633,"/// We have a call to a function like __sync_fetch_and_add, which is an\n/// overloaded function based on the pointer type of its first argument.\n/// The main BuildCallExpr routines have already promoted the types of\n/// arguments because all of these calls are prototyped as void(...).\n///\n/// This function goes through and does final semantic checking for these\n/// builtins, as well as generating any warnings.\nExprResult Sema::SemaBuiltinAtomicOverloaded(ExprResult TheCallResult) {\n // ...\n default:\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_pointer_size) << FirstArg->getType() << FirstArg->getSourceRange();"}} }, ["err_atomic_exclusive_builtin_pointer_size"]={ [c]="err_atomic_exclusive_builtin_pointer_size", [d]="address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type (%0 invalid)", [e]="address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type (A invalid)", [f]=k, [g]="address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"6aacd49094bc",1373968073,"ARM: implement low-level intrinsics for the atomic exclusive operations.","ARM: implement low-level intrinsics for the atomic exclusive operations.\n\nThis adds three overloaded intrinsics to Clang:\n T __builtin_arm_ldrex(const volatile T *addr)\n int __builtin_arm_strex(T val, volatile T *addr)\n void __builtin_arm_clrex()\n\nThe intent is that these do what users would expect when given most sensible\ntypes. Currently, \"sensible\" translates to ints, floats and pointers.\n\nllvm-svn: 186394"}, [j]={{t,3224,"bool Sema::CheckARMBuiltinExclusiveCall(unsigned BuiltinID, CallExpr *TheCall, unsigned MaxWidth) {\n // ...\n // But ARM doesn\'t have instructions to deal with 128-bit versions.\n if (Context.getTypeSize(ValType) > MaxWidth) {\n // ...\n Diag(DRE->getBeginLoc(), diag::err_atomic_exclusive_builtin_pointer_size) << PointerArg->getType() << PointerArg->getSourceRange();"}}, [l]={ ["clang/test/Sema/builtins-arm-exclusive.c"]={"clang/test/Sema/builtins-arm-exclusive.c:24:10: error: address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type (\'const volatile __int128 *\' invalid)","clang/test/Sema/builtins-arm-exclusive.c:51:10: error: address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type (\'volatile __int128 *\' invalid)","clang/test/Sema/builtins-arm-exclusive.c:75:10: error: address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type (\'const volatile __int128 *\' invalid)","clang/test/Sema/builtins-arm-exclusive.c:102:10: error: address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type (\'volatile __int128 *\' invalid)"} } }, ["err_atomic_load_store_uses_lib"]={ [c]="err_atomic_load_store_uses_lib", [d]="atomic %select{load|store}0 requires runtime support that is not available for this target", [e]={{nil,nil,{qb,{"load","store"}," requires runtime support that is not available for this target"}}}, [f]=k, [g]="atomic (?:load|store) requires runtime support that is not available for this target", [h]=a, [i]=m, [b]={"615de765abde",1369762659,"Patch to issue error when target of MacOS and iOS ","Patch to issue error when target of MacOS and iOS \ndoes not support large load/store of atomic objects.\n// rdar://13973577\n\nllvm-svn: 182781"}, [j]={{t,7452,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n if ((Op == AtomicExpr::AO__c11_atomic_load || Op == AtomicExpr::AO__c11_atomic_store || Op == AtomicExpr::AO__opencl_atomic_load || Op == AtomicExpr::AO__hip_atomic_load || Op == AtomicExpr::AO__opencl_atomic_store || Op == AtomicExpr::AO__hip_atomic_store) && Context.AtomicUsesUnsupportedLibcall(AE))\n Diag(AE->getBeginLoc(), diag::err_atomic_load_store_uses_lib) << ((Op == AtomicExpr::AO__c11_atomic_load || Op == AtomicExpr::AO__opencl_atomic_load || Op == AtomicExpr::AO__hip_atomic_load) ? 0 : 1);"}}, [l]={ ["clang/test/Sema/atomic-requires-library-error.c"]={"clang/test/Sema/atomic-requires-library-error.c:17:3: error: atomic store requires runtime support that is not available for this target","clang/test/Sema/atomic-requires-library-error.c:26:18: error: atomic load requires runtime support that is not available for this target"} } }, ["err_atomic_op_has_invalid_synch_scope"]={ [c]={{nil,X,"err_atomic_op_has_invalid_synch_scope"}}, [d]={{nil,X,"synchronization scope argument to atomic operation is invalid"}}, [e]={{nil,X,"synchronization scope argument to atomic operation is invalid"}}, [f]=k, [g]="synchronization scope argument to atomic operation is invalid", [h]=a, [i]={{nil,X,m}}, [b]={"39195062c20c",1501870591,"Add OpenCL 2.0 atomic builtin functions as Clang builtin","Add OpenCL 2.0 atomic builtin functions as Clang builtin\n\nOpenCL 2.0 atomic builtin functions have a scope argument which is ideally\nrepresented as synchronization scope argument in LLVM atomic instructions.\n\nClang supports translating Clang atomic builtin functions to LLVM atomic\ninstructions. However it currently does not support synchronization scope\nof LLVM atomic instructions. Without this, users have to use LLVM assembly\ncode to implement OpenCL atomic builtin functions.\n\nThis patch adds OpenCL 2.0 atomic builtin functions as Clang builtin\nfunctions, which supports generating LLVM atomic instructions with\nsynchronization scope operand.\n\nCurrently only constant memory scope argument is supported. Support of\nnon-constant memory scope argument will be added later.\n\nDifferential Revision: https://reviews.llvm.org/D28691\n\nllvm-svn: 310082"}, [j]={{t,7436,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n if (auto ScopeModel = AtomicExpr::getScopeModel(Op)) {\n // ...\n if (std::optional<llvm::APSInt> Result = Scope->getIntegerConstantExpr(Context)) {\n if (!ScopeModel->isValid(Result->getZExtValue()))\n Diag(Scope->getBeginLoc(), diag::err_atomic_op_has_invalid_synch_scope) << Scope->getSourceRange();"}}, [l]={ ["clang/test/SemaCUDA/atomic-ops.cu"]={"clang/test/SemaCUDA/atomic-ops.cu:9:36: error: synchronization scope argument to atomic operation is invalid","clang/test/SemaCUDA/atomic-ops.cu:15:51: error: synchronization scope argument to atomic operation is invalid","clang/test/SemaCUDA/atomic-ops.cu:34:34: error: synchronization scope argument to atomic operation is invalid","clang/test/SemaCUDA/atomic-ops.cu:40:49: error: synchronization scope argument to atomic operation is invalid","clang/test/SemaCUDA/atomic-ops.cu:68:62: error: synchronization scope argument to atomic operation is invalid"} } }, ["err_atomic_op_needs_atomic"]={ [c]="err_atomic_op_needs_atomic", [d]="address argument to atomic operation must be a pointer to _Atomic type (%0 invalid)", [e]="address argument to atomic operation must be a pointer to _Atomic type (A invalid)", [f]=k, [g]="address argument to atomic operation must be a pointer to _Atomic type \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"df14b3a8377f",1318299601,"Initial implementation of __atomic_* (everything except __atomic_is_lock_free).","Initial implementation of __atomic_* (everything except __atomic_is_lock_free).\n\nllvm-svn: 141632"}, [j]={{t,7163,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n if (IsC11) {\n if (!AtomTy->isAtomicType()) {\n Diag(ExprRange.getBegin(), diag::err_atomic_op_needs_atomic) << Ptr->getType() << Ptr->getSourceRange();"}}, [l]={ ["clang/test/SemaOpenCL/atomic-ops.cl"]={"clang/test/SemaOpenCL/atomic-ops.cl:27:3: error: address argument to atomic operation must be a pointer to _Atomic type (\'__generic int *\' invalid)","clang/test/SemaOpenCL/atomic-ops.cl:33:3: error: address argument to atomic operation must be a pointer to _Atomic type (\'__generic int *\' invalid)","clang/test/SemaOpenCL/atomic-ops.cl:52:20: error: address argument to atomic operation must be a pointer to _Atomic type (\'__generic int *\' invalid)"} } }, ["err_atomic_op_needs_atomic_int"]={ [c]={{nil,s,"err_atomic_op_needs_atomic_int"}}, [d]={{nil,s,"address argument to atomic operation must be a pointer to %select{|atomic }0integer (%1 invalid)"}}, [e]={{nil,s,{"address argument to atomic operation must be a pointer to ",{a,qb},"integer (B invalid)"}}}, [f]=k, [g]="address argument to atomic operation must be a pointer to (?:|atomic )integer \\((.*?) invalid\\)", [h]=a, [i]={{nil,s,m}}, [b]={"c094e7dc4b3f",1573050950,"[SYCL] Add sycl_kernel attribute for accelerated code outlining","[SYCL] Add sycl_kernel attribute for accelerated code outlining\n\nSYCL is single source offload programming model relying on compiler to\nseparate device code (i.e. offloaded to an accelerator) from the code\nexecuted on the host.\n\nHere is code example of the SYCL program to demonstrate compiler\noutlining work:\n\n```\nint foo(int x) { return ++x; }\nint bar(int x) { throw std::exception(\"CPU code only!\"); }\n...\nusing namespace cl::sycl;\nqueue Q;\nbuffer<int, 1> a(range<1>{1024});\nQ.submit([&](handler& cgh) {\n auto A = a.get_access<access::mode::write>(cgh);\n cgh.parallel_for<init_a>(range<1>{1024}, [=](id<1> index) {\n A[index] = index[0] + foo(42);\n });\n}\n...\n```\n\nSYCL device compiler must compile lambda expression passed to\ncl::sycl::handler::parallel_for method and function foo called from this\nlambda expression for an \"accelerator\". SYCL device compiler also must\nignore bar function as it\'s not required for offloaded code execution.\n\nThis patch adds the sycl_kernel attribute, which is used to mark code\npassed to cl::sycl::handler::parallel_for as \"accelerated code\".\n\nAttribute must be applied to function templates which parameters include\nat least \"kernel name\" and \"kernel function object\". These parameters\nwill be used to establish an ABI between the host application and\noffloaded part.\n\nReviewers: jlebar, keryell, Naghasan, ABataev, Anastasia, bader, aaron.ballman, rjmccall, rsmith\n\nReviewed By: keryell, bader\n\nSubscribers: mgorny, OlegM, ArturGainullin, agozillon, aaron.ballman, ebevhan, Anastasia, cfe-commits\n\nTags: #clang\n\nDifferential Revision: https://reviews.llvm.org/D60455\n\nSigned-off-by: Alexey Bader <alexey.bader@intel.com>"}, [j]={{t,7207,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n // For an arithmetic operation, the implied arithmetic must be well-formed.\n if (Form == Arithmetic) {\n // ...\n if (!IsAllowedValueType(ValType, ArithAllows)) {\n auto DID = ArithAllows & AOEVT_FP ? (ArithAllows & AOEVT_Pointer ? diag::err_atomic_op_needs_atomic_int_ptr_or_fp : diag::err_atomic_op_needs_atomic_int_or_fp) : diag::err_atomic_op_needs_atomic_int;"}}, [l]={ ["clang/test/SemaOpenCL/atomic-ops.cl"]={"clang/test/SemaOpenCL/atomic-ops.cl:60:3: error: address argument to atomic operation must be a pointer to atomic integer (\'__generic atomic_float *\' (aka \'__generic _Atomic(float) *\') invalid)"} } }, ["err_atomic_op_needs_atomic_int_or_fp"]={ [c]="err_atomic_op_needs_atomic_int_or_fp", [d]="address argument to atomic operation must be a pointer to %select{|atomic }0integer or supported floating point type (%1 invalid)", [e]={{nil,nil,{"address argument to atomic operation must be a pointer to ",{a,qb},"integer or supported floating point type (B invalid)"}}}, [f]=k, [g]="address argument to atomic operation must be a pointer to (?:|atomic )integer or supported floating point type \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={eb,1625925174,gb,hb}, [j]={{t,7206,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n // For an arithmetic operation, the implied arithmetic must be well-formed.\n if (Form == Arithmetic) {\n // ...\n if (!IsAllowedValueType(ValType, ArithAllows)) {\n auto DID = ArithAllows & AOEVT_FP ? (ArithAllows & AOEVT_Pointer ? diag::err_atomic_op_needs_atomic_int_ptr_or_fp : diag::err_atomic_op_needs_atomic_int_or_fp) : diag::err_atomic_op_needs_atomic_int;"}}, [l]={ ["clang/test/Sema/atomic-ops.c"]={"clang/test/Sema/atomic-ops.c:203:3: error: address argument to atomic operation must be a pointer to atomic integer or supported floating point type (\'_Atomic(int *) *\' invalid)","clang/test/Sema/atomic-ops.c:208:3: error: address argument to atomic operation must be a pointer to atomic integer or supported floating point type (\'_Atomic(int *) *\' invalid)","clang/test/Sema/atomic-ops.c:222:3: error: address argument to atomic operation must be a pointer to integer or supported floating point type (\'int **\' invalid)"} } }, ["err_atomic_op_needs_atomic_int_or_ptr"]={ [c]="err_atomic_op_needs_atomic_int_or_ptr", [d]="address argument to atomic operation must be a pointer to %select{|atomic }0integer or pointer (%1 invalid)", [e]={{nil,nil,{"address argument to atomic operation must be a pointer to ",{a,qb},"integer or pointer (B invalid)"}}}, [f]=k, [g]="address argument to atomic operation must be a pointer to (?:|atomic )integer or pointer \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"df14b3a8377f",1318299601,"Initial implementation of __atomic_* (everything except __atomic_is_lock_free).","Initial implementation of __atomic_* (everything except __atomic_is_lock_free).\n\nllvm-svn: 141632"}, [j]={{t,7220,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n // For an arithmetic operation, the implied arithmetic must be well-formed.\n if (Form == Arithmetic) {\n // ...\n } else if (IsN && !ValType->isIntegerType() && !ValType->isPointerType()) {\n // ...\n Diag(ExprRange.getBegin(), diag::err_atomic_op_needs_atomic_int_or_ptr) << IsC11 << Ptr->getType() << Ptr->getSourceRange();"}}, [l]={ ["clang/test/Sema/atomic-ops.c"]={"clang/test/Sema/atomic-ops.c:152:20: error: address argument to atomic operation must be a pointer to integer or pointer (\'double *\' invalid)","clang/test/Sema/atomic-ops.c:153:3: error: address argument to atomic operation must be a pointer to integer or pointer (\'struct S *\' invalid)","clang/test/Sema/atomic-ops.c:176:3: error: address argument to atomic operation must be a pointer to integer or pointer (\'_Atomic(int) *\' invalid)","clang/test/Sema/atomic-ops.c:177:3: error: address argument to atomic operation must be a pointer to integer or pointer (\'struct S *\' invalid)","clang/test/Sema/atomic-ops.c:187:20: error: address argument to atomic operation must be a pointer to integer or pointer (\'_Atomic(int) *\' invalid)"} } }, ["err_atomic_op_needs_atomic_int_ptr_or_fp"]={ [c]={{nil,y,"err_atomic_op_needs_atomic_int_ptr_or_fp"}}, [d]={{nil,y,"address argument to atomic operation must be a pointer to %select{|atomic }0integer, pointer or supported floating point type (%1 invalid)"}}, [e]={{nil,y,{"address argument to atomic operation must be a pointer to ",{a,qb},"integer, pointer or supported floating point type (B invalid)"}}}, [f]=k, [g]="address argument to atomic operation must be a pointer to (?:|atomic )integer, pointer or supported floating point type \\((.*?) invalid\\)", [h]=a, [i]={{nil,y,m}}, [b]={"61d065e21ff3",1590001902,"Let clang atomic builtins fetch add/sub support floating point types","Let clang atomic builtins fetch add/sub support floating point types\n\nRecently atomicrmw started to support fadd/fsub:\n\nhttps://reviews.llvm.org/D53965\n\nHowever clang atomic builtins fetch add/sub still does not support\nemitting atomicrmw fadd/fsub.\n\nThis patch adds that.\n\nReviewed by: John McCall, Artem Belevich, Matt Arsenault, JF Bastien,\nJames Y Knight, Louis Dionne, Olivier Giroux\n\nDifferential Revision: https://reviews.llvm.org/D71726"}, [j]={{t,7205,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n // For an arithmetic operation, the implied arithmetic must be well-formed.\n if (Form == Arithmetic) {\n // ...\n if (!IsAllowedValueType(ValType, ArithAllows)) {\n auto DID = ArithAllows & AOEVT_FP ? (ArithAllows & AOEVT_Pointer ? diag::err_atomic_op_needs_atomic_int_ptr_or_fp : diag::err_atomic_op_needs_atomic_int_or_fp) : diag::err_atomic_op_needs_atomic_int;"}}, [l]={ ["clang/test/Sema/atomic-ops.c"]={"clang/test/Sema/atomic-ops.c:213:3: error: address argument to atomic operation must be a pointer to integer, pointer or supported floating point type (\'_Atomic(int) *\' invalid)","clang/test/Sema/atomic-ops.c:217:3: error: address argument to atomic operation must be a pointer to integer, pointer or supported floating point type (\'struct S *\' invalid)"} } }, ["err_atomic_op_needs_non_const_atomic"]={ [c]="err_atomic_op_needs_non_const_atomic", [d]={{nil,X,"address argument to atomic operation must be a pointer to non-%select{const|constant}0 _Atomic type (%1 invalid)"},{T,nil,"address argument to atomic operation must be a pointer to non-const _Atomic type (%0 invalid)"}}, [e]={{nil,X,{"address argument to atomic operation must be a pointer to non-",{"const","constant"}," _Atomic type (B invalid)"}},{T,nil,"address argument to atomic operation must be a pointer to non-const _Atomic type (A invalid)"}}, [f]=k, [g]="address argument to atomic operation must be a pointer to non\\-(?:const|constant) _Atomic type \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"e00921a0a448",1347689398,"const _Atomic(T) is not an atomic type, so do not allow it as the type \'A\' in","const _Atomic(T) is not an atomic type, so do not allow it as the type \'A\' in\nC11 7.17\'s atomic operations. GNU\'s __atomic_* builtins do allow const-qualified\natomics, though (!!) so don\'t restrict those.\n\nllvm-svn: 163964"}, [j]={{t,7169,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n if (IsC11) {\n // ...\n if ((Form != Load && Form != LoadCopy && AtomTy.isConstQualified()) || AtomTy.getAddressSpace() == LangAS::opencl_constant) {\n Diag(ExprRange.getBegin(), diag::err_atomic_op_needs_non_const_atomic) << (AtomTy.isConstQualified() ? 0 : 1) << Ptr->getType() << Ptr->getSourceRange();"}}, [l]={ ["clang/test/SemaOpenCL/atomic-ops.cl"]={"clang/test/SemaOpenCL/atomic-ops.cl:28:3: error: address argument to atomic operation must be a pointer to non-const _Atomic type (\'const __generic atomic_int *\' (aka \'const __generic _Atomic(int) *\') invalid)","clang/test/SemaOpenCL/atomic-ops.cl:35:3: error: address argument to atomic operation must be a pointer to non-const _Atomic type (\'const __generic atomic_int *\' (aka \'const __generic _Atomic(int) *\') invalid)","clang/test/SemaOpenCL/atomic-ops.cl:39:3: error: address argument to atomic operation must be a pointer to non-constant _Atomic type (\'__constant atomic_int *\' (aka \'__constant _Atomic(int) *\') invalid)","clang/test/SemaOpenCL/atomic-ops.cl:45:3: error: address argument to atomic operation must be a pointer to non-constant _Atomic type (\'__constant atomic_int *\' (aka \'__constant _Atomic(int) *\') invalid)","clang/test/SemaOpenCL/atomic-ops.cl:82:3: error: address argument to atomic operation must be a pointer to non-const _Atomic type (\'const __generic atomic_int *\' (aka \'const __generic _Atomic(int) *\') invalid)","clang/test/SemaOpenCL/atomic-ops.cl:83:3: error: address argument to atomic operation must be a pointer to non-const _Atomic type (\'const __generic atomic_int *\' (aka \'const __generic _Atomic(int) *\') invalid)"} } }, ["err_atomic_op_needs_non_const_pointer"]={ [c]="err_atomic_op_needs_non_const_pointer", [d]="address argument to atomic operation must be a pointer to non-const type (%0 invalid)", [e]="address argument to atomic operation must be a pointer to non-const type (A invalid)", [f]=k, [g]="address argument to atomic operation must be a pointer to non\\-const type \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"a3a7c56143f4",1443917462,"Diagnose const atomics in __atomic builtins.","Diagnose const atomics in __atomic builtins.\n\nDiagnose when a pointer to const T is used as the first argument in at atomic\nbuiltin unless that builtin is a load operation. This is already checked for\nC11 atomics builtins but not for __atomic ones.\n\nThis patch was given the LGTM by rsmith when it was part\nof a larger review. (See http://reviews.llvm.org/D10407)\n\nllvm-svn: 249252"}, [j]={{t,7177,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n if (IsC11) {\n // ...\n } else if (Form != Load && Form != LoadCopy) {\n if (ValType.isConstQualified()) {\n Diag(ExprRange.getBegin(), diag::err_atomic_op_needs_non_const_pointer) << Ptr->getType() << Ptr->getSourceRange();"}}, [l]={ ["clang/test/Sema/builtins.c"]={"clang/test/Sema/builtins.c:281:3: error: address argument to atomic operation must be a pointer to non-const type (\'const int *\' invalid)"} } }, ["err_atomic_op_needs_trivial_copy"]={ [c]="err_atomic_op_needs_trivial_copy", [d]="address argument to atomic operation must be a pointer to a trivially-copyable type (%0 invalid)", [e]="address argument to atomic operation must be a pointer to a trivially-copyable type (A invalid)", [f]=k, [g]="address argument to atomic operation must be a pointer to a trivially\\-copyable type \\((.*?) invalid\\)", [h]=a, [i]=m, [b]={"feea883de4e5",1334207297,"Implement support for 18 of the GNU-compatible __atomic builtins.","Implement support for 18 of the GNU-compatible __atomic builtins.\n\nThis is not quite sufficient for libstdc++\'s <atomic>: we still need\n__atomic_test_and_set and __atomic_clear, and may need a more complete\n__atomic_is_lock_free implementation.\n\nWe are also missing an implementation of __atomic_always_lock_free,\n__atomic_nand_fetch, and __atomic_fetch_nand, but those aren\'t needed\nfor libstdc++.\n\nllvm-svn: 154579"}, [j]={{t,7231,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // ...\n if (!IsC11 && !AtomTy.isTriviallyCopyableType(Context) && !AtomTy->isScalarType()) {\n // ...\n Diag(ExprRange.getBegin(), diag::err_atomic_op_needs_trivial_copy) << Ptr->getType() << Ptr->getSourceRange();"}}, [l]={ ["clang/test/Sema/atomic-ops.c"]={"clang/test/Sema/atomic-ops.c:156:3: error: address argument to atomic operation must be a pointer to a trivially-copyable type (\'_Atomic(int) *\' invalid)","clang/test/Sema/atomic-ops.c:183:3: error: address argument to atomic operation must be a pointer to a trivially-copyable type (\'_Atomic(int) *\' invalid)"} } }, ["err_atomic_property_nontrivial_assign_op"]={ [c]="err_atomic_property_nontrivial_assign_op", [d]="atomic property of reference type %0 cannot have non-trivial assignment operator", [e]="atomic property of reference type A cannot have non-trivial assignment operator", [f]=k, [g]="atomic property of reference type (.*?) cannot have non\\-trivial assignment operator", [h]=a, [i]=m, [b]={"a08a74705bb0",1326155821,"objc++: patch for IRgen for atomic properties of","objc++: patch for IRgen for atomic properties of\nc++ objects with non-trivial assignment/copy functions.\nAlso, one additional sema check. // rdar://6137845\n\nllvm-svn: 147817"}, [j]={{mb,1547,"/// ActOnPropertyImplDecl - This routine performs semantic checks and\n/// builds the AST node for a property implementation declaration; declared\n/// as \\@synthesize or \\@dynamic.\n///\nDecl *Sema::ActOnPropertyImplDecl(Scope *S, SourceLocation AtLoc, SourceLocation PropertyLoc, bool Synthesize, IdentifierInfo *PropertyId, IdentifierInfo *PropertyIvar, SourceLocation PropertyIvarLoc, ObjCPropertyQueryKind QueryKind) {\n // ...\n if (ObjCMethodDecl *setterMethod = property->getSetterMethodDecl()) {\n // ...\n if (getLangOpts().CPlusPlus && Synthesize && !CompleteTypeErr && Ivar->getType()->isRecordType()) {\n // ...\n if (property->getPropertyAttributes() & ObjCPropertyAttribute::kind_atomic) {\n // ...\n if (const CXXOperatorCallExpr *CXXCE = dyn_cast_or_null<CXXOperatorCallExpr>(callExpr))\n if (const FunctionDecl *FuncDecl = CXXCE->getDirectCallee())\n if (!FuncDecl->isTrivial())\n if (property->getType()->isReferenceType()) {\n Diag(PropertyDiagLoc, diag::err_atomic_property_nontrivial_assign_op) << property->getType();"}}, [l]={ ["clang/test/SemaObjCXX/property-synthesis-error.mm"]={"clang/test/SemaObjCXX/property-synthesis-error.mm:70:13: error: atomic property of reference type \'const TCPPObject &\' cannot have non-trivial assignment operator","clang/test/SemaObjCXX/property-synthesis-error.mm:102:1: error: atomic property of reference type \'TemplateClass2<int &> &\' cannot have non-trivial assignment operator"} } }, ["err_atomic_specifier_bad_type"]={ [c]="err_atomic_specifier_bad_type", [d]={{nil,q,"_Atomic cannot be applied to %select{incomplete |array |function |reference |atomic |qualified |sizeless ||integer }0type %1 %select{|||||||which is not trivially copyable|}0"},{s,nil,"_Atomic cannot be applied to %select{incomplete |array |function |reference |atomic |qualified |}0type %1 %select{||||||which is not trivially copyable}0"}}, [e]={{nil,q,{"_Atomic cannot be applied to ",{"incomplete ","array ","function ","reference ",qb,"qualified ","sizeless ",a,"integer "},"type B ",{a,a,a,a,a,a,a,"which is not trivially copyable",a}}},{s,nil,{"_Atomic cannot be applied to ",{"incomplete ","array ","function ","reference ",qb,"qualified ",a},"type B ",{a,a,a,a,a,a,"which is not trivially copyable"}}}}, [f]=k, [g]="_Atomic cannot be applied to (?:incomplete |array |function |reference |atomic |qualified |sizeless ||integer )type (.*?) (?:|||||||which is not trivially copyable|)", [h]=a, [i]=m, [b]={"0dfb889575a6",1317942033,"Support for C1x _Atomic specifier (see testcase). This is primarily being committed at the moment t...","Support for C1x _Atomic specifier (see testcase). This is primarily being committed at the moment to help support C++0x <atomic>, but it should be a solid base for implementing the full specification of C1x _Atomic.\n\nThanks to Jeffrey Yasskin for the thorough review!\n\nllvm-svn: 141330"}, [j]={{p,9762,"QualType Sema::BuildAtomicType(QualType T, SourceLocation Loc) {\n if (!isDependentOrGNUAutoType(T)) {\n // ...\n if (RequireCompleteType(Loc, T, diag::err_atomic_specifier_bad_type, 0))"},{p,9785,"QualType Sema::BuildAtomicType(QualType T, SourceLocation Loc) {\n if (!isDependentOrGNUAutoType(T)) {\n // ...\n if (DisallowedKind != -1) {\n Diag(Loc, diag::err_atomic_specifier_bad_type) << DisallowedKind << T;"}}, [l]={ ["clang/test/Sema/atomic-type.c"]={"clang/test/Sema/atomic-type.c:18:1: error: _Atomic cannot be applied to function type \'int (void)\' ","clang/test/Sema/atomic-type.c:19:1: error: _Atomic cannot be applied to incomplete type \'struct ErrorS\' ","clang/test/Sema/atomic-type.c:20:1: error: _Atomic cannot be applied to array type \'int[10]\' ","clang/test/Sema/atomic-type.c:21:1: error: _Atomic cannot be applied to qualified type \'const int\' ","clang/test/Sema/atomic-type.c:22:1: error: _Atomic cannot be applied to atomic type \'_Atomic(int)\' "} } }, ["err_atprotocol_protocol"]={ [c]={{nil,B,"err_atprotocol_protocol"}}, [d]={{nil,B,"@protocol is using a forward protocol declaration of %0"}}, [e]={{nil,B,"@protocol is using a forward protocol declaration of A"}}, [f]=k, [g]="@protocol is using a forward protocol declaration of (.*?)", [h]=a, [i]={{nil,B,m}}, [b]={"b111da14ada1",1534544288,"[ObjC] Error out when using forward-declared protocol in a @protocol","[ObjC] Error out when using forward-declared protocol in a @protocol\nexpression\n\nClang emits invalid protocol metadata when a @protocol expression is used with a\nforward-declared protocol. The protocol metadata is missing protocol conformance\nlist of the protocol since we don\'t have access to the definition of it in the\ncompiled translation unit. The linker then might end up picking the invalid\nmetadata when linking which will lead to incorrect runtime protocol conformance\nchecks.\n\nThis commit makes sure that Clang fails to compile code that uses a @protocol\nexpression with a forward-declared protocol. This ensures that Clang does not\nemit invalid protocol metadata. I added an extra assert in CodeGen to ensure\nthat this kind of issue won\'t happen in other places.\n\nrdar://32787811\n\nDifferential Revision: https://reviews.llvm.org/D49462\n\nllvm-svn: 340102"}, [j]={{S,1400,"ExprResult Sema::ParseObjCProtocolExpression(IdentifierInfo *ProtocolId, SourceLocation AtLoc, SourceLocation ProtoLoc, SourceLocation LParenLoc, SourceLocation ProtoIdLoc, SourceLocation RParenLoc) {\n // ...\n if (!PDecl->hasDefinition()) {\n Diag(ProtoLoc, diag::err_atprotocol_protocol) << PDecl;"}}, [l]={ ["clang/test/SemaObjC/protocol-expr-neg-1.m"]={"clang/test/SemaObjC/protocol-expr-neg-1.m:15:29: error: @protocol is using a forward protocol declaration of \'fproto\'","clang/test/SemaObjC/protocol-expr-neg-1.m:29:35: error: @protocol is using a forward protocol declaration of \'TestProtocol\'","clang/test/SemaObjC/protocol-expr-neg-1.m:33:35: error: @protocol is using a forward protocol declaration of \'SuperProtocol\'"} } }, ["err_attr_cond_never_constant_expr"]={ [c]="err_attr_cond_never_constant_expr", [d]="%0 attribute expression never produces a constant expression", [e]="A attribute expression never produces a constant expression", [f]=k, [g]="(.*?) attribute expression never produces a constant expression", [h]=a, [i]=m, [b]={"177399e2277c",1483935134,"Add the diagnose_if attribute to clang.","Add the diagnose_if attribute to clang.\n\n`diagnose_if` can be used to have clang emit either warnings or errors\nfor function calls that meet user-specified conditions. For example:\n\n```\nconstexpr int foo(int a)\n __attribute__((diagnose_if(a > 10, \"configurations with a > 10 are \"\n \"expensive.\", \"warning\")));\n\nint f1 = foo(9);\nint f2 = foo(10); // warning: configuration with a > 10 are expensive.\nint f3 = foo(f2);\n```\n\nIt currently only emits diagnostics in cases where the condition is\nguaranteed to always be true. So, the following code will emit no\nwarnings:\n\n```\nconstexpr int bar(int a) {\n foo(a);\n return 0;\n}\n\nconstexpr int i = bar(10);\n```\n\nWe hope to support optionally emitting diagnostics for cases like that\n(and emitting runtime checks) in the future.\n\nRelease notes will appear shortly. :)\n\nDifferential Revision: https://reviews.llvm.org/D27424\n\nllvm-svn: 291418"}, [j]={{n,948,"static bool checkFunctionConditionAttr(Sema &S, Decl *D, const ParsedAttr &AL, Expr *&Cond, StringRef &Msg) {\n // ...\n if (isa<FunctionDecl>(D) && !Cond->isValueDependent() && !Expr::isPotentialConstantExprUnevaluated(Cond, cast<FunctionDecl>(D), Diags)) {\n S.Diag(AL.getLoc(), diag::err_attr_cond_never_constant_expr) << AL;"},{"clang/lib/Sema/SemaTemplateInstantiateDecl.cpp",253,"static Expr *instantiateDependentFunctionAttrCondition(Sema &S, const MultiLevelTemplateArgumentList &TemplateArgs, const Attr *A, Expr *OldCond, const Decl *Tmpl, FunctionDecl *New) {\n // ...\n if (OldCond->isValueDependent() && !Cond->isValueDependent() && !Expr::isPotentialConstantExprUnevaluated(Cond, New, Diags)) {\n S.Diag(A->getLocation(), diag::err_attr_cond_never_constant_expr) << A;"}}, [l]={ ["clang/test/Sema/diagnose_if.c"]={"clang/test/Sema/diagnose_if.c:16:27: error: \'diagnose_if\' attribute expression never produces a constant expression","clang/test/Sema/diagnose_if.c:17:27: error: \'diagnose_if\' attribute expression never produces a constant expression"} } }, ["err_attr_objc_ownership_redundant"]={ [c]="err_attr_objc_ownership_redundant", [d]="the type %0 is already explicitly ownership-qualified", [e]="the type A is already explicitly ownership-qualified", [f]=k, [g]="the type (.*?) is already explicitly ownership\\-qualified", [h]=a, [i]=m, [b]={jb,1308874139,fb,kb}, [j]={{p,6973,"/// handleObjCOwnershipTypeAttr - Process an objc_ownership\n/// attribute on the specified type.\n///\n/// Returns \'true\' if the attribute was handled.\nstatic bool handleObjCOwnershipTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n // ...\n // Check for redundant/conflicting ownership qualifiers.\n if (Qualifiers::ObjCLifetime previousLifetime = type.getQualifiers().getObjCLifetime()) {\n // If it\'s written directly, that\'s an error.\n if (S.Context.hasDirectOwnershipQualifier(type)) {\n S.Diag(AttrLoc, diag::err_attr_objc_ownership_redundant) << type;"}}, [l]={ ["clang/test/SemaObjCXX/arc-objc-lifetime.mm"]={"clang/test/SemaObjCXX/arc-objc-lifetime.mm:36:1: error: the type \'I *__strong\' is already explicitly ownership-qualified","clang/test/SemaObjCXX/arc-objc-lifetime.mm:37:14: error: the type \'I *__strong\' is already explicitly ownership-qualified","clang/test/SemaObjCXX/arc-objc-lifetime.mm:38:14: error: the type \'I *__strong\' is already explicitly ownership-qualified"} } }, ["err_attr_swift_error_no_error_parameter"]={ [c]={{nil,r,"err_attr_swift_error_no_error_parameter"}}, [d]={{nil,r,"%0 attribute can only be applied to a %select{function|method}1 with an error parameter"}}, [e]={{nil,r,{"A attribute can only be applied to a ",{"function","method"}," with an error parameter"}}}, [f]=k, [g]="(.*?) attribute can only be applied to a (?:function|method) with an error parameter", [h]=a, [i]={{nil,r,m}}, [b]={sb,1582847864,Ab,xb}, [j]={{n,6390,"static void handleSwiftError(Sema &S, Decl *D, const ParsedAttr &AL) {\n auto hasErrorParameter = [](Sema &S, Decl *D, const ParsedAttr &AL) -> bool {\n // ...\n S.Diag(AL.getLoc(), diag::err_attr_swift_error_no_error_parameter) << AL << isa<ObjCMethodDecl>(D);"}}, [l]={ ["clang/test/SemaObjC/attr-swift-error.m"]={"clang/test/SemaObjC/attr-swift-error.m:46:35: error: \'__swift_error__\' attribute can only be applied to a method with an error parameter","clang/test/SemaObjC/attr-swift-error.m:48:35: error: \'__swift_error__\' attribute can only be applied to a method with an error parameter","clang/test/SemaObjC/attr-swift-error.m:50:35: error: \'__swift_error__\' attribute can only be applied to a method with an error parameter","clang/test/SemaObjC/attr-swift-error.m:52:35: error: \'__swift_error__\' attribute can only be applied to a method with an error parameter","clang/test/SemaObjC/attr-swift-error.m:83:38: error: \'__swift_error__\' attribute can only be applied to a function with an error parameter","clang/test/SemaObjC/attr-swift-error.m:85:38: error: \'__swift_error__\' attribute can only be applied to a function with an error parameter","clang/test/SemaObjC/attr-swift-error.m:87:38: error: \'__swift_error__\' attribute can only be applied to a function with an error parameter","clang/test/SemaObjC/attr-swift-error.m:89:38: error: \'__swift_error__\' attribute can only be applied to a function with an error parameter"} } }, ["err_attr_swift_error_return_type"]={ [c]={{nil,r,"err_attr_swift_error_return_type"}}, [d]={{nil,r,"%0 attribute with \'%1\' convention can only be applied to a %select{function|method}2 returning %select{an integral type|a pointer}3"}}, [e]={{nil,r,{"A attribute with \'B\' convention can only be applied to a ",{"function","method"}," returning ",{"an integral type","a pointer"}}}}, [f]=k, [g]="(.*?) attribute with \'(.*?)\' convention can only be applied to a (?:function|method) returning (?:an integral type|a pointer)", [h]=a, [i]={{nil,r,m}}, [b]={sb,1582847864,Ab,xb}, [j]={{n,6403,"static void handleSwiftError(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n auto hasPointerResult = [](Sema &S, Decl *D, const ParsedAttr &AL) -> bool {\n // ...\n S.Diag(AL.getLoc(), diag::err_attr_swift_error_return_type) << AL << AL.getArgAsIdent(0)->Ident->getName() << isa<ObjCMethodDecl>(D) << /*pointer*/ 1;"},{n,6414,"static void handleSwiftError(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n auto hasIntegerResult = [](Sema &S, Decl *D, const ParsedAttr &AL) -> bool {\n // ...\n S.Diag(AL.getLoc(), diag::err_attr_swift_error_return_type) << AL << AL.getArgAsIdent(0)->Ident->getName() << isa<ObjCMethodDecl>(D) << /*integral*/ 0;"}}, [l]={ ["clang/test/SemaObjC/attr-swift-error.m"]={"clang/test/SemaObjC/attr-swift-error.m:23:45: error: \'__swift_error__\' attribute with \'null_result\' convention can only be applied to a method returning a pointer","clang/test/SemaObjC/attr-swift-error.m:34:51: error: \'__swift_error__\' attribute with \'nonzero_result\' convention can only be applied to a method returning an integral type","clang/test/SemaObjC/attr-swift-error.m:39:51: error: \'__swift_error__\' attribute with \'zero_result\' convention can only be applied to a method returning an integral type","clang/test/SemaObjC/attr-swift-error.m:58:45: error: \'__swift_error__\' attribute with \'null_result\' convention can only be applied to a function returning a pointer","clang/test/SemaObjC/attr-swift-error.m:77:46: error: \'__swift_error__\' attribute with \'nonzero_result\' convention can only be applied to a function returning an integral type","clang/test/SemaObjC/attr-swift-error.m:79:46: error: \'__swift_error__\' attribute with \'zero_result\' convention can only be applied to a function returning an integral type"} } }, ["err_attr_tlsmodel_arg"]={ [c]="err_attr_tlsmodel_arg", [d]="tls_model must be \"global-dynamic\", \"local-dynamic\", \"initial-exec\" or \"local-exec\"", [e]="tls_model must be \"global-dynamic\", \"local-dynamic\", \"initial-exec\" or \"local-exec\"", [f]=k, [g]="tls_model must be \"global\\-dynamic\", \"local\\-dynamic\", \"initial\\-exec\" or \"local\\-exec\"", [h]=a, [i]=m, [b]={"d3b01bc7c673",1340452306,"Support the tls_model attribute (PR9788)","Support the tls_model attribute (PR9788)\n\nThis adds support for the tls_model attribute. This allows the user to\nchoose a TLS model that is better than what LLVM would select by\ndefault. For example, a variable might be declared as:\n\n __thread int x __attribute__((tls_model(\"initial-exec\")));\n\nif it will not be used in a shared library that is dlopen\'ed.\n\nThis depends on LLVM r159077.\n\nllvm-svn: 159078"}, [j]={{n,2038,"static void handleTLSModelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // Check that the value.\n if (Model != \"global-dynamic\" && Model != \"local-dynamic\" && Model != \"initial-exec\" && Model != \"local-exec\") {\n S.Diag(LiteralLoc, diag::err_attr_tlsmodel_arg);"}}, [l]={ ["clang/test/Sema/attr-tls_model.c"]={"clang/test/Sema/attr-tls_model.c:14:46: error: tls_model must be \"global-dynamic\", \"local-dynamic\", \"initial-exec\" or \"local-exec\""} } }, ["err_attribute_address_function_type"]={ [c]="err_attribute_address_function_type", [d]="function type may not be qualified with an address space", [e]="function type may not be qualified with an address space", [f]=k, [g]="function type may not be qualified with an address space", [h]=a, [i]=m, [b]={"8f5f520653f5",1311798605,"Forbid address-space-qualified function types, per TR 18037","Forbid address-space-qualified function types, per TR 18037\n\nllvm-svn: 136257"}, [j]={{p,6827,"/// HandleAddressSpaceTypeAttribute - Process an address_space attribute on the\n/// specified type. The attribute contains 1 argument, the id of the address\n/// space for the type.\nstatic void HandleAddressSpaceTypeAttribute(QualType &Type, const ParsedAttr &Attr, TypeProcessingState &State) {\n // ...\n // ISO/IEC TR 18037 S5.3 (amending C99 6.7.3): \"A function type shall not be\n // qualified by an address-space qualifier.\"\n if (Type->isFunctionType()) {\n S.Diag(Attr.getLoc(), diag::err_attribute_address_function_type);"}}, [l]={ ["clang/test/Sema/address_spaces.c"]={"clang/test/Sema/address_spaces.c:50:1: error: function type may not be qualified with an address space","clang/test/Sema/address_spaces.c:51:9: error: function type may not be qualified with an address space"} } }, ["err_attribute_address_multiple_qualifiers"]={ [c]="err_attribute_address_multiple_qualifiers", [d]="multiple address spaces specified for type", [e]="multiple address spaces specified for type", [f]=k, [g]="multiple address spaces specified for type", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{p,4624,"// Diagnose whether this is a case with the multiple addr spaces.\n// Returns true if this is an invalid case.\n// ISO/IEC TR 18037 S5.3 (amending C99 6.7.3): \"No type shall be qualified\n// by qualifiers for two or more different address spaces.\"\nstatic bool DiagnoseMultipleAddrSpaceAttributes(Sema &S, LangAS ASOld, LangAS ASNew, SourceLocation AttrLoc) {\n if (ASOld != LangAS::Default) {\n if (ASOld != ASNew) {\n S.Diag(AttrLoc, diag::err_attribute_address_multiple_qualifiers);"},{p,6774,"/// BuildAddressSpaceAttr - Builds a DependentAddressSpaceType if an expression\n/// is uninstantiated. If instantiated it will apply the appropriate address\n/// space to the type. This function allows dependent template variables to be\n/// used in conjunction with the address_space attribute\nQualType Sema::BuildAddressSpaceAttr(QualType &T, LangAS ASIdx, Expr *AddrSpace, SourceLocation AttrLoc) {\n // ...\n // A check with similar intentions as checking if a type already has an\n // address space except for on a dependent types, basically if the\n // current type is already a DependentAddressSpaceType then its already\n // lined up to have another address space on it and we can\'t have\n // multiple address spaces on the one pointer indirection\n if (T->getAs<DependentAddressSpaceType>()) {\n Diag(AttrLoc, diag::err_attribute_address_multiple_qualifiers);"}}, [l]={ ["clang/test/SemaOpenCLCXX/address-space-of-this-class-scope.clcpp"]={"clang/test/SemaOpenCLCXX/address-space-of-this-class-scope.clcpp:6:24: error: multiple address spaces specified for type"} } }, ["err_attribute_address_space_negative"]={ [c]="err_attribute_address_space_negative", [d]="address space is negative", [e]="address space is negative", [f]=k, [g]="address space is negative", [h]=a, [i]=m, [b]={"8945266f3d02",1248763938,"Bounds checking for address spaces.","Bounds checking for address spaces.\n\nllvm-svn: 77303"}, [j]={{p,6727,"/// Build an AddressSpace index from a constant expression and diagnose any\n/// errors related to invalid address_spaces. Returns true on successfully\n/// building an AddressSpace index.\nstatic bool BuildAddressSpaceIndex(Sema &S, LangAS &ASIdx, const Expr *AddrSpace, SourceLocation AttrLoc) {\n if (!AddrSpace->isValueDependent()) {\n // ...\n // Bounds checking.\n if (addrSpace.isSigned()) {\n if (addrSpace.isNegative()) {\n S.Diag(AttrLoc, diag::err_attribute_address_space_negative) << AddrSpace->getSourceRange();"}}, [l]={ ["clang/test/Sema/address_spaces.c"]={"clang/test/Sema/address_spaces.c:23:18: error: address space is negative"} } }, ["err_attribute_address_space_too_high"]={ [c]="err_attribute_address_space_too_high", [d]="address space is larger than the maximum supported (%0)", [e]="address space is larger than the maximum supported (A)", [f]=k, [g]="address space is larger than the maximum supported \\((.*?)\\)", [h]=a, [i]=m, [b]={"8945266f3d02",1248763938,"Bounds checking for address spaces.","Bounds checking for address spaces.\n\nllvm-svn: 77303"}, [j]={{p,6739,"/// Build an AddressSpace index from a constant expression and diagnose any\n/// errors related to invalid address_spaces. Returns true on successfully\n/// building an AddressSpace index.\nstatic bool BuildAddressSpaceIndex(Sema &S, LangAS &ASIdx, const Expr *AddrSpace, SourceLocation AttrLoc) {\n if (!AddrSpace->isValueDependent()) {\n // ...\n if (addrSpace > max) {\n S.Diag(AttrLoc, diag::err_attribute_address_space_too_high) << (unsigned)max.getZExtValue() << AddrSpace->getSourceRange();"}}, [l]={ ["clang/test/Sema/address_spaces.c"]={"clang/test/Sema/address_spaces.c:24:18: error: address space is larger than the maximum supported (8388586)","clang/test/Sema/address_spaces.c:25:18: error: address space is larger than the maximum supported (8388586)","clang/test/Sema/address_spaces.c:27:18: error: address space is larger than the maximum supported (8388586)"} } }, ["err_attribute_aligned_too_great"]={ [c]="err_attribute_aligned_too_great", [d]="requested alignment must be %0 bytes or smaller", [e]="requested alignment must be A bytes or smaller", [f]=k, [g]="requested alignment must be (.*?) bytes or smaller", [h]=a, [i]=m, [b]={"abecae741cb7",1392237370,"Sema: Restrict alignment to 2**28.","Sema: Restrict alignment to 2**28.\n\nAllowing alignment past this point causes wrap around within clang.\n\nN.B. GCC has the same restriction.\n\nllvm-svn: 201254"}, [j]={{n,4481,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\n // ...\n if (Alignment > MaximumAlignment) {\n Diag(AttrLoc, diag::err_attribute_aligned_too_great) << MaximumAlignment << E->getSourceRange();"}}, [l]={ ["clang/test/Sema/attr-aligned.c"]={"clang/test/Sema/attr-aligned.c:4:22: error: requested alignment must be 4294967296 bytes or smaller","clang/test/Sema/attr-aligned.c:7:22: error: requested alignment must be 4294967296 bytes or smaller"} } }, ["err_attribute_argument_invalid"]={ [c]="err_attribute_argument_invalid", [d]="%0 attribute argument is invalid: %select{max must be 0 since min is 0|min must not be greater than max}1", [e]={{nil,nil,{"A attribute argument is invalid: ",{"max must be 0 since min is 0","min must not be greater than max"}}}}, [f]=k, [g]="(.*?) attribute argument is invalid\\: (?:max must be 0 since min is 0|min must not be greater than max)", [h]=a, [i]=m, [b]={"5b48d725a0bc",1474851777,"[AMDGPU] Expose flat work group size, register and wave control attributes","[AMDGPU] Expose flat work group size, register and wave control attributes\n\n__attribute__((amdgpu_flat_work_group_size(<min>, <max>))) - request minimum and maximum flat work group size\n__attribute__((amdgpu_waves_per_eu(<min>[, <max>]))) - request minimum and/or maximum waves per execution unit\n\nDifferential Revision: https://reviews.llvm.org/D24513\n\nllvm-svn: 282371"}, [j]={{n,7853,"static bool checkAMDGPUFlatWorkGroupSizeArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUFlatWorkGroupSizeAttr &Attr) {\n // ...\n if (Min == 0 && Max != 0) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 0;"},{n,7858,"static bool checkAMDGPUFlatWorkGroupSizeArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUFlatWorkGroupSizeAttr &Attr) {\n // ...\n if (Min > Max) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 1;"},{n,7907,"static bool checkAMDGPUWavesPerEUArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUWavesPerEUAttr &Attr) {\n // ...\n if (Min == 0 && Max != 0) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 0;"},{n,7912,"static bool checkAMDGPUWavesPerEUArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUWavesPerEUAttr &Attr) {\n // ...\n if (Max != 0 && Min > Max) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 1;"}}, [l]={ ["clang/test/SemaOpenCL/amdgpu-attrs.cl"]={"clang/test/SemaOpenCL/amdgpu-attrs.cl:48:16: error: \'amdgpu_flat_work_group_size\' attribute argument is invalid: max must be 0 since min is 0","clang/test/SemaOpenCL/amdgpu-attrs.cl:49:16: error: \'amdgpu_waves_per_eu\' attribute argument is invalid: max must be 0 since min is 0","clang/test/SemaOpenCL/amdgpu-attrs.cl:51:16: error: \'amdgpu_flat_work_group_size\' attribute argument is invalid: min must not be greater than max","clang/test/SemaOpenCL/amdgpu-attrs.cl:52:16: error: \'amdgpu_waves_per_eu\' attribute argument is invalid: min must not be greater than max"} } }, ["err_attribute_argument_is_zero"]={ [c]="err_attribute_argument_is_zero", [d]="%0 attribute must be greater than 0", [e]="A attribute must be greater than 0", [f]=k, [g]="(.*?) attribute must be greater than 0", [h]=a, [i]=m, [b]={"b1d23a8db36c",1400510498,"[OpenCL] Reject reqd_work_group_size(X, Y, Z) where X, Y or Z == 0.","[OpenCL] Reject reqd_work_group_size(X, Y, Z) where X, Y or Z == 0.\n\nPatch by Pedro Ferreira!\n\nllvm-svn: 209127"}, [j]={{n,3221,"// Handles reqd_work_group_size and work_group_size_hint.\ntemplate <typename WorkGroupAttr> static void handleWorkGroupSize(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n for (unsigned i = 0; i < 3; ++i) {\n // ...\n if (WGSize[i] == 0) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_is_zero) << AL << E->getSourceRange();"},{n,3244,"// Handles intel_reqd_sub_group_size.\nstatic void handleSubGroupSize(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (SGSize == 0) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_is_zero) << AL << E->getSourceRange();"}}, [l]={ ["clang/test/SemaOpenCL/invalid-kernel-attrs.cl"]={"clang/test/SemaOpenCL/invalid-kernel-attrs.cl:33:23: error: \'reqd_work_group_size\' attribute must be greater than 0","clang/test/SemaOpenCL/invalid-kernel-attrs.cl:34:23: error: \'reqd_work_group_size\' attribute must be greater than 0","clang/test/SemaOpenCL/invalid-kernel-attrs.cl:35:23: error: \'reqd_work_group_size\' attribute must be greater than 0","clang/test/SemaOpenCL/invalid-kernel-attrs.cl:38:23: error: \'intel_reqd_sub_group_size\' attribute must be greater than 0"} } }, ["err_attribute_argument_n_type"]={ [c]="err_attribute_argument_n_type", [d]={{nil,x,"%0 attribute requires parameter %1 to be %select{int or bool|an integer constant|a string|an identifier|a constant expression|a builtin function}2"},{y,r,"%0 attribute requires parameter %1 to be %select{int or bool|an integer constant|a string|an identifier|a constant expression}2"},{"11.1",nil,"%0 attribute requires parameter %1 to be %select{int or bool|an integer constant|a string|an identifier}2"}}, [e]={{nil,x,{"A attribute requires parameter B to be ",{"int or bool","an integer constant","a string","an identifier","a constant expression","a builtin function"}}},{y,r,{"A attribute requires parameter B to be ",{"int or bool","an integer constant","a string","an identifier","a constant expression"}}},{"11.1",nil,{"A attribute requires parameter B to be ",{"int or bool","an integer constant","a string","an identifier"}}}}, [f]=k, [g]="(.*?) attribute requires parameter (.*?) to be (?:int or bool|an integer constant|a string|an identifier|a constant expression|a builtin function)", [h]=a, [i]=m, [b]={"29982275012f",1374588237,"Consolidate several attribute argument diagnostics into a single, selectable diagnostic. This makes...","Consolidate several attribute argument diagnostics into a single, selectable diagnostic. This makes the diagnostic more consistent.\n\nllvm-svn: 186940"}, [j]={{"clang/lib/Sema/SemaAttr.cpp",424,"bool Sema::ConstantFoldAttrArgs(const AttributeCommonInfo &CI, MutableArrayRef<Expr *> Args) {\n // ...\n for (unsigned Idx = 0; Idx < Args.size(); Idx++) {\n // ...\n /// Result means the expression can be folded to a constant.\n /// Note.empty() means the expression is a valid constant expression in the\n /// current language mode.\n if (!Result || !Notes.empty()) {\n Diag(E->getBeginLoc(), diag::err_attribute_argument_n_type) << CI << (Idx + 1) << AANT_ArgumentConstantExpr;"},{n,225,"/// If Expr is a valid integer constant, get the value of the integer\n/// expression and return success or failure. May output an error.\n///\n/// Negative argument is implicitly converted to unsigned, unless\n/// \\p StrictlyUnsigned is true.\ntemplate <typename AttrInfo> static bool checkUInt32Argument(Sema &S, const AttrInfo &AI, const Expr *Expr, uint32_t &Val, unsigned Idx = UINT_MAX, bool StrictlyUnsigned = false) {\n // ...\n if (Expr->isTypeDependent() || !(I = Expr->getIntegerConstantExpr(S.Context))) {\n if (Idx != UINT_MAX)\n S.Diag(getAttrLoc(AI), diag::err_attribute_argument_n_type) << &AI << Idx << AANT_ArgumentIntegerConstant << Expr->getSourceRange();"},{n,319,"/// Check if IdxExpr is a valid parameter index for a function or\n/// instance method D. May output an error.\n///\n/// \\returns true if IdxExpr is a valid index.\ntemplate <typename AttrInfo> static bool checkFunctionOrMethodParameterIndex(Sema &S, const Decl *D, const AttrInfo &AI, unsigned AttrArgNum, const Expr *IdxExpr, ParamIdx &Idx, bool CanIndexImplicitThis = false) {\n // ...\n if (IdxExpr->isTypeDependent() || !(IdxInt = IdxExpr->getIntegerConstantExpr(S.Context))) {\n S.Diag(getAttrLoc(AI), diag::err_attribute_argument_n_type) << &AI << AttrArgNum << AANT_ArgumentIntegerConstant << IdxExpr->getSourceRange();"},{n,870,"static bool checkTryLockFunAttrCommon(Sema &S, Decl *D, const ParsedAttr &AL, SmallVectorImpl<Expr *> &Args) {\n // ...\n if (!isIntOrBool(AL.getArgAsExpr(0))) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIntOrBool;"},{n,1037,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n auto DiagnoseType = [&](unsigned Index, AttributeArgumentNType T) {\n // ...\n S.Diag(Loc, diag::err_attribute_argument_n_type) << AL << Index << T;"},{n,1700,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n // ...\n if (!E->isValueDependent()) {\n // ...\n if (!(I = E->getIntegerConstantExpr(Context))) {\n if (OE)\n Diag(AttrLoc, diag::err_attribute_argument_n_type) << &TmpAttr << 1 << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{n,1722,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n // ...\n if (OE && !OE->isValueDependent() && !OE->isIntegerConstantExpr(Context)) {\n Diag(AttrLoc, diag::err_attribute_argument_n_type) << &TmpAttr << 2 << AANT_ArgumentIntegerConstant << OE->getSourceRange();"},{n,1820,"static void handleOwnershipAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIdentifier;"},{n,2967,"static void handleObjCMethodFamilyAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIdentifier;"},{n,3033,"static void handleBlocksAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIdentifier;"},{n,3054,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.getNumArgs() > 0) {\n // ...\n if (E->isTypeDependent() || !(Idx = E->getIntegerConstantExpr(S.Context))) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{n,3073,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.getNumArgs() > 1) {\n // ...\n if (E->isTypeDependent() || !(Idx = E->getIntegerConstantExpr(S.Context))) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 2 << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{n,3754,"static void handleEnumExtensibilityAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 0 << AANT_ArgumentIdentifier;"},{n,3937,"/// Handle __attribute__((format(type,idx,firstarg))) attributes based on\n/// http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html\nstatic void handleFormatAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIdentifier;"},{n,5613,"// Checks whether an argument of launch_bounds attribute is\n// acceptable, performs implicit conversion to Rvalue, and returns\n// non-nullptr Expr result on success. Otherwise, it returns nullptr\n// and may output an error.\nstatic Expr *makeLaunchBoundsArgExpr(Sema &S, Expr *E, const CUDALaunchBoundsAttr &AL, const unsigned Idx) {\n // ...\n if (!(I = E->getIntegerConstantExpr(S.Context))) {\n S.Diag(E->getExprLoc(), diag::err_attribute_argument_n_type) << &AL << Idx << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{n,5665,"static void handleArgumentWithTypeTagAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << /* arg num = */ 1 << AANT_ArgumentIdentifier;"},{n,5697,"static void handleTypeTagForDatatypeAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIdentifier;"},{n,5812,"static void handleArmBuiltinAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIdentifier;"},{n,5841,"static void handleBuiltinAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIdentifier;"},{n,6915,"static void handleSwiftAsyncAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIdentifier;"}}, [l]={ ["clang/test/Sema/alloc-align-attr.c"]={"clang/test/Sema/alloc-align-attr.c:13:46: error: \'alloc_align\' attribute requires parameter 1 to be an integer constant"} } }, ["err_attribute_argument_out_of_bounds"]={ [c]="err_attribute_argument_out_of_bounds", [d]="%0 attribute parameter %1 is out of bounds", [e]="A attribute parameter B is out of bounds", [f]=k, [g]="(.*?) attribute parameter (.*?) is out of bounds", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{n,327,"/// Check if IdxExpr is a valid parameter index for a function or\n/// instance method D. May output an error.\n///\n/// \\returns true if IdxExpr is a valid index.\ntemplate <typename AttrInfo> static bool checkFunctionOrMethodParameterIndex(Sema &S, const Decl *D, const AttrInfo &AI, unsigned AttrArgNum, const Expr *IdxExpr, ParamIdx &Idx, bool CanIndexImplicitThis = false) {\n // ...\n if (IdxSource < 1 || (!IV && IdxSource > NumParams)) {\n S.Diag(getAttrLoc(AI), diag::err_attribute_argument_out_of_bounds) << &AI << AttrArgNum << IdxExpr->getSourceRange();"},{n,3974,"/// Handle __attribute__((format(type,idx,firstarg))) attributes based on\n/// http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html\nstatic void handleFormatAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (Idx < 1 || Idx > NumArgs) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << 2 << IdxExpr->getSourceRange();"},{n,4024,"/// Handle __attribute__((format(type,idx,firstarg))) attributes based on\n/// http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html\nstatic void handleFormatAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // FirstArg == 0 is is always valid.\n if (FirstArg != 0) {\n if (Kind == StrftimeFormat) {\n // ...\n } else if (isFunctionOrMethodVariadic(D)) {\n // Else, if the function is variadic, then FirstArg must be 0 or the\n // \"position\" of the ... parameter. It\'s unusual to use 0 with variadic\n // functions, so the fixit proposes the latter.\n if (FirstArg != NumArgs + 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << 3 << FirstArgExpr->getSourceRange() << FixItHint::CreateReplacement(FirstArgExpr->getSourceRange(), std::to_string(NumArgs + 1));"},{n,4037,"/// Handle __attribute__((format(type,idx,firstarg))) attributes based on\n/// http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html\nstatic void handleFormatAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // FirstArg == 0 is is always valid.\n if (FirstArg != 0) {\n if (Kind == StrftimeFormat) {\n // ...\n } else if (isFunctionOrMethodVariadic(D)) {\n // ...\n } else {\n // ...\n if (FirstArg <= Idx) {\n // ...\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << 3 << FirstArgExpr->getSourceRange();"},{n,4097,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n // ...\n if (AL.isArgIdent(I)) {\n // ...\n } else if (AL.isArgExpr(I)) {\n // ...\n // If the expression is not parseable as an int32_t we have a problem.\n if (!checkUInt32Argument(S, AL, IdxExpr, (uint32_t &)ArgIdx, I + 1, false)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << (I + 1) << IdxExpr->getSourceRange();"},{n,4104,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n // ...\n if (AL.isArgIdent(I)) {\n // ...\n } else if (AL.isArgExpr(I)) {\n // ...\n // Check oob, excluding the special values, 0 and -1.\n if (ArgIdx < -1 || ArgIdx > NumArgs) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << (I + 1) << IdxExpr->getSourceRange();"},{n,6487,"static void checkSwiftAsyncErrorBlock(Sema &S, Decl *D, const SwiftAsyncErrorAttr *ErrorAttr, const SwiftAsyncAttr *AsyncAttr) {\n // ...\n case SwiftAsyncErrorAttr::ZeroArgument:\n case SwiftAsyncErrorAttr::NonZeroArgument: {\n // ...\n if (ParamIdx == 0 || ParamIdx > BlockParams.size()) {\n S.Diag(ErrorAttr->getLocation(), diag::err_attribute_argument_out_of_bounds) << ErrorAttr << 2;"},{n,7418,"static void handleMSP430InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (Num > 63) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << (int)NumParams->getSExtValue() << NumParamsExpr->getSourceRange();"},{n,7508,"static void handleM68kInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if ((Num & 1) || Num > 30) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << (int)MaybeNumParams->getSExtValue() << NumParamsExpr->getSourceRange();"},{n,7990,"static void handleLayoutVersion(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // TODO: Investigate what happens with the next major version of MSVC.\n if (Version != LangOptions::MSVC2015 / 100) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << Version << VersionExpr->getSourceRange();"}}, [l]={ ["clang/test/Sema/alloc-align-attr.c"]={"clang/test/Sema/alloc-align-attr.c:8:48: error: \'alloc_align\' attribute parameter 1 is out of bounds","clang/test/Sema/alloc-align-attr.c:9:43: error: \'alloc_align\' attribute parameter 1 is out of bounds"} } }, ["err_attribute_argument_out_of_bounds_extra_info"]={ [c]={{nil,K,"err_attribute_argument_out_of_bounds_extra_info"}}, [d]={{nil,K,"%0 attribute parameter %1 is out of bounds: %plural{0:no parameters to index into|1:can only be 1, since there is one parameter|:must be between 1 and %2}2"}}, [e]={{nil,K,{"A attribute parameter B is out of bounds: ",{"no parameters to index into","can only be 1, since there is one parameter","must be between 1 and C"}}}}, [f]=k, [g]="(.*?) attribute parameter (.*?) is out of bounds\\: (?:no parameters to index into|can only be 1, since there is one parameter|must be between 1 and (.*?))", [h]=a, [i]={{nil,K,m}}, [b]={"ce667f6df971",1549977542,"Renaming yet another diagnostic to not conflict; NFC.","Renaming yet another diagnostic to not conflict; NFC.\n\nllvm-svn: 353839"}, [j]={{n,666,"/// Checks that all attribute arguments, starting from Sidx, resolve to\n/// a capability object.\n/// \\param Sidx The attribute argument index to start checking with.\n/// \\param ParamIdxOk Whether an argument can be indexing into a function\n/// parameter list.\nstatic void checkAttrArgsAreCapabilityObjs(Sema &S, Decl *D, const ParsedAttr &AL, SmallVectorImpl<Expr *> &Args, unsigned Sidx = 0, bool ParamIdxOk = false) {\n // ...\n for (unsigned Idx = Sidx; Idx < AL.getNumArgs(); ++Idx) {\n // ...\n // Now check if we index into a record type function param.\n if (!RT && ParamIdxOk) {\n // ...\n if (FD && IL) {\n // ...\n if (!ArgValue.isStrictlyPositive() || ParamIdxFromOne > NumParams) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds_extra_info) << AL << Idx + 1 << NumParams;"}}, [l]={ ["clang/test/SemaCXX/warn-thread-safety-parsing.cpp"]={"clang/test/SemaCXX/warn-thread-safety-parsing.cpp:628:26: error: \'exclusive_lock_function\' attribute parameter 1 is out of bounds: no parameters to index into","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:630:33: error: \'exclusive_lock_function\' attribute parameter 1 is out of bounds: can only be 1, since there is one parameter","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:632:42: error: \'exclusive_lock_function\' attribute parameter 1 is out of bounds: must be between 1 and 2","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:634:26: error: \'exclusive_lock_function\' attribute parameter 1 is out of bounds: no parameters to index into","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:701:26: error: \'shared_lock_function\' attribute parameter 1 is out of bounds: no parameters to index into","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:703:33: error: \'shared_lock_function\' attribute parameter 1 is out of bounds: can only be 1, since there is one parameter","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:705:42: error: \'shared_lock_function\' attribute parameter 1 is out of bounds: must be between 1 and 2","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:707:26: error: \'shared_lock_function\' attribute parameter 1 is out of bounds: no parameters to index into","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:932:25: error: \'unlock_function\' attribute parameter 1 is out of bounds: no parameters to index into","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:934:32: error: \'unlock_function\' attribute parameter 1 is out of bounds: can only be 1, since there is one parameter","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:936:41: error: \'unlock_function\' attribute parameter 1 is out of bounds: must be between 1 and 2","clang/test/SemaCXX/warn-thread-safety-parsing.cpp:938:25: error: \'unlock_function\' attribute parameter 1 is out of bounds: no parameters to index into"} } }, ["err_attribute_argument_out_of_range"]={ [c]="err_attribute_argument_out_of_range", [d]={{nil,K,"%0 attribute requires integer constant between %1 and %2 inclusive"},{B,nil,"%0 attribute parameter %1 is out of bounds: %plural{0:no parameters to index into|1:can only be 1, since there is one parameter|:must be between 1 and %2}2"}}, [e]={{nil,K,"A attribute requires integer constant between B and C inclusive"},{B,nil,{"A attribute parameter B is out of bounds: ",{"no parameters to index into","can only be 1, since there is one parameter","must be between 1 and C"}}}}, [f]=k, [g]="(.*?) attribute requires integer constant between (.*?) and (.*?) inclusive", [h]=a, [i]=m, [b]={"4b1e8399c22e",1312912771,"Thread Safety: Added basic argument parsing for all new attributes.","Thread Safety: Added basic argument parsing for all new attributes.\n\nThis patch special cases the parser for thread safety attributes so that all\nattribute arguments are put in the argument list (instead of a special\nparameter) since arguments may not otherwise resolve correctly without two-token\nlookahead.\n\nThis patch also adds checks to make sure that attribute arguments are\nlockable objects.\n\nllvm-svn: 137130"}, [j]={{n,1188,"static void handlePassObjectSizeAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // pass_object_size\'s argument is passed in as the second argument of\n // __builtin_object_size. So, it has the same constraints as that second\n // argument; namely, it must be in the range [0, 3].\n if (Type > 3) {\n S.Diag(E->getBeginLoc(), diag::err_attribute_argument_out_of_range) << AL << 0 << 3 << E->getSourceRange();"},{n,3881,"/// Handle __attribute__((init_priority(priority))) attributes based on\n/// http://gcc.gnu.org/onlinedocs/gcc/C_002b_002b-Attributes.html\nstatic void handleInitPriorityAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // Only perform the priority check if the attribute is outside of a system\n // header. Values <= 100 are reserved for the implementation, and libc++\n // benefits from being able to specify values in that range.\n if ((prioritynum < 101 || prioritynum > 65535) && !S.getSourceManager().isInSystemHeader(AL.getLoc())) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_range) << E->getSourceRange() << AL << 101 << 65535;"},{n,5744,"static void handlePatchableFunctionEntryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.getNumArgs() == 2) {\n // ...\n if (Count < Offset) {\n S.Diag(getAttrLoc(AL), diag::err_attribute_argument_out_of_range) << &AL << 0 << Count << Arg->getBeginLoc();"}}, [l]={ ["clang/test/Sema/pass-object-size.c"]={"clang/test/Sema/pass-object-size.c:9:48: error: \'pass_object_size\' attribute requires integer constant between 0 and 3 inclusive","clang/test/Sema/pass-object-size.c:10:48: error: \'pass_object_size\' attribute requires integer constant between 0 and 3 inclusive"} } }, ["err_attribute_argument_parm_pack_not_supported"]={ [c]={{nil,E,"err_attribute_argument_parm_pack_not_supported"}}, [d]={{nil,E,"attribute %0 does not support argument pack expansion"}}, [e]={{nil,E,"attribute A does not support argument pack expansion"}}, [f]=k, [g]="attribute (.*?) does not support argument pack expansion", [h]=a, [i]={{nil,E,V}}, [b]={"69350e569dc4",1612659633,"[C++20][Modules][3/8] Initial handling for module partitions.","[C++20][Modules][3/8] Initial handling for module partitions.\n\nThis implements the parsing and recognition of module partition CMIs\nand removes the FIXMEs in the parser.\n\nModule partitions are recognised in the base computation of visibility,\nhowever additional amendments to visibility follow in subsequent patches.\n\nDifferential Revision: https://reviews.llvm.org/D118586"}, [j]={{Bb,481,"unsigned Parser::ParseAttributeArgsCommon(IdentifierInfo *AttrName, SourceLocation AttrNameLoc, ParsedAttributes &Attrs, SourceLocation *EndLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n // ...\n if (!ArgExprs.empty() ? Tok.is(tok::comma) : Tok.isNot(tok::r_paren)) {\n // ...\n if (AttributeIsTypeArgAttr) {\n // ...\n } else if (AttributeHasVariadicIdentifierArg) {\n // ...\n } else {\n // ...\n // Pack expansion must currently be explicitly supported by an attribute.\n for (size_t I = 0; I < ParsedExprs.size(); ++I) {\n // ...\n if (!attributeAcceptsExprPack(*AttrName)) {\n Diag(Tok.getLocation(), diag::err_attribute_argument_parm_pack_not_supported) << AttrName;"}}, [l]={ ["clang/test/Parser/cxx0x-attributes.cpp"]={"clang/test/Parser/cxx0x-attributes.cpp:269:38: error: attribute \'no_sanitize\' does not support argument pack expansion"} } }, ["err_attribute_argument_type"]={ [c]="err_attribute_argument_type", [d]="%0 attribute requires %select{int or bool|an integer constant|a string|an identifier}1", [e]={{nil,nil,{"A attribute requires ",{"int or bool","an integer constant","a string","an identifier"}}}}, [f]=k, [g]="(.*?) attribute requires (?:int or bool|an integer constant|a string|an identifier)", [h]=a, [i]=m, [b]={"3bf758cd6579",1375147863,"err_attribute_not_string has been subsumed by err_attribute_argument_type.","err_attribute_not_string has been subsumed by err_attribute_argument_type.\n\nllvm-svn: 187400"}, [j]={{n,229,"/// If Expr is a valid integer constant, get the value of the integer\n/// expression and return success or failure. May output an error.\n///\n/// Negative argument is implicitly converted to unsigned, unless\n/// \\p StrictlyUnsigned is true.\ntemplate <typename AttrInfo> static bool checkUInt32Argument(Sema &S, const AttrInfo &AI, const Expr *Expr, uint32_t &Val, unsigned Idx = UINT_MAX, bool StrictlyUnsigned = false) {\n // ...\n if (Expr->isTypeDependent() || !(I = Expr->getIntegerConstantExpr(S.Context))) {\n if (Idx != UINT_MAX)\n // ...\n else\n S.Diag(getAttrLoc(AI), diag::err_attribute_argument_type) << &AI << AANT_ArgumentIntegerConstant << Expr->getSourceRange();"},{n,354,"/// Check if the argument \\p E is a ASCII string literal. If not emit an error\n/// and return false, otherwise set \\p Str to the value of the string literal\n/// and return true.\nbool Sema::checkStringLiteralArgumentAttr(const AttributeCommonInfo &CI, const Expr *E, StringRef &Str, SourceLocation *ArgLocation) {\n // ...\n if (!Literal || !Literal->isOrdinary()) {\n Diag(E->getBeginLoc(), diag::err_attribute_argument_type) << CI << AANT_ArgumentString;"},{n,373,"/// Check if the argument \\p ArgNum of \\p Attr is a ASCII string literal.\n/// If not emit an error and return false. If the argument is an identifier it\n/// will emit an error with a fixit hint and treat it as if it was a string\n/// literal.\nbool Sema::checkStringLiteralArgumentAttr(const ParsedAttr &AL, unsigned ArgNum, StringRef &Str, SourceLocation *ArgLocation) {\n // Look for identifiers. If we have one emit a hint to fix it to a literal.\n if (AL.isArgIdent(ArgNum)) {\n // ...\n Diag(Loc->Loc, diag::err_attribute_argument_type) << AL << AANT_ArgumentString << FixItHint::CreateInsertion(Loc->Loc, \"\\\"\") << FixItHint::CreateInsertion(getLocForEndOfToken(Loc->Loc), \"\\\"\");"},{n,1217,"static void handleConsumableAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.isArgIdent(0)) {\n // ...\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,1289,"static void handleParamTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.isArgIdent(0)) {\n // ...\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,1321,"static void handleReturnTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.isArgIdent(0)) {\n // ...\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,1368,"static void handleSetTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.isArgIdent(0)) {\n // ...\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,1390,"static void handleTestTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.isArgIdent(0)) {\n // ...\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,1704,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n // ...\n if (!E->isValueDependent()) {\n // ...\n if (!(I = E->getIntegerConstantExpr(Context))) {\n if (OE)\n // ...\n else\n Diag(AttrLoc, diag::err_attribute_argument_type) << &TmpAttr << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{n,2100,"static void handleCPUSpecificAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n for (unsigned ArgNo = 0; ArgNo < getNumAttributeArgs(AL); ++ArgNo) {\n if (!AL.isArgIdent(ArgNo)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,4726,"/// handleModeAttr - This attribute modifies the width of a decl with primitive\n/// type.\n///\n/// Despite what would be logical, the mode attribute is a decl attribute, not a\n/// type attribute: \'int ** __attribute((mode(HI))) *G;\' tries to make \'G\' be\n/// HImode, not an intermediate pointer.\nstatic void handleModeAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // This attribute isn\'t documented, but glibc uses it. It changes\n // the width of an int or unsigned int to the specified size.\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,6892,"static void handleSwiftNewType(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,7223,"static void handleHLSLResourceBindingAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,7236,"static void handleHLSLResourceBindingAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.getNumArgs() == 2) {\n // ...\n if (!AL.isArgIdent(1)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{n,7402,"static void handleMSP430InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!AL.isArgExpr(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant;"},{n,7410,"static void handleMSP430InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!(NumParams = NumParamsExpr->getIntegerConstantExpr(S.Context))) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant << NumParamsExpr->getSourceRange();"},{n,7490,"static void handleM68kInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!AL.isArgExpr(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant;"},{n,7500,"static void handleM68kInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!MaybeNumParams) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant << NumParamsExpr->getSourceRange();"},{n,8592,"static void handleCFGuardAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{"clang/lib/Sema/SemaStmtAttr.cpp",463,"static Attr *handleOpenCLUnrollHint(Sema &S, Stmt *St, const ParsedAttr &A, SourceRange Range) {\n // ...\n if (A.getNumArgs() == 1) {\n // ...\n if (!(ArgVal = E->getIntegerConstantExpr(S.Context))) {\n S.Diag(A.getLoc(), diag::err_attribute_argument_type) << A << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{p,2729,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n // ...\n if (!VecSize) {\n Diag(AttrLoc, diag::err_attribute_argument_type) << \"vector_size\" << AANT_ArgumentIntegerConstant << SizeExpr->getSourceRange();"},{p,2807,"/// Build an ext-vector type.\n///\n/// Run the required checks for the extended vector type.\nQualType Sema::BuildExtVectorType(QualType T, Expr *ArraySize, SourceLocation AttrLoc) {\n // ...\n if (!ArraySize->isTypeDependent() && !ArraySize->isValueDependent()) {\n // ...\n if (!vecSize) {\n Diag(AttrLoc, diag::err_attribute_argument_type) << \"ext_vector_type\" << AANT_ArgumentIntegerConstant << ArraySize->getSourceRange();"},{p,2861,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n // ...\n // Both are row and column expressions are invalid.\n if (!ValueRows && !ValueColumns) {\n Diag(AttrLoc, diag::err_attribute_argument_type) << \"matrix_type\" << AANT_ArgumentIntegerConstant << RowRange << ColRange;"},{p,2869,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n // ...\n // Only the row expression is invalid.\n if (!ValueRows) {\n Diag(AttrLoc, diag::err_attribute_argument_type) << \"matrix_type\" << AANT_ArgumentIntegerConstant << RowRange;"},{p,2876,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n // ...\n // Only the column expression is invalid.\n if (!ValueColumns) {\n Diag(AttrLoc, diag::err_attribute_argument_type) << \"matrix_type\" << AANT_ArgumentIntegerConstant << ColRange;"},{p,6717,"/// Build an AddressSpace index from a constant expression and diagnose any\n/// errors related to invalid address_spaces. Returns true on successfully\n/// building an AddressSpace index.\nstatic bool BuildAddressSpaceIndex(Sema &S, LangAS &ASIdx, const Expr *AddrSpace, SourceLocation AttrLoc) {\n if (!AddrSpace->isValueDependent()) {\n // ...\n if (!OptAddrSpace) {\n S.Diag(AttrLoc, diag::err_attribute_argument_type) << \"\'address_space\'\" << AANT_ArgumentIntegerConstant << AddrSpace->getSourceRange();"},{p,6804,"static void HandleBTFTypeTagAttribute(QualType &Type, const ParsedAttr &Attr, TypeProcessingState &State) {\n // ...\n if (!StrLiteral) {\n S.Diag(Attr.getLoc(), diag::err_attribute_argument_type) << Attr << AANT_ArgumentString;"},{p,6936,"/// handleObjCOwnershipTypeAttr - Process an objc_ownership\n/// attribute on the specified type.\n///\n/// Returns \'true\' if the attribute was handled.\nstatic bool handleObjCOwnershipTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n // ...\n if (!attr.isArgIdent(0)) {\n S.Diag(AttrLoc, diag::err_attribute_argument_type) << attr << AANT_ArgumentString;"},{p,7107,"/// handleObjCGCTypeAttr - Process the __attribute__((objc_gc)) type\n/// attribute on the specified type. Returns true to indicate that\n/// the attribute was handled, false to indicate that the type does\n/// not permit the attribute.\nstatic bool handleObjCGCTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n // ...\n // Check the attribute arguments.\n if (!attr.isArgIdent(0)) {\n S.Diag(attr.getLoc(), diag::err_attribute_argument_type) << attr << AANT_ArgumentString;"},{p,8184,"static bool verifyValidIntegerConstantExpr(Sema &S, const ParsedAttr &Attr, llvm::APSInt &Result) {\n // ...\n S.Diag(Attr.getLoc(), diag::err_attribute_argument_type) << Attr << AANT_ArgumentIntegerConstant << AttrExpr->getSourceRange();"}}, [l]={ ["clang/test/SemaCXX/warn-consumed-parsing.cpp"]={"clang/test/SemaCXX/warn-consumed-parsing.cpp:38:39: error: \'callable_when\' attribute requires a string","clang/test/SemaCXX/warn-consumed-parsing.cpp:46:38: error: \'return_typestate\' attribute requires an identifier","clang/test/SemaCXX/warn-consumed-parsing.cpp:56:7: error: \'consumable\' attribute requires an identifier"} } }, ["err_attribute_arm_builtin_alias"]={ [c]={{nil,q,"err_attribute_arm_builtin_alias"}}, [d]={{nil,q,"\'__clang_arm_builtin_alias\' attribute can only be applied to an ARM builtin"}}, [e]={{nil,q,"\'__clang_arm_builtin_alias\' attribute can only be applied to an ARM builtin"}}, [f]=k, [g]="\'__clang_arm_builtin_alias\' attribute can only be applied to an ARM builtin", [h]=a, [i]={{nil,q,m}}, [b]={Fb,1576908663,Gb,Hb}, [j]={{n,5826,"static void handleArmBuiltinAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if ((IsAArch64 && !ArmSveAliasValid(S.Context, BuiltinID, AliasName) && !ArmSmeAliasValid(S.Context, BuiltinID, AliasName)) || (!IsAArch64 && !ArmMveAliasValid(BuiltinID, AliasName) && !ArmCdeAliasValid(BuiltinID, AliasName))) {\n S.Diag(AL.getLoc(), diag::err_attribute_arm_builtin_alias);"}}, [l]={ ["clang/test/Sema/arm-mve-alias-attribute.c"]={"clang/test/Sema/arm-mve-alias-attribute.c:3:34: error: \'__clang_arm_builtin_alias\' attribute can only be applied to an ARM builtin"} } }, ["err_attribute_arm_feature_sve_bits_unsupported"]={ [c]={{nil,r,"err_attribute_arm_feature_sve_bits_unsupported"}}, [d]={{nil,r,"%0 is only supported when \'-msve-vector-bits=<bits>\' is specified with a value of 128, 256, 512, 1024 or 2048."}}, [e]={{nil,r,"A is only supported when \'-msve-vector-bits=<bits>\' is specified with a value of 128, 256, 512, 1024 or 2048."}}, [f]=k, [g]="(.*?) is only supported when \'\\-msve\\-vector\\-bits\\=\\<bits\\>\' is specified with a value of 128, 256, 512, 1024 or 2048\\.", [h]=a, [i]={{nil,r,m}}, [b]={sb,1582847864,Ab,xb}, [j]={{p,8265,"/// HandleArmSveVectorBitsTypeAttr - The \"arm_sve_vector_bits\" attribute is\n/// used to create fixed-length versions of sizeless SVE types defined by\n/// the ACLE, such as svint32_t and svbool_t.\nstatic void HandleArmSveVectorBitsTypeAttr(QualType &CurType, ParsedAttr &Attr, Sema &S) {\n // ...\n // Attribute is unsupported if \'-msve-vector-bits=<bits>\' isn\'t specified, or\n // if <bits>+ syntax is used.\n if (!S.getLangOpts().VScaleMin || S.getLangOpts().VScaleMin != S.getLangOpts().VScaleMax) {\n S.Diag(Attr.getLoc(), diag::err_attribute_arm_feature_sve_bits_unsupported) << Attr;"}} }, ["err_attribute_arm_mve_polymorphism"]={ [c]={{nil,q,"err_attribute_arm_mve_polymorphism"}}, [d]={{nil,q,"\'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE/NEON vector type"}}, [e]={{nil,q,"\'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE/NEON vector type"}}, [f]=k, [g]="\'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE\\/NEON vector type", [h]=a, [i]={{nil,q,m}}, [b]={"6d485ff455ea",1576172311,"Improve static checks for sprintf and __builtin___sprintf_chk","Improve static checks for sprintf and __builtin___sprintf_chk\n\nImplement a pessimistic evaluator of the minimal required size for a buffer\nbased on the format string, and couple that with the fortified version to emit a\nwarning when the buffer size is lower than the lower bound computed from the\nformat string.\n\nDifferential Revision: https://reviews.llvm.org/D71566"}, [j]={{p,8322,"static void HandleArmMveStrictPolymorphismAttr(TypeProcessingState &State, QualType &CurType, ParsedAttr &Attr) {\n // ...\n if (!VT || VT->getVectorKind() != VectorType::NeonVector) {\n State.getSema().Diag(Attr.getLoc(), diag::err_attribute_arm_mve_polymorphism);"}}, [l]={ ["clang/test/Sema/overload-arm-mve.c"]={"clang/test/Sema/overload-arm-mve.c:120:24: error: \'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE/NEON vector type","clang/test/Sema/overload-arm-mve.c:121:24: error: \'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE/NEON vector type","clang/test/Sema/overload-arm-mve.c:122:24: error: \'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE/NEON vector type"} } }, ["err_attribute_bad_neon_vector_size"]={ [c]="err_attribute_bad_neon_vector_size", [d]="Neon vector size must be 64 or 128 bits", [e]="Neon vector size must be 64 or 128 bits", [f]=k, [g]="Neon vector size must be 64 or 128 bits", [h]=a, [i]=m, [b]={"118baf76115b",1289867544,"Add support for \"neon_vector_type\" and \"neon_polyvector_type\" attributes","Add support for \"neon_vector_type\" and \"neon_polyvector_type\" attributes\nto create the special Neon vector types. These are intended to be used in\nClang\'s version of <arm_neon.h> to define special Neon vector types that will\nbe mangled according to ARM\'s ABI.\n\nllvm-svn: 119301"}, [j]={{p,8241,"/// HandleNeonVectorTypeAttr - The \"neon_vector_type\" and\n/// \"neon_polyvector_type\" attributes are used to create vector types that\n/// are mangled according to ARM\'s ABI. Otherwise, these types are identical\n/// to those created with the \"vector_size\" attribute. Unlike \"vector_size\"\n/// the argument to these Neon attributes is the number of vector elements,\n/// not the vector size in bytes. The vector width and element type must\n/// match one of the standard Neon vector types.\nstatic void HandleNeonVectorTypeAttr(QualType &CurType, const ParsedAttr &Attr, Sema &S, VectorType::VectorKind VecKind) {\n // ...\n if (vecSize != 64 && vecSize != 128) {\n S.Diag(Attr.getLoc(), diag::err_attribute_bad_neon_vector_size) << CurType;"}}, [l]={ ["clang/test/Sema/neon-vector-types.c"]={"clang/test/Sema/neon-vector-types.c:42:24: error: Neon vector size must be 64 or 128 bits","clang/test/Sema/neon-vector-types.c:43:24: error: Neon vector size must be 64 or 128 bits"} } }, ["err_attribute_bad_rvv_vector_size"]={ [c]="err_attribute_bad_rvv_vector_size", [d]="invalid RVV vector size \'%0\', expected size is \'%1\' based on LMUL of type and \'-mrvv-vector-bits\'", [e]="invalid RVV vector size \'A\', expected size is \'B\' based on LMUL of type and \'-mrvv-vector-bits\'", [f]=k, [g]="invalid RVV vector size \'(.*?)\', expected size is \'(.*?)\' based on LMUL of type and \'\\-mrvv\\-vector\\-bits\'", [h]=a, [i]=m, [b]={eb,1625925174,gb,hb}, [j]={{p,8385,"/// HandleRISCVRVVVectorBitsTypeAttr - The \"riscv_rvv_vector_bits\" attribute is\n/// used to create fixed-length versions of sizeless RVV types such as\n/// vint8m1_t_t.\nstatic void HandleRISCVRVVVectorBitsTypeAttr(QualType &CurType, ParsedAttr &Attr, Sema &S) {\n // ...\n if (VecSize != ExpectedSize) {\n S.Diag(Attr.getLoc(), diag::err_attribute_bad_rvv_vector_size) << VecSize << ExpectedSize;"}} }, ["err_attribute_bad_sve_vector_size"]={ [c]={{nil,r,"err_attribute_bad_sve_vector_size"}}, [d]={{nil,r,"invalid SVE vector size \'%0\', must match value set by \'-msve-vector-bits\' (\'%1\')"}}, [e]={{nil,r,"invalid SVE vector size \'A\', must match value set by \'-msve-vector-bits\' (\'B\')"}}, [f]=k, [g]="invalid SVE vector size \'(.*?)\', must match value set by \'\\-msve\\-vector\\-bits\' \\(\'(.*?)\'\\)", [h]=a, [i]={{nil,r,m}}, [b]={sb,1582847864,Ab,xb}, [j]={{p,8288,"/// HandleArmSveVectorBitsTypeAttr - The \"arm_sve_vector_bits\" attribute is\n/// used to create fixed-length versions of sizeless SVE types defined by\n/// the ACLE, such as svint32_t and svbool_t.\nstatic void HandleArmSveVectorBitsTypeAttr(QualType &CurType, ParsedAttr &Attr, Sema &S) {\n // ...\n // The attribute vector size must match -msve-vector-bits.\n if (VecSize != S.getLangOpts().VScaleMin * 128) {\n S.Diag(Attr.getLoc(), diag::err_attribute_bad_sve_vector_size) << VecSize << S.getLangOpts().VScaleMin * 128;"}} }, ["err_attribute_bounds_for_function"]={ [c]={{nil,x,"err_attribute_bounds_for_function"}}, [d]={{nil,x,"%0 attribute references parameter %1, but the function %2 has only %3 parameters"}}, [e]={{nil,x,"A attribute references parameter B, but the function C has only D parameters"}}, [f]=k, [g]="(.*?) attribute references parameter (.*?), but the function (.*?) has only (.*?) parameters", [h]=a, [i]={{nil,x,m}}, [b]={"f9c3310d32c6",1616787805,"[OPENMP]Fix PR49366: crash on VLAs in task untied regions.","[OPENMP]Fix PR49366: crash on VLAs in task untied regions.\n\nWe need to capture the local variables into a record in task untied\nregions but clang does not support record with VLA data members.\n\nDifferential Revision: https://reviews.llvm.org/D99436"}, [j]={{n,1075,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n for (unsigned I = 1; I < AL.getNumArgs(); ++I) {\n // ...\n if (Index > DeclFD->getNumParams()) {\n S.Diag(AL.getLoc(), diag::err_attribute_bounds_for_function) << AL << Index << DeclFD << DeclFD->getNumParams();"}}, [l]={ ["clang/test/Sema/attr-diagnose-as-builtin.c"]={"clang/test/Sema/attr-diagnose-as-builtin.c:33:80: error: \'diagnose_as_builtin\' attribute references parameter 3, but the function \'failure_parameter_index_bounds\' has only 2 parameters"} } }, ["err_attribute_builtin_alias"]={ [c]={{nil,y,"err_attribute_builtin_alias"}}, [d]={{nil,E,"%0 attribute can only be applied to a ARM, HLSL or RISC-V builtin"},{x,y,"%0 attribute can only be applied to a ARM or RISC-V builtin"}}, [e]={{nil,E,"A attribute can only be applied to a ARM, HLSL or RISC-V builtin"},{x,y,"A attribute can only be applied to a ARM or RISC-V builtin"}}, [f]=k, [g]="(.*?) attribute can only be applied to a ARM, HLSL or RISC\\-V builtin", [h]=a, [i]={{nil,y,m}}, [b]={"b83b23275b74",1607502387,"Introduce -Wreserved-identifier","Introduce -Wreserved-identifier\n\nWarn when a declaration uses an identifier that doesn\'t obey the reserved\nidentifier rule from C and/or C++.\n\nDifferential Revision: https://reviews.llvm.org/D93095"}, [j]={{n,5859,"static void handleBuiltinAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if ((IsAArch64 && !ArmSveAliasValid(S.Context, BuiltinID, AliasName)) || (IsARM && !ArmMveAliasValid(BuiltinID, AliasName) && !ArmCdeAliasValid(BuiltinID, AliasName)) || (IsRISCV && !RISCVAliasValid(BuiltinID, AliasName)) || (!IsAArch64 && !IsARM && !IsRISCV && !IsHLSL)) {\n S.Diag(AL.getLoc(), diag::err_attribute_builtin_alias) << AL;"}} }, ["err_attribute_cleanup_arg_not_function"]={ [c]="err_attribute_cleanup_arg_not_function", [d]="\'cleanup\' argument %select{|%1 |%1 }0is not a %select{||single }0function", [e]={{nil,nil,{"\'cleanup\' argument ",{a,"B ","B "},"is not a ",{a,a,"single "},"function"}}}, [f]=k, [g]="\'cleanup\' argument (?:|(.*?) |(.*?) )is not a (?:||single )function", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{n,3710,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // gcc only allows for simple identifiers. Since we support more than gcc, we\n // will warn the user.\n if (auto *DRE = dyn_cast<DeclRefExpr>(E)) {\n // ...\n if (!FD) {\n S.Diag(Loc, diag::err_attribute_cleanup_arg_not_function) << 1 << NI.getName();"},{n,3720,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // gcc only allows for simple identifiers. Since we support more than gcc, we\n // will warn the user.\n if (auto *DRE = dyn_cast<DeclRefExpr>(E)) {\n // ...\n } else if (auto *ULE = dyn_cast<UnresolvedLookupExpr>(E)) {\n // ...\n if (!FD) {\n S.Diag(Loc, diag::err_attribute_cleanup_arg_not_function) << 2 << NI.getName();"},{n,3727,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // gcc only allows for simple identifiers. Since we support more than gcc, we\n // will warn the user.\n if (auto *DRE = dyn_cast<DeclRefExpr>(E)) {\n // ...\n } else if (auto *ULE = dyn_cast<UnresolvedLookupExpr>(E)) {\n // ...\n } else {\n S.Diag(Loc, diag::err_attribute_cleanup_arg_not_function) << 0;"}}, [l]={ ["clang/test/SemaCXX/attr-cleanup.cpp"]={"clang/test/SemaCXX/attr-cleanup.cpp:27:35: error: \'cleanup\' argument \'c3\' is not a single function"} } }, ["err_attribute_cleanup_func_arg_incompatible_type"]={ [c]="err_attribute_cleanup_func_arg_incompatible_type", [d]="\'cleanup\' function %0 parameter has %diff{type $ which is incompatible with type $|incompatible type}1,2", [e]={{nil,nil,{"\'cleanup\' function A parameter has ",{"type B which is incompatible with type C","incompatible type"}}}}, [f]=k, [g]="\'cleanup\' function (.*?) parameter has (?:type (.*?) which is incompatible with type (.*?)|incompatible type)", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{n,3743,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (S.CheckAssignmentConstraints(FD->getParamDecl(0)->getLocation(), ParamTy, Ty) != Sema::Compatible) {\n S.Diag(Loc, diag::err_attribute_cleanup_func_arg_incompatible_type) << NI.getName() << ParamTy << Ty;"}}, [l]={ ["clang/test/Sema/attr-cleanup.c"]={"clang/test/Sema/attr-cleanup.c:32:35: error: \'cleanup\' function \'c3\' parameter has type \'struct s\' which is incompatible with type \'int *\'"} } }, ["err_attribute_cleanup_func_must_take_one_arg"]={ [c]="err_attribute_cleanup_func_must_take_one_arg", [d]="\'cleanup\' function %0 must take 1 parameter", [e]="\'cleanup\' function A must take 1 parameter", [f]=k, [g]="\'cleanup\' function (.*?) must take 1 parameter", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{n,3732,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (FD->getNumParams() != 1) {\n S.Diag(Loc, diag::err_attribute_cleanup_func_must_take_one_arg) << NI.getName();"}}, [l]={ ["clang/test/Sema/attr-cleanup.c"]={"clang/test/Sema/attr-cleanup.c:31:35: error: \'cleanup\' function \'c2\' must take 1 parameter"} } }, ["err_attribute_dll_ambiguous_default_ctor"]={ [c]="err_attribute_dll_ambiguous_default_ctor", [d]="\'__declspec(dllexport)\' cannot be applied to more than one default constructor in %0", [e]="\'__declspec(dllexport)\' cannot be applied to more than one default constructor in A", [f]=k, [g]="\'__declspec\\(dllexport\\)\' cannot be applied to more than one default constructor in (.*?)", [h]=a, [i]=m, [b]={"474b323a0387",1451540206,"[MSVC Compat] Diagnose multiple default ctors for dllexport\'d classes","[MSVC Compat] Diagnose multiple default ctors for dllexport\'d classes\n\nThe MS ABI emits a special default constructor closure thunk if a\ndefault constructor has a weird calling convention or default arguments.\n\nThe MS ABI has a quirk: there can be only one such thunk because the\nmangling scheme does not have room for distinct manglings. We must\nraise a diagnostic in this eventuality.\n\nN.B. MSVC sorta gets this right. Multiple default constructors result\nin the default constructor closure getting emitted but they seem to\nget confused by which default constructors are reasonable to reference\nfrom the closure. We try to be a little more careful which results in\nmild differences in behavior.\n\nllvm-svn: 256661"}, [j]={{M,6298,"static void checkForMultipleExportedDefaultConstructors(Sema &S, CXXRecordDecl *Class) {\n // ...\n for (Decl *Member : Class->decls()) {\n // ...\n if (LastExportedDefaultCtor) {\n S.Diag(LastExportedDefaultCtor->getLocation(), diag::err_attribute_dll_ambiguous_default_ctor) << Class;"}}, [l]={ ["clang/test/SemaCXX/dllexport.cpp"]={"clang/test/SemaCXX/dllexport.cpp:788:3: error: \'__declspec(dllexport)\' cannot be applied to more than one default constructor in \'ClassWithMultipleDefaultCtors\'","clang/test/SemaCXX/dllexport.cpp:793:25: error: \'__declspec(dllexport)\' cannot be applied to more than one default constructor in \'ClassTemplateWithMultipleDefaultCtors\'"} } }, ["err_attribute_dll_deleted"]={ [c]="err_attribute_dll_deleted", [d]="attribute %q0 cannot be applied to a deleted function", [e]="attribute A cannot be applied to a deleted function", [f]=k, [g]="attribute (.*?) cannot be applied to a deleted function", [h]=a, [i]=m, [b]={"9de0a57687b9",1401382279,"Sema: Functions with dll attributes cannot be deleted","Sema: Functions with dll attributes cannot be deleted\n\nllvm-svn: 209827"}, [j]={{M,17831,"void Sema::SetDeclDeleted(Decl *Dcl, SourceLocation DelLoc) {\n // ...\n // dllimport/dllexport cannot be deleted.\n if (const InheritableAttr *DLLAttr = getDLLAttr(Fn)) {\n Diag(Fn->getLocation(), diag::err_attribute_dll_deleted) << DLLAttr;"}}, [l]={ ["clang/test/SemaCXX/dllexport.cpp"]={"clang/test/SemaCXX/dllexport.cpp:247:28: error: attribute \'dllexport\' cannot be applied to a deleted function","clang/test/SemaCXX/dllexport.cpp:248:35: error: attribute \'dllexport\' cannot be applied to a deleted function","clang/test/SemaCXX/dllexport.cpp:705:25: error: attribute \'dllexport\' cannot be applied to a deleted function","clang/test/SemaCXX/dllexport.cpp:706:25: error: attribute \'dllexport\' cannot be applied to a deleted function","clang/test/SemaCXX/dllexport.cpp:707:25: error: attribute \'dllexport\' cannot be applied to a deleted function","clang/test/SemaCXX/dllexport.cpp:708:40: error: attribute \'dllexport\' cannot be applied to a deleted function","clang/test/SemaCXX/dllexport.cpp:709:25: error: attribute \'dllexport\' cannot be applied to a deleted function","clang/test/SemaCXX/dllexport.cpp:710:40: error: attribute \'dllexport\' cannot be applied to a deleted function","clang/test/SemaCXX/dllexport.cpp:711:30: error: attribute \'dllexport\' cannot be applied to a deleted function","clang/test/SemaCXX/dllexport.cpp:1111:47: error: attribute \'dllexport\' cannot be applied to a deleted function"} } }, ["err_attribute_dll_lambda"]={ [c]="err_attribute_dll_lambda", [d]="lambda cannot be declared %0", [e]="lambda cannot be declared A", [f]=k, [g]="lambda cannot be declared (.*?)", [h]=a, [i]=m, [b]={"5869ec4c6c62",1442351130,"MS ABI: Don\'t allow dllexport/import on lambdas","MS ABI: Don\'t allow dllexport/import on lambdas\n\nThis is to follow up on David\'s comment in\nhttp://reviews.llvm.org/D12422#235509\n\nllvm-svn: 247718"}, [j]={{n,2089,"static void handleCPUSpecificAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (const auto *MD = dyn_cast<CXXMethodDecl>(D)) {\n if (MD->getParent()->isLambda()) {\n S.Diag(AL.getLoc(), diag::err_attribute_dll_lambda) << AL;"},{n,8049,"static void handleDLLAttr(Sema &S, Decl *D, const ParsedAttr &A) {\n // ...\n if (const auto *MD = dyn_cast<CXXMethodDecl>(D)) {\n if ((S.Context.getTargetInfo().shouldDLLImportComdatSymbols()) && MD->getParent()->isLambda()) {\n S.Diag(A.getRange().getBegin(), diag::err_attribute_dll_lambda) << A;"}}, [l]={ ["clang/test/SemaCXX/attr-cpuspecific.cpp"]={"clang/test/SemaCXX/attr-cpuspecific.cpp:122:30: error: lambda cannot be declared \'cpu_dispatch\'"} } }, ["err_attribute_dll_member_of_dll_class"]={ [c]="err_attribute_dll_member_of_dll_class", [d]="attribute %q0 cannot be applied to member of %q1 class", [e]="attribute A cannot be applied to member of B class", [f]=k, [g]="attribute (.*?) cannot be applied to member of (.*?) class", [h]=a, [i]=m, [b]={"496524b4484b",1401502129,"Diagnose dll attribute on member of class that already has a dll attribute","Diagnose dll attribute on member of class that already has a dll attribute\n\nDifferential Revision: http://reviews.llvm.org/D3973\n\nllvm-svn: 209954"}, [j]={{M,6483,"/// Check class-level dllimport/dllexport attribute.\nvoid Sema::checkClassLevelDLLAttribute(CXXRecordDecl *Class) {\n // ...\n if (Context.getTargetInfo().shouldDLLImportComdatSymbols() && !ClassAttr->isInherited()) {\n // Diagnose dll attributes on members of class with dll attribute.\n for (Decl *Member : Class->decls()) {\n // ...\n Diag(MemberAttr->getLocation(), diag::err_attribute_dll_member_of_dll_class) << MemberAttr << ClassAttr;"}}, [l]={ ["clang/test/SemaCXX/dllimport.cpp"]={"clang/test/SemaCXX/dllimport.cpp:1487:19: error: attribute \'dllexport\' cannot be applied to member of \'dllimport\' class","clang/test/SemaCXX/dllimport.cpp:1488:19: error: attribute \'dllimport\' cannot be applied to member of \'dllimport\' class","clang/test/SemaCXX/dllimport.cpp:1498:19: error: attribute \'dllimport\' cannot be applied to member of \'dllexport\' class","clang/test/SemaCXX/dllimport.cpp:1499:19: error: attribute \'dllexport\' cannot be applied to member of \'dllexport\' class"} } }, ["err_attribute_dll_not_extern"]={ [c]="err_attribute_dll_not_extern", [d]="%q0 must have external linkage when declared %q1", [e]="A must have external linkage when declared B", [f]=k, [g]="(.*?) must have external linkage when declared (.*?)", [h]=a, [i]=m, [b]={"8ca0bfc57ff5",1396277818,"Sema: Require external linkage for dll attributes","Sema: Require external linkage for dll attributes\n\nllvm-svn: 205198"}, [j]={{o,7003,"static void checkAttributesAfterMerging(Sema &S, NamedDecl &ND) {\n // ...\n if (const InheritableAttr *Attr = getDLLAttr(&ND)) {\n // ...\n if ((ND.isExternallyVisible() && AnonNSInMicrosoftMode) || (!AnonNSInMicrosoftMode && (!ND.isExternallyVisible() || (VD && VD->isStaticLocal())))) {\n S.Diag(ND.getLocation(), diag::err_attribute_dll_not_extern) << &ND << Attr;"},{M,6467,"/// Check class-level dllimport/dllexport attribute.\nvoid Sema::checkClassLevelDLLAttribute(CXXRecordDecl *Class) {\n // ...\n if (!Class->isExternallyVisible()) {\n Diag(Class->getLocation(), diag::err_attribute_dll_not_extern) << Class << ClassAttr;"}}, [l]={ ["clang/test/Sema/dllexport-2.cpp"]={"clang/test/Sema/dllexport-2.cpp:11:33: error: \'j\' must have external linkage when declared \'dllexport\'","clang/test/Sema/dllexport-2.cpp:21:28: error: \'j2\' must have external linkage when declared \'dllexport\'"} } }, ["err_attribute_dll_redeclaration"]={ [c]="err_attribute_dll_redeclaration", [d]="redeclaration of %q0 cannot add %q1 attribute", [e]="redeclaration of A cannot add B attribute", [f]=k, [g]="redeclaration of (.*?) cannot add (.*?) attribute", [h]=a, [i]=m, [b]={"82f0b06749e5",1396277775,"Sema: Check dll attributes on redeclarations","Sema: Check dll attributes on redeclarations\n\nA redeclaration may not add dllimport or dllexport attributes. dllexport is\nsticky and can be omitted on redeclarations while dllimport cannot.\n\nllvm-svn: 205197"}, [j]={{o,7093,"static void checkDLLAttributeRedeclaration(Sema &S, NamedDecl *OldDecl, NamedDecl *NewDecl, bool IsSpecialization, bool IsDefinition) {\n // ...\n if (AddsAttr && !IsSpecialization && !OldDecl->isImplicit()) {\n // ...\n unsigned DiagID = JustWarn ? diag::warn_attribute_dll_redeclaration : diag::err_attribute_dll_redeclaration;"}}, [l]={ ["clang/test/Sema/dllexport.c"]={"clang/test/Sema/dllexport.c:49:34: error: redeclaration of \'GlobalRedecl3\' cannot add \'dllexport\' attribute","clang/test/Sema/dllexport.c:104:28: error: redeclaration of \'redecl4\' cannot add \'dllexport\' attribute","clang/test/Sema/dllexport.c:108:35: error: redeclaration of \'redecl5\' cannot add \'dllexport\' attribute"} } }, ["err_attribute_dll_thread_local"]={ [c]="err_attribute_dll_thread_local", [d]="%q0 cannot be thread local when declared %q1", [e]="A cannot be thread local when declared B", [f]=k, [g]="(.*?) cannot be thread local when declared (.*?)", [h]=a, [i]=m, [b]={"5da21da4f6d7",1412405514,"MS ABI: Disallow dllimported/exported variables from having TLS","MS ABI: Disallow dllimported/exported variables from having TLS\n\nWindows TLS relies on indexing through a tls_index in order to get at\nthe DLL\'s thread local variables. However, this index is not exported\nalong with the variable: it is assumed that all accesses to thread local\nvariables are inside the same module which created the variable in the\nfirst place.\n\nWhile there are several implementation techniques we could adopt to fix\nthis (notably, the Itanium ABI gets this for free), it is not worth the\nheroics.\n\nInstead, let\'s just ban this combination. We could revisit this in the\nfuture if we need to.\n\nThis fixes PR21111.\n\nllvm-svn: 219049"}, [j]={{o,14463,"/// FinalizeDeclaration - called by ParseDeclarationAfterDeclarator to perform\n/// any semantic actions necessary after any initializer has been attached.\nvoid Sema::FinalizeDeclaration(Decl *ThisDecl) {\n // ...\n // dllimport/dllexport variables cannot be thread local, their TLS index\n // isn\'t exported with the variable.\n if (DLLAttr && VD->getTLSKind()) {\n // ...\n if (F && getDLLAttr(F)) {\n // ...\n } else {\n Diag(VD->getLocation(), diag::err_attribute_dll_thread_local) << VD << DLLAttr;"}}, [l]={ ["clang/test/Sema/dllexport.c"]={"clang/test/Sema/dllexport.c:59:36: error: \'ThreadLocalGlobal\' cannot be thread local when declared \'dllexport\'"} } }, ["err_attribute_dllimport_data_definition"]={ [c]="err_attribute_dllimport_data_definition", [d]="definition of dllimport data", [e]="definition of dllimport data", [f]=k, [g]="definition of dllimport data", [h]=a, [i]=m, [b]={"8e9791f62c45",1393450033,"Sema: Definition of dllimport globals is not allowed","Sema: Definition of dllimport globals is not allowed\n\nUpgrades the warning to an error and clarifies the message by treating the\ndefinition as error instead of the attribute.\n\nllvm-svn: 202300"}, [j]={{o,13179,"/// AddInitializerToDecl - Adds the initializer Init to the\n/// declaration dcl. If DirectInit is true, this is C++ direct\n/// initialization rather than copy initialization.\nvoid Sema::AddInitializerToDecl(Decl *RealDecl, Expr *Init, bool DirectInit) {\n // ...\n // dllimport cannot be used on variable definitions.\n if (VDecl->hasAttr<DLLImportAttr>() && !VDecl->isStaticDataMember()) {\n Diag(VDecl->getLocation(), diag::err_attribute_dllimport_data_definition);"}}, [l]={ ["clang/test/Sema/dllimport.c"]={"clang/test/Sema/dllimport.c:44:34: error: definition of dllimport data","clang/test/Sema/dllimport.c:45:27: error: definition of dllimport data","clang/test/Sema/dllimport.c:46:27: error: definition of dllimport data","clang/test/Sema/dllimport.c:137:36: error: definition of dllimport data","clang/test/Sema/dllimport.c:139:36: error: definition of dllimport data"} } }, ["err_attribute_dllimport_function_definition"]={ [c]="err_attribute_dllimport_function_definition", [d]="dllimport cannot be applied to non-inline function definition", [e]="dllimport cannot be applied to non-inline function definition", [f]=k, [g]="dllimport cannot be applied to non\\-inline function definition", [h]=a, [i]=m, [b]={"b0f2f146bb65",1400191669,"Allow dllimport/dllexport on inline functions and adjust the linkage.","Allow dllimport/dllexport on inline functions and adjust the linkage.\n\nThis is a step towards handling these attributes on classes (PR11170).\n\nDifferential Revision: http://reviews.llvm.org/D3772\n\nllvm-svn: 208925"}, [j]={{o,15420,"Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D, SkipBodyInfo *SkipBody, FnBodyKind BodyKind) {\n // ...\n // dllimport cannot be applied to non-inline function definitions.\n if (FD->hasAttr<DLLImportAttr>() && !FD->isInlined() && !FD->isTemplateInstantiation()) {\n // ...\n Diag(FD->getLocation(), diag::err_attribute_dllimport_function_definition);"}}, [l]={ ["clang/test/SemaCXX/MicrosoftExtensions.cpp"]={"clang/test/SemaCXX/MicrosoftExtensions.cpp:188:33: error: dllimport cannot be applied to non-inline function definition"} } }, ["err_attribute_dllimport_function_specialization_definition"]={ [c]={{nil,I,"err_attribute_dllimport_function_specialization_definition"}}, [d]={{nil,I,"cannot define non-inline dllimport template specialization"}}, [e]={{nil,I,"cannot define non-inline dllimport template specialization"}}, [f]=k, [g]="cannot define non\\-inline dllimport template specialization", [h]=a, [i]={{nil,I,m}}, [b]={eb,1625925174,gb,hb}, [j]={{o,7130,"static void checkDLLAttributeRedeclaration(Sema &S, NamedDecl *OldDecl, NamedDecl *NewDecl, bool IsSpecialization, bool IsDefinition) {\n // ...\n if (OldImportAttr && !HasNewAttr && (!IsInline || (IsMicrosoftABI && IsTemplate)) && !IsStaticDataMember && !NewDecl->isLocalExternDecl() && !IsQualifiedFriend) {\n if (IsMicrosoftABI && IsDefinition) {\n if (IsSpecialization) {\n S.Diag(NewDecl->getLocation(), diag::err_attribute_dllimport_function_specialization_definition);"}}, [l]={ ["clang/test/SemaCXX/dllimport.cpp"]={"clang/test/SemaCXX/dllimport.cpp:1322:33: error: cannot define non-inline dllimport template specialization","clang/test/SemaCXX/dllimport.cpp:1326:33: error: cannot define non-inline dllimport template specialization","clang/test/SemaCXX/dllimport.cpp:1332:47: error: cannot define non-inline dllimport template specialization"} } }, ["err_attribute_dllimport_static_field_definition"]={ [c]="err_attribute_dllimport_static_field_definition", [d]="definition of dllimport static field not allowed", [e]="definition of dllimport static field not allowed", [f]=k, [g]="definition of dllimport static field not allowed", [h]=a, [i]=m, [b]={"078d2f89cd6a",1401382220,"Sema: Check dll attributes on static data members","Sema: Check dll attributes on static data members\n\nRedeclarations cannot add a dll attribute and static data members cannot\nbe defined.\n\nllvm-svn: 209825"}, [j]={{o,14446,"/// FinalizeDeclaration - called by ParseDeclarationAfterDeclarator to perform\n/// any semantic actions necessary after any initializer has been attached.\nvoid Sema::FinalizeDeclaration(Decl *ThisDecl) {\n // ...\n // Imported static data members cannot be defined out-of-line.\n if (const auto *IA = dyn_cast_or_null<DLLImportAttr>(DLLAttr)) {\n if (VD->isStaticDataMember() && VD->isOutOfLine() && VD->isThisDeclarationADefinition()) {\n // ...\n Diag(VD->getLocation(), IsClassTemplateMember ? diag::warn_attribute_dllimport_static_field_definition : diag::err_attribute_dllimport_static_field_definition);"}}, [l]={ ["clang/test/SemaCXX/dllimport.cpp"]={"clang/test/SemaCXX/dllimport.cpp:641:28: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:642:28: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:680:53: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:681:53: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:844:49: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:847:49: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:923:52: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:924:52: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:972:71: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:975:71: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:1107:56: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:1126:56: error: definition of dllimport static field not allowed","clang/test/SemaCXX/dllimport.cpp:1506:13: error: definition of dllimport static field not allowed"} } }, ["err_attribute_integers_only"]={ [c]="err_attribute_integers_only", [d]="%0 attribute argument may only refer to a function parameter of integer type", [e]="A attribute argument may only refer to a function parameter of integer type", [f]=k, [g]="(.*?) attribute argument may only refer to a function parameter of integer type", [h]=a, [i]=m, [b]={"a747027bc645",1482195942,"Add the alloc_size attribute to clang.","Add the alloc_size attribute to clang.\n\nThis patch does three things:\n\n- Gives us the alloc_size attribute in clang, which lets us infer the\n number of bytes handed back to us by malloc/realloc/calloc/any user\n functions that act in a similar manner.\n- Teaches our constexpr evaluator that evaluating some `const` variables\n is OK sometimes. This is why we have a change in\n test/SemaCXX/constant-expression-cxx11.cpp and other seemingly\n unrelated tests. Richard Smith okay\'ed this idea some time ago in\n person.\n- Uniques some Blocks in CodeGen, which was reviewed separately at\n D26410. Lack of uniquing only really shows up as a problem when\n combined with our new eagerness in the face of const.\n\nDifferential Revision: https://reviews.llvm.org/D14274\n\nllvm-svn: 290149"}, [j]={{n,820,"/// Checks to be sure that the given parameter number is in bounds, and\n/// is an integral type. Will emit appropriate diagnostics if this returns\n/// false.\n///\n/// AttrArgNo is used to actually retrieve the argument, so it\'s base-0.\ntemplate <typename AttrInfo> static bool checkParamIsIntegerType(Sema &S, const Decl *D, const AttrInfo &AI, unsigned AttrArgNo) {\n // ...\n if (!ParamTy->isIntegerType() && !ParamTy->isCharType()) {\n // ...\n S.Diag(SrcLoc, diag::err_attribute_integers_only) << AI << getFunctionOrMethodParamRange(D, Idx.getASTIndex());"},{n,1754,"void Sema::AddAllocAlignAttr(Decl *D, const AttributeCommonInfo &CI, Expr *ParamExpr) {\n // ...\n if (!Ty->isDependentType() && !Ty->isIntegralType(Context) && !Ty->isAlignValT()) {\n Diag(ParamExpr->getBeginLoc(), diag::err_attribute_integers_only) << &TmpAttr << FuncDecl->getParamDecl(Idx.getASTIndex())->getSourceRange();"}}, [l]={ ["clang/test/Sema/alloc-align-attr.c"]={"clang/test/Sema/alloc-align-attr.c:10:69: error: \'alloc_align\' attribute argument may only refer to a function parameter of integer type"} } }, ["err_attribute_invalid_argument"]={ [c]={{nil,s,"err_attribute_invalid_argument"}}, [d]={{nil,s,"%select{a reference type|an array type|a non-vector or non-vectorizable scalar type}0 is an invalid argument to attribute %1"}}, [e]={{nil,s,{{"a reference type","an array type","a non-vector or non-vectorizable scalar type"}," is an invalid argument to attribute B"}}}, [f]=k, [g]="(?:a reference type|an array type|a non\\-vector or non\\-vectorizable scalar type) is an invalid argument to attribute (.*?)", [h]=a, [i]={{nil,s,m}}, [b]={"d293cbd5fd44",1564077051,"Add lifetime categories attributes","Add lifetime categories attributes\n\nSummary:\nThis is the first part of work announced in\n\"[RFC] Adding lifetime analysis to clang\" [0],\ni.e. the addition of the [[gsl::Owner(T)]] and\n[[gsl::Pointer(T)]] attributes, which\nwill enable user-defined types to participate in\nthe lifetime analysis (which will be part of the\nnext PR).\nThe type `T` here is called \"DerefType\" in the paper,\nand denotes the type that an Owner owns and a Pointer\npoints to. E.g. `std::vector<int>` should be annotated\nwith `[[gsl::Owner(int)]]` and\na `std::vector<int>::iterator` with `[[gsl::Pointer(int)]]`.\n\n[0] http://lists.llvm.org/pipermail/cfe-dev/2018-November/060355.html\n\nReviewers: gribozavr\n\nSubscribers: xazax.hun, cfe-commits\n\nTags: #clang\n\nDifferential Revision: https://reviews.llvm.org/D63954\n\nllvm-svn: 367040"}, [j]={{n,3271,"static void handleVecTypeHint(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (!ParmType->isExtVectorType() && !ParmType->isFloatingType() && (ParmType->isBooleanType() || !ParmType->isIntegralType(S.getASTContext()))) {\n S.Diag(AL.getLoc(), diag::err_attribute_invalid_argument) << 2 << AL;"},{n,5236,"static void handleLifetimeCategoryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (AL.hasParsedType()) {\n // ...\n if (SelectIdx != ~0U) {\n S.Diag(AL.getLoc(), diag::err_attribute_invalid_argument) << SelectIdx << AL;"}}, [l]={ ["clang/test/SemaOpenCL/invalid-kernel-attrs.cl"]={"clang/test/SemaOpenCL/invalid-kernel-attrs.cl:7:23: error: a non-vector or non-vectorizable scalar type is an invalid argument to attribute \'vec_type_hint\'","clang/test/SemaOpenCL/invalid-kernel-attrs.cl:9:23: error: a non-vector or non-vectorizable scalar type is an invalid argument to attribute \'vec_type_hint\'"} } }, ["err_attribute_invalid_bitint_vector_type"]={ [c]={{nil,I,"err_attribute_invalid_bitint_vector_type"}}, [d]={{nil,I,"\'_BitInt\' vector element width must be %select{a power of 2|at least as wide as \'CHAR_BIT\'}0"}}, [e]={{nil,I,{"\'_BitInt\' vector element width must be ",{"a power of 2","at least as wide as \'CHAR_BIT\'"}}}}, [f]=k, [g]="\'_BitInt\' vector element width must be (?:a power of 2|at least as wide as \'CHAR_BIT\')", [h]=a, [i]={{nil,I,m}}, [b]={eb,1625925174,gb,hb}, [j]={{p,2716,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n // ...\n // Only support _BitInt elements with byte-sized power of 2 NumBits.\n if (const auto *BIT = CurType->getAs<BitIntType>()) {\n // ...\n if (!llvm::isPowerOf2_32(NumBits) || NumBits < 8) {\n Diag(AttrLoc, diag::err_attribute_invalid_bitint_vector_type) << (NumBits < 8);"},{p,2797,"/// Build an ext-vector type.\n///\n/// Run the required checks for the extended vector type.\nQualType Sema::BuildExtVectorType(QualType T, Expr *ArraySize, SourceLocation AttrLoc) {\n // ...\n // Only support _BitInt elements with byte-sized power of 2 NumBits.\n if (T->isBitIntType()) {\n // ...\n if (!llvm::isPowerOf2_32(NumBits) || NumBits < 8) {\n Diag(AttrLoc, diag::err_attribute_invalid_bitint_vector_type) << (NumBits < 8);"}}, [l]={ ["clang/test/SemaCXX/ext-int.cpp"]={"clang/test/SemaCXX/ext-int.cpp:88:35: error: \'_BitInt\' vector element width must be at least as wide as \'CHAR_BIT\'","clang/test/SemaCXX/ext-int.cpp:90:35: error: \'_BitInt\' vector element width must be at least as wide as \'CHAR_BIT\'","clang/test/SemaCXX/ext-int.cpp:92:35: error: \'_BitInt\' vector element width must be at least as wide as \'CHAR_BIT\'","clang/test/SemaCXX/ext-int.cpp:94:35: error: \'_BitInt\' vector element width must be at least as wide as \'CHAR_BIT\'","clang/test/SemaCXX/ext-int.cpp:96:35: error: \'_BitInt\' vector element width must be at least as wide as \'CHAR_BIT\'","clang/test/SemaCXX/ext-int.cpp:98:35: error: \'_BitInt\' vector element width must be at least as wide as \'CHAR_BIT\'","clang/test/SemaCXX/ext-int.cpp:100:36: error: \'_BitInt\' vector element width must be a power of 2","clang/test/SemaCXX/ext-int.cpp:102:36: error: \'_BitInt\' vector element width must be a power of 2"} } }, ["err_attribute_invalid_implicit_this_argument"]={ [c]="err_attribute_invalid_implicit_this_argument", [d]="%0 attribute is invalid for the implicit this argument", [e]="A attribute is invalid for the implicit this argument", [f]=k, [g]="(.*?) attribute is invalid for the implicit this argument", [h]=a, [i]=m, [b]={"743682bb9f66",1289896543,"Re-work the handling of implicit \'this\' arguments and silly GCC-style attribute","Re-work the handling of implicit \'this\' arguments and silly GCC-style attribute\nargument indexes. This handles the offsets in a consistent manner for all of\nthe attributes which I saw working with these concepts. I\'ve also added tests\nfor the attribute that motivated this: nonnull.\n\nI consolidated the tests for format attributes into one file, and fleshed them\nout a bit to trigger more of the warning cases. Also improved the quality of\nsome of the diagnostics that occur with invalid argument indices.\n\nThe only really questionable change here is supporting the implicit this\nargument for the ownership attribute. I\'m not sure it\'s really a sensible\nconcept there, but implemented the logic for consistency.\n\nllvm-svn: 119339"}, [j]={{n,333,"/// Check if IdxExpr is a valid parameter index for a function or\n/// instance method D. May output an error.\n///\n/// \\returns true if IdxExpr is a valid index.\ntemplate <typename AttrInfo> static bool checkFunctionOrMethodParameterIndex(Sema &S, const Decl *D, const AttrInfo &AI, unsigned AttrArgNum, const Expr *IdxExpr, ParamIdx &Idx, bool CanIndexImplicitThis = false) {\n // ...\n if (HasImplicitThisParam && !CanIndexImplicitThis) {\n if (IdxSource == 1) {\n S.Diag(getAttrLoc(AI), diag::err_attribute_invalid_implicit_this_argument) << &AI << IdxExpr->getSourceRange();"}}, [l]={ ["clang/test/SemaCXX/alloc-align-attr.cpp"]={"clang/test/SemaCXX/alloc-align-attr.cpp:4:35: error: \'alloc_align\' attribute is invalid for the implicit this argument"} } }, ["err_attribute_invalid_matrix_type"]={ [c]={{nil,q,"err_attribute_invalid_matrix_type"}}, [d]={{nil,q,"invalid matrix element type %0"}}, [e]={{nil,q,"invalid matrix element type A"}}, [f]=k, [g]="invalid matrix element type (.*?)", [h]=a, [i]={{nil,q,m}}, [b]={Fb,1576908663,Gb,Hb}, [j]={{p,2842,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n // ...\n // Check element type, if it is not dependent.\n if (!ElementTy->isDependentType() && !MatrixType::isValidElementType(ElementTy)) {\n Diag(AttrLoc, diag::err_attribute_invalid_matrix_type) << ElementTy;"}}, [l]={ ["clang/test/SemaTemplate/matrix-type.cpp"]={"clang/test/SemaTemplate/matrix-type.cpp:120:28: error: invalid matrix element type \'s\'","clang/test/SemaTemplate/matrix-type.cpp:141:34: error: invalid matrix element type \'int_ptr\' (aka \'int *\')"} } }, ["err_attribute_invalid_on_decl"]={ [c]={{nil,E,"err_attribute_invalid_on_decl"}}, [d]="%0%select{ attribute|}1 cannot be applied to a declaration", [e]={{nil,nil,{"A",{" attribute",a}," cannot be applied to a declaration"}},{I,E,"A attribute cannot be applied to a declaration"}}, [f]=k, [g]="(.*?)(?: attribute|) cannot be applied to a declaration", [h]=a, [i]={{nil,E,m}}, [b]={eb,1625925174,gb,hb}, [j]={{n,8826,"/// ProcessDeclAttribute - Apply the specific attribute to the specified decl if\n/// the attribute applies to decls. If the attribute is a type attribute, just\n/// silently ignore it if a GNU attribute.\nstatic void ProcessDeclAttribute(Sema &S, Scope *scope, Decl *D, const ParsedAttr &AL, const Sema::ProcessDeclAttributeOptions &Options) {\n // ...\n default:\n // ...\n S.Diag(AL.getLoc(), diag::err_attribute_invalid_on_decl) << AL << AL.isRegularKeywordAttribute() << D->getLocation();"},{"clang/utils/TableGen/ClangAttrEmitter.cpp",3886,"static void GenerateAppertainsTo(const Record &Attr, raw_ostream &OS) {\n // ...\n if (DeclSubjects.empty()) {\n // If there are no decl subjects but there are stmt subjects, diagnose\n // trying to apply a statement attribute to a declaration.\n if (!StmtSubjects.empty()) {\n // ...\n OS << \" S.Diag(AL.getLoc(), diag::err_attribute_invalid_on_decl)\\n\";"}}, [l]={ ["clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.fallthrough/p1.cpp"]={"clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.fallthrough/p1.cpp:46:3: error: \'fallthrough\' attribute cannot be applied to a declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.fallthrough/p1.cpp:48:17: error: \'fallthrough\' attribute cannot be applied to a declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.fallthrough/p1.cpp:50:8: error: \'fallthrough\' attribute cannot be applied to a declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.fallthrough/p1.cpp:51:9: error: \'fallthrough\' attribute cannot be applied to a declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.fallthrough/p1.cpp:53:3: error: \'fallthrough\' attribute cannot be applied to a declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.fallthrough/p1.cpp:55:5: error: \'fallthrough\' attribute cannot be applied to a declaration"} } }, ["err_attribute_invalid_rvv_type"]={ [c]="err_attribute_invalid_rvv_type", [d]="%0 attribute applied to non-RVV type %1", [e]="A attribute applied to non-RVV type B", [f]=k, [g]="(.*?) attribute applied to non\\-RVV type (.*?)", [h]=a, [i]=m, [b]={eb,1625925174,gb,hb}, [j]={{p,8369,"/// HandleRISCVRVVVectorBitsTypeAttr - The \"riscv_rvv_vector_bits\" attribute is\n/// used to create fixed-length versions of sizeless RVV types such as\n/// vint8m1_t_t.\nstatic void HandleRISCVRVVVectorBitsTypeAttr(QualType &CurType, ParsedAttr &Attr, Sema &S) {\n // ...\n // Attribute can only be attached to a single RVV vector type.\n if (!CurType->isRVVVLSBuiltinType()) {\n S.Diag(Attr.getLoc(), diag::err_attribute_invalid_rvv_type) << Attr << CurType;"}}, [l]={ ["clang/test/Sema/attr-riscv-rvv-vector-bits.c"]={"clang/test/Sema/attr-riscv-rvv-vector-bits.c:232:50: error: \'riscv_rvv_vector_bits\' attribute applied to non-RVV type \'vbool1_t\' (aka \'__rvv_bool1_t\')","clang/test/Sema/attr-riscv-rvv-vector-bits.c:235:39: error: \'riscv_rvv_vector_bits\' attribute applied to non-RVV type \'void *\'","clang/test/Sema/attr-riscv-rvv-vector-bits.c:236:37: error: \'riscv_rvv_vector_bits\' attribute applied to non-RVV type \'int\'","clang/test/Sema/attr-riscv-rvv-vector-bits.c:237:39: error: \'riscv_rvv_vector_bits\' attribute applied to non-RVV type \'float\'"} } }, ["err_attribute_invalid_size"]={ [c]="err_attribute_invalid_size", [d]="vector size not an integral multiple of component size", [e]="vector size not an integral multiple of component size", [f]=k, [g]="vector size not an integral multiple of component size", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{p,2756,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n // ...\n if (!TypeSize || VectorSizeBits % TypeSize) {\n Diag(AttrLoc, diag::err_attribute_invalid_size) << SizeExpr->getSourceRange();"}}, [l]={ ["clang/test/SemaCUDA/amdgpu-bf16.cu"]={"clang/test/SemaCUDA/amdgpu-bf16.cu:57:35: error: vector size not an integral multiple of component size"} } }, ["err_attribute_invalid_sve_type"]={ [c]={{nil,r,"err_attribute_invalid_sve_type"}}, [d]={{nil,r,"%0 attribute applied to non-SVE type %1"}}, [e]={{nil,r,"A attribute applied to non-SVE type B"}}, [f]=k, [g]="(.*?) attribute applied to non\\-SVE type (.*?)", [h]=a, [i]={{nil,r,m}}, [b]={sb,1582847864,Ab,xb}, [j]={{p,8296,"/// HandleArmSveVectorBitsTypeAttr - The \"arm_sve_vector_bits\" attribute is\n/// used to create fixed-length versions of sizeless SVE types defined by\n/// the ACLE, such as svint32_t and svbool_t.\nstatic void HandleArmSveVectorBitsTypeAttr(QualType &CurType, ParsedAttr &Attr, Sema &S) {\n // ...\n // Attribute can only be attached to a single SVE vector or predicate type.\n if (!CurType->isVLSTBuiltinType()) {\n S.Diag(Attr.getLoc(), diag::err_attribute_invalid_sve_type) << Attr << CurType;"}}, [l]={ ["clang/test/Sema/attr-arm-sve-vector-bits.c"]={"clang/test/Sema/attr-arm-sve-vector-bits.c:81:39: error: \'arm_sve_vector_bits\' attribute applied to non-SVE type \'void *\'","clang/test/Sema/attr-arm-sve-vector-bits.c:82:37: error: \'arm_sve_vector_bits\' attribute applied to non-SVE type \'int\'","clang/test/Sema/attr-arm-sve-vector-bits.c:83:39: error: \'arm_sve_vector_bits\' attribute applied to non-SVE type \'float\'","clang/test/Sema/attr-arm-sve-vector-bits.c:84:44: error: \'arm_sve_vector_bits\' attribute applied to non-SVE type \'svint8x2_t\' (aka \'__clang_svint8x2_t\')","clang/test/Sema/attr-arm-sve-vector-bits.c:85:47: error: \'arm_sve_vector_bits\' attribute applied to non-SVE type \'svfloat32x3_t\' (aka \'__clang_svfloat32x3_t\')"} } }, ["err_attribute_invalid_vector_type"]={ [c]="err_attribute_invalid_vector_type", [d]="invalid vector element type %0", [e]="invalid vector element type A", [f]=k, [g]="invalid vector element type (.*?)", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{p,2709,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n // The base type must be integer (not Boolean or enumeration) or float, and\n // can\'t already be a vector.\n if ((!CurType->isDependentType() && (!CurType->isBuiltinType() || CurType->isBooleanType() || (!CurType->isIntegerType() && !CurType->isRealFloatingType())) && !CurType->isBitIntType()) || CurType->isArrayType()) {\n Diag(AttrLoc, diag::err_attribute_invalid_vector_type) << CurType;"},{p,2789,"/// Build an ext-vector type.\n///\n/// Run the required checks for the extended vector type.\nQualType Sema::BuildExtVectorType(QualType T, Expr *ArraySize, SourceLocation AttrLoc) {\n // ...\n if ((!T->isDependentType() && !T->isIntegerType() && !T->isRealFloatingType()) || (IsNoBoolVecLang && T->isBooleanType())) {\n Diag(AttrLoc, diag::err_attribute_invalid_vector_type) << T;"},{p,8231,"/// HandleNeonVectorTypeAttr - The \"neon_vector_type\" and\n/// \"neon_polyvector_type\" attributes are used to create vector types that\n/// are mangled according to ARM\'s ABI. Otherwise, these types are identical\n/// to those created with the \"vector_size\" attribute. Unlike \"vector_size\"\n/// the argument to these Neon attributes is the number of vector elements,\n/// not the vector size in bytes. The vector width and element type must\n/// match one of the standard Neon vector types.\nstatic void HandleNeonVectorTypeAttr(QualType &CurType, const ParsedAttr &Attr, Sema &S, VectorType::VectorKind VecKind) {\n // ...\n // Only certain element types are supported for Neon vectors.\n if (!isPermittedNeonBaseType(CurType, VecKind, S) && !IsTargetCUDAAndHostARM) {\n S.Diag(Attr.getLoc(), diag::err_attribute_invalid_vector_type) << CurType;"}}, [l]={ ["clang/test/Sema/ext_vector_casts.c"]={"clang/test/Sema/ext_vector_casts.c:56:25: error: invalid vector element type \'float2\' (vector of 2 \'float\' values)"} } }, ["err_attribute_missing_on_first_decl"]={ [c]={{nil,x,"err_attribute_missing_on_first_decl"}}, [d]={{nil,x,"%0 attribute does not appear on the first declaration"}}, [e]={{nil,x,"A attribute does not appear on the first declaration"}}, [f]=k, [g]="(.*?) attribute does not appear on the first declaration", [h]=a, [i]={{nil,x,m}}, [b]={"3dbcea8b957a",1615397021,"Reland [clang] Check unsupported types in expressions","Reland [clang] Check unsupported types in expressions\n\nThis was committed as ec6c847179fd, but then reverted after a failure\nin: https://lab.llvm.org/buildbot/#/builders/84/builds/13983\n\nI was not able to reproduce the problem, but I added an extra check\nfor a NULL QualType just in case.\n\nOriginal comit message:\n\nThe patch adds missing diagnostics for cases like:\n\n float F3 = ((__float128)F1 * (__float128)F2) / 2.0f;\n\nSema::checkDeviceDecl (renamed to checkTypeSupport) is changed to work\nwith a type without the corresponding ValueDecl. It is also refactored\nso that host diagnostics for unsupported types can be added here as\nwell.\n\nDifferential Revision: https://reviews.llvm.org/D109315"}, [j]={{o,3710,"/// MergeFunctionDecl - We just parsed a function \'New\' from\n/// declarator D which has the same name and scope as a previous\n/// declaration \'Old\'. Figure out how to resolve this situation,\n/// merging decls or emitting diagnostics as appropriate.\n///\n/// In C++, New and Old must be declarations that are not\n/// overloaded. Use IsOverload to determine whether New and Old are\n/// overloaded, and to select the Old declaration that New should be\n/// merged with.\n///\n/// Returns true if there was an error, false otherwise.\nbool Sema::MergeFunctionDecl(FunctionDecl *New, NamedDecl *&OldD, Scope *S, bool MergeTypeWithOld, bool NewDeclIsDefn) {\n // ...\n if (const auto *ILA = New->getAttr<InternalLinkageAttr>())\n if (!Old->hasAttr<InternalLinkageAttr>()) {\n Diag(New->getLocation(), diag::err_attribute_missing_on_first_decl) << ILA;"},{o,3718,"/// MergeFunctionDecl - We just parsed a function \'New\' from\n/// declarator D which has the same name and scope as a previous\n/// declaration \'Old\'. Figure out how to resolve this situation,\n/// merging decls or emitting diagnostics as appropriate.\n///\n/// In C++, New and Old must be declarations that are not\n/// overloaded. Use IsOverload to determine whether New and Old are\n/// overloaded, and to select the Old declaration that New should be\n/// merged with.\n///\n/// Returns true if there was an error, false otherwise.\nbool Sema::MergeFunctionDecl(FunctionDecl *New, NamedDecl *&OldD, Scope *S, bool MergeTypeWithOld, bool NewDeclIsDefn) {\n // ...\n if (auto *EA = New->getAttr<ErrorAttr>()) {\n if (!Old->hasAttr<ErrorAttr>()) {\n Diag(EA->getLocation(), diag::err_attribute_missing_on_first_decl) << EA;"},{o,4043,"/// MergeFunctionDecl - We just parsed a function \'New\' from\n/// declarator D which has the same name and scope as a previous\n/// declaration \'Old\'. Figure out how to resolve this situation,\n/// merging decls or emitting diagnostics as appropriate.\n///\n/// In C++, New and Old must be declarations that are not\n/// overloaded. Use IsOverload to determine whether New and Old are\n/// overloaded, and to select the Old declaration that New should be\n/// merged with.\n///\n/// Returns true if there was an error, false otherwise.\nbool Sema::MergeFunctionDecl(FunctionDecl *New, NamedDecl *&OldD, Scope *S, bool MergeTypeWithOld, bool NewDeclIsDefn) {\n // ...\n if (getLangOpts().CPlusPlus) {\n // ...\n // C++11 [dcl.attr.noreturn]p1:\n // The first declaration of a function shall specify the noreturn\n // attribute if any declaration of that function specifies the noreturn\n // attribute.\n if (const auto *NRA = New->getAttr<CXX11NoReturnAttr>())\n if (!Old->hasAttr<CXX11NoReturnAttr>()) {\n Diag(NRA->getLocation(), diag::err_attribute_missing_on_first_decl) << NRA;"},{o,4600,"/// MergeVarDecl - We just parsed a variable \'New\' which has the same name\n/// and scope as a previous declaration \'Old\'. Figure out how to resolve this\n/// situation, merging decls or emitting diagnostics as appropriate.\n///\n/// Tentative definition rules (C99 6.9.2p2) are checked by\n/// FinalizeDeclaratorGroup. Unfortunately, we can\'t analyze tentative\n/// definitions here, since the initializer hasn\'t been attached.\n///\nvoid Sema::MergeVarDecl(VarDecl *New, LookupResult &Previous) {\n // ...\n if (const auto *ILA = New->getAttr<InternalLinkageAttr>())\n if (!Old->hasAttr<InternalLinkageAttr>()) {\n Diag(New->getLocation(), diag::err_attribute_missing_on_first_decl) << ILA;"}}, [l]={ ["clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.noreturn/p1.cpp"]={"clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.noreturn/p1.cpp:28:3: error: \'noreturn\' attribute does not appear on the first declaration"} } }, ["err_attribute_multiple_objc_gc"]={ [c]="err_attribute_multiple_objc_gc", [d]="multiple garbage collection attributes specified for type", [e]="multiple garbage collection attributes specified for type", [f]=k, [g]="multiple garbage collection attributes specified for type", [h]=a, [i]=m, [b]={v,1237025389,w,u}, [j]={{p,7100,"/// handleObjCGCTypeAttr - Process the __attribute__((objc_gc)) type\n/// attribute on the specified type. Returns true to indicate that\n/// the attribute was handled, false to indicate that the type does\n/// not permit the attribute.\nstatic bool handleObjCGCTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n // ...\n if (type.getObjCGCAttr() != Qualifiers::GCNone) {\n S.Diag(attr.getLoc(), diag::err_attribute_multiple_objc_gc);"}} }, ["err_attribute_no_builtin_on_defaulted_deleted_function"]={ [c]={{nil,s,"err_attribute_no_builtin_on_defaulted_deleted_function"}}, [d]={{nil,s,"%0 attribute has no effect on defaulted or deleted functions"}}, [e]={{nil,s,"A attribute has no effect on defaulted or deleted functions"}}, [f]=k, [g]="(.*?) attribute has no effect on defaulted or deleted functions", [h]=a, [i]={{nil,s,m}}, [b]={"bd8791610948",1569403888,"[clang] Add no_builtin attribute","[clang] Add no_builtin attribute\n\nSummary:\nThis is a follow up on https://reviews.llvm.org/D61634\nThis patch is simpler and only adds the no_builtin attribute.\n\nReviewers: tejohnson, courbet, theraven, t.p.northover, jdoerfert\n\nSubscribers: mgrang, cfe-commits\n\nTags: #clang\n\nDifferential Revision: https://reviews.llvm.org/D68028"}, [j]={{o,10801,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\n // ...\n // Diagnose no_builtin attribute on function declaration that are not a\n // definition.\n // FIXME: We should really be doing this in\n // SemaDeclAttr.cpp::handleNoBuiltinAttr, unfortunately we only have access to\n // the FunctionDecl and at this point of the code\n // FunctionDecl::isThisDeclarationADefinition() which always returns `false`\n // because Sema::ActOnStartOfFunctionDef has not been called yet.\n if (const auto *NBA = NewFD->getAttr<NoBuiltinAttr>())\n // ...\n case FunctionDefinitionKind::Defaulted:\n case FunctionDefinitionKind::Deleted:\n Diag(NBA->getLocation(), diag::err_attribute_no_builtin_on_defaulted_deleted_function) << NBA->getSpelling();"}}, [l]={ ["clang/test/Sema/no-builtin.cpp"]={"clang/test/Sema/no-builtin.cpp:36:18: error: no_builtin attribute has no effect on defaulted or deleted functions","clang/test/Sema/no-builtin.cpp:41:18: error: no_builtin attribute has no effect on defaulted or deleted functions"} } }, ["err_attribute_no_builtin_on_non_definition"]={ [c]={{nil,s,"err_attribute_no_builtin_on_non_definition"}}, [d]={{nil,s,"%0 attribute is permitted on definitions only"}}, [e]={{nil,s,"A attribute is permitted on definitions only"}}, [f]=k, [g]="(.*?) attribute is permitted on definitions only", [h]=a, [i]={{nil,s,m}}, [b]={"bd8791610948",1569403888,"[clang] Add no_builtin attribute","[clang] Add no_builtin attribute\n\nSummary:\nThis is a follow up on https://reviews.llvm.org/D61634\nThis patch is simpler and only adds the no_builtin attribute.\n\nReviewers: tejohnson, courbet, theraven, t.p.northover, jdoerfert\n\nSubscribers: mgrang, cfe-commits\n\nTags: #clang\n\nDifferential Revision: https://reviews.llvm.org/D68028"}, [j]={{o,10805,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\n // ...\n // Diagnose no_builtin attribute on function declaration that are not a\n // definition.\n // FIXME: We should really be doing this in\n // SemaDeclAttr.cpp::handleNoBuiltinAttr, unfortunately we only have access to\n // the FunctionDecl and at this point of the code\n // FunctionDecl::isThisDeclarationADefinition() which always returns `false`\n // because Sema::ActOnStartOfFunctionDef has not been called yet.\n if (const auto *NBA = NewFD->getAttr<NoBuiltinAttr>())\n // ...\n case FunctionDefinitionKind::Declaration:\n Diag(NBA->getLocation(), diag::err_attribute_no_builtin_on_non_definition) << NBA->getSpelling();"}}, [l]={ ["clang/test/Sema/no-builtin.cpp"]={"clang/test/Sema/no-builtin.cpp:30:48: error: no_builtin attribute is permitted on definitions only","clang/test/Sema/no-builtin.cpp:44:34: error: no_builtin attribute is permitted on definitions only","clang/test/Sema/no-builtin.cpp:50:41: error: no_builtin attribute is permitted on definitions only"} } }, ["err_attribute_no_builtin_wildcard_or_builtin_name"]={ [c]={{nil,s,"err_attribute_no_builtin_wildcard_or_builtin_name"}}, [d]={{nil,s,"empty %0 cannot be composed with named ones"}}, [e]={{nil,s,"empty A cannot be composed with named ones"}}, [f]=k, [g]="empty (.*?) cannot be composed with named ones", [h]=a, [i]={{nil,s,m}}, [b]={"bd8791610948",1569403888,"[clang] Add no_builtin attribute","[clang] Add no_builtin attribute\n\nSummary:\nThis is a follow up on https://reviews.llvm.org/D61634\nThis patch is simpler and only adds the no_builtin attribute.\n\nReviewers: tejohnson, courbet, theraven, t.p.northover, jdoerfert\n\nSubscribers: mgrang, cfe-commits\n\nTags: #clang\n\nDifferential Revision: https://reviews.llvm.org/D68028"}, [j]={{n,1164,"static void handleNoBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // Empty no_builtin must be on its own.\n if (HasWildcard && Names.size() > 1)\n S.Diag(D->getLocation(), diag::err_attribute_no_builtin_wildcard_or_builtin_name) << AL;"}}, [l]={ ["clang/test/Sema/no-builtin.cpp"]={"clang/test/Sema/no-builtin.cpp:22:6: error: empty \'no_builtin\' cannot be composed with named ones"} } }, ["err_attribute_no_member_function"]={ [c]={{nil,x,"err_attribute_no_member_function"}}, [d]={{nil,x,"%0 attribute cannot be applied to non-static member functions"}}, [e]={{nil,x,"A attribute cannot be applied to non-static member functions"}}, [f]=k, [g]="(.*?) attribute cannot be applied to non\\-static member functions", [h]=a, [i]={{nil,x,m}}, [b]={"f9c3310d32c6",1616787805,"[OPENMP]Fix PR49366: crash on VLAs in task untied regions.","[OPENMP]Fix PR49366: crash on VLAs in task untied regions.\n\nWe need to capture the local variables into a record in task untied\nregions but clang does not support record with VLA data members.\n\nDifferential Revision: https://reviews.llvm.org/D99436"}, [j]={{n,1025,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n if (const auto *MethodDecl = dyn_cast<CXXMethodDecl>(DeclFD))\n if (!MethodDecl->isStatic()) {\n S.Diag(AL.getLoc(), diag::err_attribute_no_member_function) << AL;"}}, [l]={ ["clang/test/Sema/attr-diagnose-as-builtin.c"]={"clang/test/Sema/attr-diagnose-as-builtin.c:104:18: error: \'diagnose_as_builtin\' attribute cannot be applied to non-static member functions"} } }, ["err_attribute_no_member_pointers"]={ [c]="err_attribute_no_member_pointers", [d]="%0 attribute cannot be used with pointers to members", [e]="A attribute cannot be used with pointers to members", [f]=k, [g]="(.*?) attribute cannot be used with pointers to members", [h]=a, [i]=m, [b]={"317a77f1c7ab",1369265132,"Adding in parsing and the start of semantic support for __sptr and __uptr pointer type qualifiers. ...","Adding in parsing and the start of semantic support for __sptr and __uptr pointer type qualifiers. This patch also fixes the correlated __ptr32 and __ptr64 pointer qualifiers so that they are truly type attributes instead of declaration attributes.\n\nFor more information about __sptr and __uptr, see MSDN: http://msdn.microsoft.com/en-us/library/aa983399.aspx\n\nPatch reviewed by Richard Smith.\n\nllvm-svn: 182535"}, [j]={{p,7380,"static bool handleMSPointerTypeQualifierAttr(TypeProcessingState &State, ParsedAttr &PAttr, QualType &Type) {\n // ...\n // Check the raw (i.e., desugared) Canonical type to see if it\n // is a pointer type.\n if (!isa<PointerType>(Desugared)) {\n // Pointer type qualifiers can only operate on pointer types, but not\n // pointer-to-member types.\n if (Type->isMemberPointerType())\n S.Diag(PAttr.getLoc(), diag::err_attribute_no_member_pointers) << PAttr;"}}, [l]={ ["clang/test/Sema/MicrosoftCompatibility.cpp"]={"clang/test/Sema/MicrosoftCompatibility.cpp:10:15: error: \'__uptr\' attribute cannot be used with pointers to members"} } }, ["err_attribute_not_clinkage"]={ [c]={{nil,q,"err_attribute_not_clinkage"}}, [d]={{nil,q,"function type with %0 attribute must have C linkage"}}, [e]={{nil,q,"function type with A attribute must have C linkage"}}, [f]=k, [g]="function type with (.*?) attribute must have C linkage", [h]=a, [i]={{nil,q,m}}, [b]={Fb,1576908663,Gb,Hb}, [j]={{n,2146,"static void handleCmseNSEntryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (S.LangOpts.CPlusPlus && !D->getDeclContext()->isExternCContext()) {\n S.Diag(AL.getLoc(), diag::err_attribute_not_clinkage) << AL;"}}, [l]={ ["clang/test/SemaCXX/arm-cmse.cpp"]={"clang/test/SemaCXX/arm-cmse.cpp:5:27: error: function type with \'cmse_nonsecure_entry\' attribute must have C linkage"} } }, ["err_attribute_not_import_attr"]={ [c]="err_attribute_not_import_attr", [d]="%0 attribute cannot be applied to a module import", [e]="A attribute cannot be applied to a module import", [f]=k, [g]="(.*?) attribute cannot be applied to a module import", [h]=a, [i]="Modules Issue", [b]={"49cc1ccb00df",1471557582,"C++ Modules TS: Add parsing support for module import declaration.","C++ Modules TS: Add parsing support for module import declaration.\n\nllvm-svn: 279163"}, [j]={{"clang/lib/Parse/Parser.cpp",2534,"/// Parse a module import declaration. This is essentially the same for\n/// Objective-C and C++20 except for the leading \'@\' (in ObjC) and the\n/// trailing optional attributes (in C++).\n///\n/// [ObjC] @import declaration:\n/// \'@\' \'import\' module-name \';\'\n/// [ModTS] module-import-declaration:\n/// \'import\' module-name attribute-specifier-seq[opt] \';\'\n/// [C++20] module-import-declaration:\n/// \'export\'[opt] \'import\' module-name\n/// attribute-specifier-seq[opt] \';\'\n/// \'export\'[opt] \'import\' module-partition\n/// attribute-specifier-seq[opt] \';\'\n/// \'export\'[opt] \'import\' header-name\n/// attribute-specifier-seq[opt] \';\'\nDecl *Parser::ParseModuleImport(SourceLocation AtLoc, Sema::ModuleImportState &ImportState) {\n // ...\n ProhibitCXX11Attributes(Attrs, diag::err_attribute_not_import_attr, diag::err_keyword_not_import_attr,"}} }, ["err_attribute_not_module_attr"]={ [c]="err_attribute_not_module_attr", [d]="%0 attribute cannot be applied to a module", [e]="A attribute cannot be applied to a module", [f]=k, [g]="(.*?) attribute cannot be applied to a module", [h]=a, [i]="Modules Issue", [b]={"964cc53d9a74",1471570986,"C++ Modules TS: support parsing the \'module\' declaration (including extensions","C++ Modules TS: support parsing the \'module\' declaration (including extensions\nfrom p0273r0 approved by EWG). We\'ll eventually need to handle this from the\nlexer as well, in order to disallow preprocessor directives preceding the\nmodule declaration and to support macro import.\n\nllvm-svn: 279196"}, [j]={{"clang/lib/Parse/Parser.cpp",2464,"/// Parse a declaration beginning with the \'module\' keyword or C++20\n/// context-sensitive keyword (optionally preceded by \'export\').\n///\n/// module-declaration: [C++20]\n/// \'export\'[opt] \'module\' module-name attribute-specifier-seq[opt] \';\'\n///\n/// global-module-fragment: [C++2a]\n/// \'module\' \';\' top-level-declaration-seq[opt]\n/// module-declaration: [C++2a]\n/// \'export\'[opt] \'module\' module-name module-partition[opt]\n/// attribute-specifier-seq[opt] \';\'\n/// private-module-fragment: [C++2a]\n/// \'module\' \':\' \'private\' \';\' top-level-declaration-seq[opt]\nParser::DeclGroupPtrTy Parser::ParseModuleDecl(Sema::ModuleImportState &ImportState) {\n // ...\n ProhibitCXX11Attributes(Attrs, diag::err_attribute_not_module_attr, diag::err_keyword_not_module_attr,"}} }, ["err_attribute_not_supported_in_lang"]={ [c]="err_attribute_not_supported_in_lang", [d]="%0 attribute is not supported in %select{C|C++|Objective-C}1", [e]={{nil,nil,{"A attribute is not supported in ",{Cb,"C++",Jb}}}}, [f]=k, [g]="(.*?) attribute is not supported in (?:C|C\\+\\+|Objective\\-C)", [h]=a, [i]=m, [b]={"df8fe4c91cf2",1385328916,"__declspec(uuid) is only supported for C++ code according to MSDN (as well as behaviorally in MSVC)....","__declspec(uuid) is only supported for C++ code according to MSDN (as well as behaviorally in MSVC). This adds a generic diagnostic that we use for uuid, and can use for some other attributes as well, and adds a testcase.\n\nllvm-svn: 195580"}, [j]={{n,2136,"static void handleCommonAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (S.LangOpts.CPlusPlus) {\n S.Diag(AL.getLoc(), diag::err_attribute_not_supported_in_lang) << AL << AttributeLangSupport::Cpp;"},{n,6989,"static void handleUuidAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!S.LangOpts.CPlusPlus) {\n S.Diag(AL.getLoc(), diag::err_attribute_not_supported_in_lang) << AL << AttributeLangSupport::C;"},{n,7291,"static void handleMSInheritanceAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!S.LangOpts.CPlusPlus) {\n S.Diag(AL.getLoc(), diag::err_attribute_not_supported_in_lang) << AL << AttributeLangSupport::C;"}}, [l]={ ["clang/test/SemaCXX/attr-common.cpp"]={"clang/test/SemaCXX/attr-common.cpp:3:16: error: \'common\' attribute is not supported in C++"} } }, ["err_attribute_not_supported_on_arch"]={ [c]={{nil,T,"err_attribute_not_supported_on_arch"}}, [d]={{nil,T,"%0 attribute is not supported on \'%1\'"}}, [e]={{nil,T,"A attribute is not supported on \'B\'"}}, [f]=k, [g]="(.*?) attribute is not supported on \'(.*?)\'", [h]=a, [i]={{nil,T,m}}, [b]={"b51bcaf2f027",1491578027,"Sema: prevent __declspec(naked) use on x64","Sema: prevent __declspec(naked) use on x64\n\nMSDN (https://msdn.microsoft.com/en-us/library/h5w10wxs.aspx) indicates\nthat `__declspec(naked)` is only permitted on x86 and ARM targets.\nTesting with cl does confirm this behaviour. Provide a warning for use\nof `__declspec(naked)` on x64.\n\nllvm-svn: 299774"}, [j]={{n,2165,"static void handleNakedAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isDeclspecAttribute()) {\n // ...\n if (Arch != llvm::Triple::x86 && (Arch != llvm::Triple::arm && Arch != llvm::Triple::thumb)) {\n S.Diag(AL.getLoc(), diag::err_attribute_not_supported_on_arch) << AL << Triple.getArchName();"}}, [l]={ ["clang/test/Sema/declspec-naked.c"]={"clang/test/Sema/declspec-naked.c:8:17: error: \'naked\' attribute is not supported on \'x86_64\'"} } }, ["err_attribute_not_type_attr"]={ [c]="err_attribute_not_type_attr", [d]="%0%select{ attribute|}1 cannot be applied to types", [e]={{nil,nil,{"A",{" attribute",a}," cannot be applied to types"}},{I,nil,"A attribute cannot be applied to types"}}, [f]=k, [g]="(.*?)(?: attribute|) cannot be applied to types", [h]=a, [i]=V, [b]={"10876ef5714f",1358386242,"Implement C++11 semantics for [[noreturn]] attribute. This required splitting","Implement C++11 semantics for [[noreturn]] attribute. This required splitting\nit apart from [[gnu::noreturn]] / __attribute__((noreturn)), since their\nsemantics are not equivalent (for instance, we treat [[gnu::noreturn]] as\naffecting the function type, whereas [[noreturn]] does not).\n\nllvm-svn: 172691"}, [j]={{Bb,3352,"/// ParseDeclarationSpecifiers\n/// declaration-specifiers: [C99 6.7]\n/// storage-class-specifier declaration-specifiers[opt]\n/// type-specifier declaration-specifiers[opt]\n/// [C99] function-specifier declaration-specifiers[opt]\n/// [C11] alignment-specifier declaration-specifiers[opt]\n/// [GNU] attributes declaration-specifiers[opt]\n/// [Clang] \'__module_private__\' declaration-specifiers[opt]\n/// [ObjC1] \'__kindof\' declaration-specifiers[opt]\n///\n/// storage-class-specifier: [C99 6.7.1]\n/// \'typedef\'\n/// \'extern\'\n/// \'static\'\n/// \'auto\'\n/// \'register\'\n/// [C++] \'mutable\'\n/// [C++11] \'thread_local\'\n/// [C11] \'_Thread_local\'\n/// [GNU] \'__thread\'\n/// function-specifier: [C99 6.7.4]\n/// [C99] \'inline\'\n/// [C++] \'virtual\'\n/// [C++] \'explicit\'\n/// [OpenCL] \'__kernel\'\n/// \'friend\': [C++ dcl.friend]\n/// \'constexpr\': [C++0x dcl.constexpr]\nvoid Parser::ParseDeclarationSpecifiers(DeclSpec &DS, const ParsedTemplateInfo &TemplateInfo, AccessSpecifier AS, DeclSpecContext DSContext, LateParsedAttrList *LateAttrs, ImplicitTypenameContext AllowImplicitTypename) {\n // ...\n while (true) {\n // ...\n DoneWithDeclSpec:\n if (!AttrsLastTime)\n // ...\n else {\n // Reject C++11 / C2x attributes that aren\'t type attributes.\n for (const ParsedAttr &PA : attrs) {\n // ...\n Diag(PA.getLoc(), diag::err_attribute_not_type_attr) << PA << PA.isRegularKeywordAttribute();"},{p,8571,"static void processTypeAttrs(TypeProcessingState &state, QualType &type, TypeAttrLocation TAL, const ParsedAttributesView &attrs) {\n // ...\n for (ParsedAttr &attr : AttrsCopy) {\n // ...\n default:\n // A [[]] attribute on a declarator chunk must appertain to a type.\n if ((attr.isStandardAttributeSyntax() || attr.isRegularKeywordAttribute()) && TAL == TAL_DeclChunk) {\n state.getSema().Diag(attr.getLoc(), diag::err_attribute_not_type_attr) << attr << attr.isRegularKeywordAttribute();"}}, [l]={ ["clang/test/Sema/attr-only-in-default-eval.cpp"]={"clang/test/Sema/attr-only-in-default-eval.cpp:21:8: error: \'available_only_in_default_eval_method\' attribute cannot be applied to types","clang/test/Sema/attr-only-in-default-eval.cpp:23:14: error: \'available_only_in_default_eval_method\' attribute cannot be applied to types"} } }, ["err_attribute_only_once_per_parameter"]={ [c]="err_attribute_only_once_per_parameter", [d]="%0 attribute can only be applied once per parameter", [e]="A attribute can only be applied once per parameter", [f]=k, [g]="(.*?) attribute can only be applied once per parameter", [h]=a, [i]=m, [b]={"3e3bb95b6951",1449093488,"Add the `pass_object_size` attribute to clang.","Add the `pass_object_size` attribute to clang.\n\n`pass_object_size` is our way of enabling `__builtin_object_size` to\nproduce high quality results without requiring inlining to happen\neverywhere.\n\nA link to the design doc for this attribute is available at the\nDifferential review link below.\n\nDifferential Revision: http://reviews.llvm.org/D13263\n\nllvm-svn: 254554"}, [j]={{n,1175,"static void handlePassObjectSizeAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (D->hasAttr<PassObjectSizeAttr>()) {\n S.Diag(D->getBeginLoc(), diag::err_attribute_only_once_per_parameter) << AL;"}}, [l]={ ["clang/test/Sema/pass-object-size.c"]={"clang/test/Sema/pass-object-size.c:18:8: error: \'pass_object_size\' attribute can only be applied once per parameter"} } }, ["err_attribute_output_parameter"]={ [c]={{nil,s,"err_attribute_output_parameter"}}, [d]={{nil,s,"attribute only applies to output parameters"}}, [e]={{nil,s,"attribute only applies to output parameters"}}, [f]=k, [g]="attribute only applies to output parameters", [h]=a, [i]={{nil,s,m}}, [b]={"fe17b30a7957",1575504770,"[attributes][analyzer] Add annotations for handles.","[attributes][analyzer] Add annotations for handles.\n\nThese annotations will be used in an upcomming static analyzer check\nthat finds handle leaks, use after releases, and double releases.\n\nDifferential Revision: https://reviews.llvm.org/D70469"}, [j]={{n,8564,"static void handleAcquireHandleAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n // Warn if the parameter is definitely not an output parameter.\n if (const auto *PVD = dyn_cast<ParmVarDecl>(D)) {\n if (PVD->getType()->isIntegerType()) {\n S.Diag(AL.getLoc(), diag::err_attribute_output_parameter) << AL.getRange();"}}, [l]={ ["clang/test/Sema/attr-handles.cpp"]={"clang/test/Sema/attr-handles.cpp:7:29: error: attribute only applies to output parameters"} } }, ["err_attribute_overloadable_mismatch"]={ [c]={{nil,T,"err_attribute_overloadable_mismatch"}}, [d]={{nil,T,"redeclaration of %0 must %select{not |}1have the \'overloadable\' attribute"}}, [e]={{nil,T,{"redeclaration of A must ",{"not ",a},"have the \'overloadable\' attribute"}}}, [f]=k, [g]="redeclaration of (.*?) must (?:not |)have the \'overloadable\' attribute", [h]=a, [i]={{nil,T,m}}, [b]={"d3cf025ae221",1498599091,"[Sema] Allow unmarked overloadable functions.","[Sema] Allow unmarked overloadable functions.\n\nThis patch extends the `overloadable` attribute to allow for one\nfunction with a given name to not be marked with the `overloadable`\nattribute. The overload without the `overloadable` attribute will not\nhave its name mangled.\n\nSo, the following code is now legal:\n\n void foo(void) __attribute__((overloadable));\n void foo(int);\n void foo(float) __attribute__((overloadable));\n\nIn addition, this patch fixes a bug where we\'d accept code with\n`__attribute__((overloadable))` inconsistently applied. In other words,\nwe used to accept:\n\n void foo(void);\n void foo(void) __attribute__((overloadable));\n\nBut we will do this no longer, since it defeats the original purpose of\nrequiring `__attribute__((overloadable))` on all redeclarations of a\nfunction.\n\nThis breakage seems to not be an issue in practice, since the only code\nI could find that had this pattern often looked like:\n\n void foo(void);\n void foo(void) __attribute__((overloadable)) __asm__(\"foo\");\n void foo(int) __attribute__((overloadable));\n\n...Which can now be simplified by simply removing the asm label and\noverloadable attribute from the redeclaration of `void foo(void);`\n\nDifferential Revision: https://reviews.llvm.org/D32332\n\nllvm-svn: 306467"}, [j]={{o,3730,"/// MergeFunctionDecl - We just parsed a function \'New\' from\n/// declarator D which has the same name and scope as a previous\n/// declaration \'Old\'. Figure out how to resolve this situation,\n/// merging decls or emitting diagnostics as appropriate.\n///\n/// In C++, New and Old must be declarations that are not\n/// overloaded. Use IsOverload to determine whether New and Old are\n/// overloaded, and to select the Old declaration that New should be\n/// merged with.\n///\n/// Returns true if there was an error, false otherwise.\nbool Sema::MergeFunctionDecl(FunctionDecl *New, NamedDecl *&OldD, Scope *S, bool MergeTypeWithOld, bool NewDeclIsDefn) {\n // ...\n if (!getLangOpts().CPlusPlus) {\n // ...\n if (OldOvl != New->hasAttr<OverloadableAttr>() && !Old->isImplicit()) {\n Diag(New->getLocation(), diag::err_attribute_overloadable_mismatch) << New << OldOvl;"}}, [l]={ ["clang/test/Sema/overloadable.c"]={"clang/test/Sema/overloadable.c:9:6: error: redeclaration of \'f\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:79:35: error: redeclaration of \'invalid\' must not have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:182:6: error: redeclaration of \'to_foo0\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:187:6: error: redeclaration of \'to_foo1\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:189:6: error: redeclaration of \'to_foo1\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:193:6: error: redeclaration of \'to_foo2\' must not have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:194:6: error: redeclaration of \'to_foo2\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:196:6: error: redeclaration of \'to_foo2\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:202:6: error: redeclaration of \'to_foo3\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:205:6: error: redeclaration of \'to_foo4\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:218:6: error: redeclaration of \'to_foo6\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:222:6: error: redeclaration of \'to_foo7\' must not have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:233:6: error: redeclaration of \'to_foo9\' must not have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:244:6: error: redeclaration of \'to_foo10\' must have the \'overloadable\' attribute","clang/test/Sema/overloadable.c:245:6: error: redeclaration of \'to_foo10\' must have the \'overloadable\' attribute"} } }, ["err_attribute_overloadable_multiple_unmarked_overloads"]={ [c]={{nil,T,"err_attribute_overloadable_multiple_unmarked_overloads"}}, [d]={{nil,T,"at most one overload for a given name may lack the \'overloadable\' attribute"}}, [e]={{nil,T,"at most one overload for a given name may lack the \'overloadable\' attribute"}}, [f]=k, [g]="at most one overload for a given name may lack the \'overloadable\' attribute", [h]=a, [i]={{nil,T,m}}, [b]={"d3cf025ae221",1498599091,"[Sema] Allow unmarked overloadable functions.","[Sema] Allow unmarked overloadable functions.\n\nThis patch extends the `overloadable` attribute to allow for one\nfunction with a given name to not be marked with the `overloadable`\nattribute. The overload without the `overloadable` attribute will not\nhave its name mangled.\n\nSo, the following code is now legal:\n\n void foo(void) __attribute__((overloadable));\n void foo(int);\n void foo(float) __attribute__((overloadable));\n\nIn addition, this patch fixes a bug where we\'d accept code with\n`__attribute__((overloadable))` inconsistently applied. In other words,\nwe used to accept:\n\n void foo(void);\n void foo(void) __attribute__((overloadable));\n\nBut we will do this no longer, since it defeats the original purpose of\nrequiring `__attribute__((overloadable))` on all redeclarations of a\nfunction.\n\nThis breakage seems to not be an issue in practice, since the only code\nI could find that had this pattern often looked like:\n\n void foo(void);\n void foo(void) __attribute__((overloadable)) __asm__(\"foo\");\n void foo(int) __attribute__((overloadable));\n\n...Which can now be simplified by simply removing the asm label and\noverloadable attribute from the redeclaration of `void foo(void);`\n\nDifferential Revision: https://reviews.llvm.org/D32332\n\nllvm-svn: 306467"}, [j]={{o,11887,"/// Perform semantic checking of a new function declaration.\n///\n/// Performs semantic analysis of the new function declaration\n/// NewFD. This routine performs all semantic checking that does not\n/// require the actual declarator involved in the declaration, and is\n/// used both for the declaration of functions as they are parsed\n/// (called via ActOnDeclarator) and for the declaration of functions\n/// that have been instantiated via C++ template instantiation (called\n/// via InstantiateDecl).\n///\n/// \\param IsMemberSpecialization whether this new function declaration is\n/// a member specialization (that replaces any definition provided by the\n/// previous declaration).\n///\n/// This sets NewFD->isInvalidDecl() to true if there was an error.\n///\n/// \\returns true if the function declaration is a redeclaration.\nbool Sema::CheckFunctionDeclaration(Scope *S, FunctionDecl *NewFD, LookupResult &Previous, bool IsMemberSpecialization, bool DeclIsDefn) {\n // ...\n if (Redeclaration) {\n // ...\n } else if (!getLangOpts().CPlusPlus && MayNeedOverloadableChecks && !NewFD->getAttr<OverloadableAttr>()) {\n // ...\n if (OtherUnmarkedIter != Previous.end()) {\n Diag(NewFD->getLocation(), diag::err_attribute_overloadable_multiple_unmarked_overloads);"}}, [l]={ ["clang/test/Sema/overloadable.c"]={"clang/test/Sema/overloadable.c:211:6: error: at most one overload for a given name may lack the \'overloadable\' attribute","clang/test/Sema/overloadable.c:213:6: error: at most one overload for a given name may lack the \'overloadable\' attribute","clang/test/Sema/overloadable.c:214:6: error: at most one overload for a given name may lack the \'overloadable\' attribute","clang/test/Sema/overloadable.c:236:6: error: at most one overload for a given name may lack the \'overloadable\' attribute","clang/test/Sema/overloadable.c:243:6: error: at most one overload for a given name may lack the \'overloadable\' attribute"} } }, ["err_attribute_overloadable_no_prototype"]={ [c]="err_attribute_overloadable_no_prototype", [d]="\'overloadable\' function %0 must have a prototype", [e]="\'overloadable\' function A must have a prototype", [f]=k, [g]="\'overloadable\' function (.*?) must have a prototype", [h]=a, [i]=m, [b]={N,1236199783,O,P}, [j]={{o,10621,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\n // ...\n if (NewFD->hasAttr<OverloadableAttr>() && !NewFD->getType()->getAs<FunctionProtoType>()) {\n Diag(NewFD->getLocation(), diag::err_attribute_overloadable_no_prototype) << NewFD;"}}, [l]={ ["clang/test/Sema/overloadable.c"]={"clang/test/Sema/overloadable.c:68:42: error: \'overloadable\' function \'f0\' must have a prototype","clang/test/Sema/overloadable.c:70:39: error: \'overloadable\' function \'f1\' must have a prototype","clang/test/Sema/overloadable.c:78:35: error: \'overloadable\' function \'invalid\' must have a prototype"} } }, ["err_attribute_parameter_types"]={ [c]={{nil,x,"err_attribute_parameter_types"}}, [d]={{nil,x,"%0 attribute parameter types do not match: parameter %1 of function %2 has type %3, but parameter %4 of function %5 has type %6"}}, [e]={{nil,x,"A attribute parameter types do not match: parameter B of function C has type D, but parameter E of function F has type G"}}, [f]=k, [g]="(.*?) attribute parameter types do not match\\: parameter (.*?) of function (.*?) has type (.*?), but parameter (.*?) of function (.*?) has type (.*?)", [h]=a, [i]={{nil,x,m}}, [b]={"f9c3310d32c6",1616787805,"[OPENMP]Fix PR49366: crash on VLAs in task untied regions.","[OPENMP]Fix PR49366: crash on VLAs in task untied regions.\n\nWe need to capture the local variables into a record in task untied\nregions but clang does not support record with VLA data members.\n\nDifferential Revision: https://reviews.llvm.org/D99436"}, [j]={{n,1085,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // ...\n for (unsigned I = 1; I < AL.getNumArgs(); ++I) {\n // ...\n if (T1.getCanonicalType().getUnqualifiedType() != T2.getCanonicalType().getUnqualifiedType()) {\n S.Diag(IndexExpr->getBeginLoc(), diag::err_attribute_parameter_types) << AL << Index << DeclFD << T2 << I << AttrFD << T1;"}}, [l]={ ["clang/test/Sema/attr-diagnose-as-builtin.c"]={"clang/test/Sema/attr-diagnose-as-builtin.c:35:126: error: \'diagnose_as_builtin\' attribute parameter types do not match: parameter 1 of function \'failure_parameter_types\' has type \'double\', but parameter 1 of function \'__builtin_memcpy\' has type \'void *\'","clang/test/Sema/attr-diagnose-as-builtin.c:66:107: error: \'diagnose_as_builtin\' attribute parameter types do not match: parameter 2 of function \'failure_type\' has type \'char\', but parameter 2 of function \'__builtin_memset\' has type \'int\'"} } } };