Bots, Bureaucrats, Interface administrators, smwadministrator, smwcurator, smweditor, Administrators
2,557
edits
Timo.stripf (talk | contribs) No edit summary |
Timo.stripf (talk | contribs) No edit summary |
||
Line 1: | Line 1: | ||
local a=""; | local a=""; | ||
local b=" | local b="regex1"; | ||
local c=" | local c="regex3"; | ||
local d=" | local d="prefix"; | ||
local e=" | local e="title"; | ||
local f=" | local f="type"; | ||
local g=" | local g="commit"; | ||
local h=" | local h="message"; | ||
local i=" | local i="category"; | ||
local j=" | local j="regex2"; | ||
local k="source"; | local k="source"; | ||
local l=" | local l="error: "; | ||
local m="Error"; | local m="Error"; | ||
local n="error: "; | local n="(?:error|fatal error)\\: "; | ||
local o="tests2"; | local o="tests2"; | ||
local p="Semantic Issue"; | local p="Semantic Issue"; | ||
local q="clang/lib/Sema/SemaDeclAttr.cpp"; | local q="clang/lib/Sema/SemaDeclAttr.cpp"; | ||
local r="clang/lib/Sema/SemaDecl.cpp"; | local r="Update tablegen diagnostic files to be in sync with the def files."; | ||
local | local s="clang/lib/Sema/SemaDecl.cpp"; | ||
local | local t="clang/lib/Sema/SemaType.cpp"; | ||
local u="clang/lib/Sema/SemaChecking.cpp"; | |||
local v="5a8987ca5113"; | local v="5a8987ca5113"; | ||
local w="clang/lib/Sema/SemaDeclCXX.cpp"; | local w="clang/lib/Sema/SemaDeclCXX.cpp"; | ||
local x="clang/lib/Sema/SemaCast.cpp"; | local x="clang/lib/Sema/SemaCast.cpp"; | ||
local y="clang/lib/Sema/SemaExprCXX.cpp"; | local y="clang/lib/Sema/SemaExprCXX.cpp"; | ||
local z="clang/lib/Sema/SemaExpr.cpp"; | local z="Automatic Reference Counting."; | ||
local | local A="clang/lib/Sema/SemaExpr.cpp"; | ||
local | local B="Implement P2361 Unevaluated string literals"; | ||
local | local C="The basic representation of diagnostics information in tablegen format, plus (uncommented and incomplete) test conversions of the existing def files to this format."; | ||
local | local D="Parse Issue"; | ||
local | local E="b1c4d5507fad"; | ||
local | local F="The basic representation of diagnostics information in tablegen format, plus (uncommented and incomp..."; | ||
local | local G="Inline Assembly Issue"; | ||
local | local H="clang/lib/Parse/ParseDecl.cpp"; | ||
local | local I="[clang] Implement objc_non_runtime_protocol to remove protocol metadata"; | ||
local | local J="clang/lib/Sema/SemaStmtAsm.cpp"; | ||
local | local K="[WebAssembly] Improve clang diagnostics for wasm attributes"; | ||
local | local L="clang/lib/Sema/SemaInit.cpp"; | ||
local | local M="clang/lib/Sema/SemaExprObjC.cpp"; | ||
local | local N="31168b077c36"; | ||
local | local O="clang/lib/Sema/SemaDeclObjC.cpp"; | ||
local | local P="clang/lib/Parse/ParseDeclCXX.cpp"; | ||
local | local Q="ARC Semantic Issue"; | ||
local | local R="95f50964fbf5"; | ||
local | local S="[OPENMP]Fix PR49366: crash on VLAs in task untied regions."; | ||
local | local T="Let clang atomic builtins fetch add/sub support floating point types"; | ||
local | local U="constexpr: semantic checking for constexpr functions and constructors. Based in"; | ||
local | local V="clang/lib/Frontend/CompilerInvocation.cpp"; | ||
local | local W="clang/test/Sema/asm.c"; | ||
local | local X="Implement most of N3638 (return type deduction for normal functions)."; | ||
local | local Y="clang/lib/Sema/SemaObjCProperty.cpp"; | ||
local | local Z="Emit !callback metadata and introduce the callback attribute"; | ||
local | local ab="clang/lib/Sema/SemaOverload.cpp"; | ||
local | local bb="clang/lib/Sema/SemaStmt.cpp"; | ||
local | local cb="14f6bfcb52e7"; | ||
local | local db="Perform access control for the implicit base and member destructor calls"; | ||
local | local eb="clang/lib/Sema/SemaAccess.cpp"; | ||
local | local fb="Implement the C++0x deduced \'auto\' feature."; | ||
local | local gb="Mass-rename the handful of error_* diagnostics to err_*."; | ||
local | local hb="AMDGPU: Teach toolchain to link rocm device libs"; | ||
local | local ib="931fcd3ba011"; | ||
local | local jb="[ObjC] Implement @available in the Parser and AST"; | ||
local | local kb="clang/lib/ARCMigrate/TransProperties.cpp"; | ||
local | local lb="Reland [clang] Check unsupported types in expressions"; | ||
local | local mb="Rename objc_lifetime -> objc_ownership, and modify diagnostics to talk about \'ownership\', not \'lifet..."; | ||
local | local nb="Rename objc_lifetime -> objc_ownership, and modify diagnostics to talk about \'ownership\', not \'lifetime\'."; | ||
local | local ob="cff00d9c127c"; | ||
local | local pb="C1X: implement generic selections"; | ||
local | local qb="clang/lib/ARCMigrate/TransUnbridgedCasts.cpp"; | ||
local | local rb="Lexical or Preprocessor Issue"; | ||
local | local sb="61d065e21ff3"; | ||
local | local tb="[clang] New __attribute__((__clang_arm_mve_alias))."; | ||
local | local ub="Implement VectorType conditional operator GNU extension."; | ||
local | local vb="eb3c10c248ac"; | ||
local | local wb="Implement a new \'availability\' attribute, that allows one to specify"; | ||
local | local xb="[C++20][Modules] Adjust handling of exports of namespaces and using-decls."; | ||
local | local yb="f9c3310d32c6"; | ||
local | local zb="ARC Restrictions"; | ||
local | local Ab="clang/test/SemaCXX/dynamic-cast.cpp"; | ||
local | local Bb="ac991bbb4456"; | ||
local | local Cb="clang/test/SemaObjC/arc.m"; | ||
local | local Db="2a7d481faf54"; | ||
local | local Eb="clang/lib/AST/Stmt.cpp"; | ||
local | local Fb="clang/lib/Sema/SemaLambda.cpp"; | ||
local | local Gb="clang/lib/Parse/ParseExpr.cpp"; | ||
local | local Hb="clang/test/Sema/builtins.c"; | ||
local | local Ib="1064d7ef2992"; | ||
local Jb="[AMDGPU] Add options -mamdgpu-ieee -mno-amdgpu-ieee"; | |||
local | local Kb="clang/test/Sema/attr-callback-broken.c"; | ||
local | local Lb="[clang,ARM] Initial ACLE intrinsics for MVE."; | ||
local | local Mb="Implement C++ DR299, which allows an implicit conversion from a class"; | ||
local | local Nb="30482bc78659"; | ||
local | local Ob="reimplement __sync_* builtins to be variadic and to follow the same"; | ||
local | local Pb="Lambdas: semantic analysis of explicit captures."; | ||
local | local Qb="[Concepts] Concept definitions (D40381)"; | ||
local Rb="[clang] Add no_builtin attribute"; | |||
local | local Sb="Add the `pass_object_size` attribute to clang."; | ||
local | local Tb="clang/lib/Lex/Lexer.cpp"; | ||
local Ub="Better diagnostics for string initialization."; | |||
local Vb="clang/test/Parser/cxx2a-concept-declaration.cpp"; | |||
local Wb="4593e4131aff"; | |||
local Xb="f881267db9a9"; | |||
local Yb="Support warn_unused_result on typedefs"; | |||
local Zb="clang/test/SemaCXX/conversion-function.cpp"; | |||
local ac="Improve handling of vector casts in C++."; | |||
local bc="[C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths."; | |||
local cc="Serialization: Merge three diagnostics to simplify ASTReader::getInputFile, NFC"; | |||
local dc="clang/lib/Sema/SemaTemplateDeduction.cpp"; | |||
local ec="ARC Weak References"; | |||
local fc="clang/lib/Lex/Pragma.cpp"; | |||
local gc="clang/lib/Parse/ParseTemplate.cpp"; | |||
local hc="3dbcea8b957a"; | |||
local ic="29099ded0c15"; | |||
local jc="fatal error\\: "; | |||
local kc="fatal error: "; | |||
local lc="clang/lib/Parse/Parser.cpp"; | |||
local mc="Fatal"; | |||
local nc="clang/lib/Sema/SemaTemplate.cpp"; | |||
local oc="clang/test/ARCMT/checking.m"; | |||
return { | return { | ||
["backslash_newline_space"]={ | ["backslash_newline_space"]={ | ||
[ | [e]="backslash and newline separated by space [-Wbackslash-newline-escape]", | ||
[ | [d]="warning: ", | ||
[ | [f]="Warning", | ||
["groups"]={"backslash-newline-escape"}, | ["groups"]={"backslash-newline-escape"}, | ||
["maingroup"]="backslash-newline-escape", | ["maingroup"]="backslash-newline-escape", | ||
[ | [h]="backslash and newline separated by space", | ||
[ | [b]="(?:warning|error|fatal error)\\: ", | ||
[ | [j]="backslash and newline separated by space", | ||
[ | [c]=" \\[(?:\\-Werror,)?\\-Wbackslash\\-newline\\-escape[^\\]]*\\]", | ||
[ | [i]=rb, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{Tb,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 Slash:\n // See if we have optional whitespace characters between the slash and\n // newline.\n if (unsigned EscapedNewLineSize = getEscapedNewLineSize(Ptr)) {\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);"},{Tb,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 while (true) {\n if (C != 0) {\n // If there was space between the backslash and newline, warn about it.\n if (HasSpace && !isLexingRawMode())\n Diag(EscapePtr, diag::backslash_newline_space);"},{Tb,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 // 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);"}}, | ||
[o]={ | [o]={ | ||
["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]"} | ["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]"} | ||
Line 118: | Line 138: | ||
}, | }, | ||
["err_32_bit_builtin_64_bit_tgt"]={ | ["err_32_bit_builtin_64_bit_tgt"]={ | ||
[e]="this builtin is only available on 32-bit targets", | |||
[d]=l, | |||
[f]=m, | |||
[h]="this builtin is only available on 32-bit targets", | [h]="this builtin is only available on 32-bit targets", | ||
[ | [b]=n, | ||
[ | [j]="this builtin is only available on 32\\-bit targets", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"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."}, | |||
[ | [k]={{u,5982,"bool Sema::CheckX86BuiltinFunctionCall(const TargetInfo &TI, unsigned BuiltinID, CallExpr *TheCall) {\n if (TT.getArch() != llvm::Triple::x86 && isX86_32Builtin(BuiltinID))\n return Diag(TheCall->getCallee()->getBeginLoc(), diag::err_32_bit_builtin_64_bit_tgt);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 133: | Line 153: | ||
}, | }, | ||
["err_64_bit_builtin_32_bit_tgt"]={ | ["err_64_bit_builtin_32_bit_tgt"]={ | ||
[e]="this builtin is only available on 64-bit targets", | |||
[d]=l, | |||
[f]=m, | |||
[h]="this builtin is only available on 64-bit targets", | [h]="this builtin is only available on 64-bit targets", | ||
[ | [b]=n, | ||
[ | [j]="this builtin is only available on 64\\-bit targets", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"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"}, | |||
[ | [k]={{u,4249,"bool Sema::CheckPPCBuiltinFunctionCall(const TargetInfo &TI, unsigned BuiltinID, CallExpr *TheCall) {\n if (isPPC_64Builtin(BuiltinID) && !IsTarget64Bit)\n return Diag(TheCall->getBeginLoc(), diag::err_64_bit_builtin_32_bit_tgt) << TheCall->getSourceRange();"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 148: | Line 168: | ||
}, | }, | ||
["err__Pragma_malformed"]={ | ["err__Pragma_malformed"]={ | ||
[e]="_Pragma takes a parenthesized string literal", | |||
[d]=l, | |||
[f]=m, | |||
[h]="_Pragma takes a parenthesized string literal", | [h]="_Pragma takes a parenthesized string literal", | ||
[ | [b]=n, | ||
[ | [j]="_Pragma takes a parenthesized string literal", | ||
[c]=a, | |||
[ | [i]=rb, | ||
[g]={E,1236199783,F,C}, | |||
[ | [k]={{fc,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 if (Tok.isNot(tok::l_paren)) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"},{fc,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 if (!tok::isStringLiteral(Tok.getKind())) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"},{fc,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 if (Tok.isNot(tok::r_paren)) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"},{fc,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 if (Invalid) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"},{fc,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 if (Tok.isNot(tok::l_paren)) {\n Diag(PragmaLoc, diag::err__Pragma_malformed);"}}, | ||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 163: | Line 183: | ||
}, | }, | ||
["err_abi_tag_on_redeclaration"]={ | ["err_abi_tag_on_redeclaration"]={ | ||
[e]="cannot add \'abi_tag\' attribute in a redeclaration", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot add \'abi_tag\' attribute in a redeclaration", | [h]="cannot add \'abi_tag\' attribute in a redeclaration", | ||
[ | [b]=n, | ||
[ | [j]="cannot add \'abi_tag\' attribute in a redeclaration", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"bf17ecf59a9b",1457537453,"[GCC] PR23529 Sema part of attrbute abi_tag support","[GCC] PR23529 Sema part of attrbute abi_tag support"}, | |||
[k]={{s,3263,"/// mergeDeclAttributes - Copy attributes from the Old decl to the New one.\nvoid Sema::mergeDeclAttributes(NamedDecl *New, Decl *Old, AvailabilityMergeKind AMK) {\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 } else {\n Diag(NewAbiTagAttr->getLocation(), diag::err_abi_tag_on_redeclaration);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 178: | Line 198: | ||
}, | }, | ||
["err_abstract_type_in_decl"]={ | ["err_abstract_type_in_decl"]={ | ||
[ | [e]="... type A is an abstract class", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{return|parameter|variable|field|instance variable|synthesized instance variable}0 type %1 is an abstract class", | ||
[ | [b]=n, | ||
[ | [j]="(?:return|parameter|variable|field|instance variable|synthesized instance variable) type (.*?) is an abstract class", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"576cc6f725a8",1237753097,"Disallow abstract types where appropriate.","Disallow abstract types where appropriate."}, | ||
[k]={{ | [k]={{u,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 for (ParmVarDecl *Param : Parameters) {\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))) {"},{s,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 if (!VDecl->getType()->isDependentType()) {\n if (RequireNonAbstractType(VDecl->getLocation(), VDecl->getType(), diag::err_abstract_type_in_decl, AbstractVariableType))"},{s,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 if (RequireNonAbstractType(VD->getLocation(), Ty, diag::err_abstract_type_in_decl, AbstractVariableType)) {"},{s,13776,"void Sema::ActOnUninitializedDecl(Decl *RealDecl) {\n if (VarDecl *Var = dyn_cast<VarDecl>(RealDecl)) {\n case VarDecl::DeclarationOnly:\n if (!Type->isDependentType() && !Var->isInvalidDecl() && RequireNonAbstractType(Var->getLocation(), Type, diag::err_abstract_type_in_decl, AbstractVariableType))"},{s,13868,"void Sema::ActOnUninitializedDecl(Decl *RealDecl) {\n if (VarDecl *Var = dyn_cast<VarDecl>(RealDecl)) {\n if (RequireNonAbstractType(Var->getLocation(), Type, diag::err_abstract_type_in_decl, AbstractVariableType)) {"},{s,15350,"Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D, SkipBodyInfo *SkipBody, FnBodyKind BodyKind) {\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)))"},{s,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 if (!InvalidDecl && RequireNonAbstractType(Loc, T, diag::err_abstract_type_in_decl, AbstractFieldType))"},{s,18876,"void Sema::ActOnFields(Scope *S, SourceLocation RecLoc, Decl *EnclosingDecl, ArrayRef<Decl *> Fields, SourceLocation LBrac, SourceLocation RBrac, const ParsedAttributesView &Attrs) {\n for (ArrayRef<Decl *>::iterator i = Fields.begin(), end = Fields.end(); i != end; ++i) {\n if (FDTy->isFunctionType()) {\n } else if (FDTy->isIncompleteArrayType() && (Record || isa<ObjCContainerDecl>(EnclosingDecl))) {\n } else if (!FDTy->isDependentType() && RequireCompleteSizedType(FD->getLocation(), FD->getType(), diag::err_field_incomplete_or_sizeless)) {\n } else if (const RecordType *FDTTy = FDTy->getAs<RecordType>()) {\n if (isa<ObjCContainerDecl>(EnclosingDecl) && RequireNonAbstractType(FD->getLocation(), FD->getType(), diag::err_abstract_type_in_decl, AbstractIvarType)) {"},{w,6098,"#include \"clang/AST/TypeLocNodes.def\"\n CheckPolymorphic(PointerTypeLoc) CheckPolymorphic(ReferenceTypeLoc) CheckPolymorphic(MemberPointerTypeLoc) CheckPolymorphic(BlockPointerTypeLoc) CheckPolymorphic(AtomicTypeLoc)\n // It matched; do some magic.\n // FIXME: These should be at most warnings. See P0929R2, CWG1640, CWG1646.\n if (Sel == Sema::AbstractArrayType) {\n } else {\n Info.S.Diag(Ctx->getLocation(), diag::err_abstract_type_in_decl) << Sel << T << TL.getSourceRange();"},{w,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 if (!Invalid && !ExDeclType->isDependentType() && RequireNonAbstractType(Loc, ExDeclType, diag::err_abstract_type_in_decl, AbstractVariableType))"},{Y,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 // Check that we have a valid, previously declared ivar for @synthesize\n if (Synthesize) {\n if (!Ivar) {\n if (RequireNonAbstractType(PropertyIvarLoc, PropertyIvarType, diag::err_abstract_type_in_decl, AbstractSynthesizedIvarType)) {"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 193: | Line 213: | ||
}, | }, | ||
["err_access"]={ | ["err_access"]={ | ||
[ | [e]="A is a ... member of B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%1 is a %select{private|protected}0 member of %3", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) is a (?:private|protected) member of (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Ib,1268716967,db,db}, | ||
[k]={{ | [k]={{eb,1568,"Sema::AccessResult Sema::CheckUnresolvedLookupAccess(UnresolvedLookupExpr *E, DeclAccessPair Found) {\n Entity.setDiag(diag::err_access) << E->getSourceRange();"},{eb,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 Entity.setDiag(diag::err_access) << E->getSourceRange();"},{eb,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 if (Diagnose)\n Entity.setDiag(diag::err_access) << PlacementRange;"},{eb,1790,"Sema::AccessResult Sema::CheckMemberOperatorAccess(SourceLocation OpLoc, Expr *ObjectExpr, const SourceRange &Range, DeclAccessPair Found) {\n Entity.setDiag(diag::err_access) << ObjectExpr->getSourceRange() << Range;"},{eb,1863,"Sema::AccessResult Sema::CheckAddressOfMemberAccess(Expr *OvlExpr, DeclAccessPair Found) {\n Entity.setDiag(diag::err_access) << Ovl->getSourceRange();"},{eb,1920,"/// Checks access to all the declarations in the given result set.\nvoid Sema::CheckLookupAccess(const LookupResult &R) {\n for (LookupResult::iterator I = R.begin(), E = R.end(); I != E; ++I) {\n if (I.getAccess() != AS_public) {\n Entity.setDiag(diag::err_access);"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 208: | Line 228: | ||
}, | }, | ||
["err_access_base_ctor"]={ | ["err_access_base_ctor"]={ | ||
[ | [e]="... A has ... ...constructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{base class|inherited virtual base class}0 %1 has %select{private|protected}3 %select{default |copy |move |*ERROR* |*ERROR* |*ERROR*|}2constructor", | ||
[ | [b]=n, | ||
[ | [j]="(?:base class|inherited virtual base class) (.*?) has (?:private|protected) (?:default |copy |move |)constructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"80f00ff95d3b",1305054494,"Re-do R131114 without breaking code.","Re-do R131114 without breaking code."}, | ||
[k]={{ | [k]={{eb,1660,"/// Checks access to a constructor.\nSema::AccessResult Sema::CheckConstructorAccess(SourceLocation UseLoc, CXXConstructorDecl *Constructor, DeclAccessPair Found, const InitializedEntity &Entity, bool IsCopyBindingRefToTemp) {\n case InitializedEntity::EK_Base:\n PD = PDiag(diag::err_access_base_ctor);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 223: | Line 243: | ||
}, | }, | ||
["err_access_ctor"]={ | ["err_access_ctor"]={ | ||
[ | [e]="calling a ... constructor of class A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="calling a %select{private|protected}0 constructor of class %2", | ||
[ | [b]=n, | ||
[ | [j]="calling a (?:private|protected) constructor of class (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Ib,1268716967,db,db}, | ||
[k]={{ | [k]={{eb,1655,"/// Checks access to a constructor.\nSema::AccessResult Sema::CheckConstructorAccess(SourceLocation UseLoc, CXXConstructorDecl *Constructor, DeclAccessPair Found, const InitializedEntity &Entity, bool IsCopyBindingRefToTemp) {\n default:\n PD = PDiag(IsCopyBindingRefToTemp ? diag::ext_rvalue_to_reference_access_ctor : diag::err_access_ctor);"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 238: | Line 258: | ||
}, | }, | ||
["err_access_decl"]={ | ["err_access_decl"]={ | ||
[e]="ISO C++11 does not allow access declarations; use using declarations instead", | |||
[d]=l, | |||
[f]=m, | |||
[h]="ISO C++11 does not allow access declarations; use using declarations instead", | [h]="ISO C++11 does not allow access declarations; use using declarations instead", | ||
[ | [b]=n, | ||
[ | [j]="ISO C\\+\\+11 does not allow access declarations; use using declarations instead", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"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"}, | |||
[ | |||
[ | |||
[ | |||
[k]={{w,12068,"Decl *Sema::ActOnUsingDeclaration(Scope *S, AccessSpecifier AS, SourceLocation UsingLoc, SourceLocation TypenameLoc, CXXScopeSpec &SS, UnqualifiedId &Name, SourceLocation EllipsisLoc, const ParsedAttributesView &AttrList) {\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 \");"}}, | [k]={{w,12068,"Decl *Sema::ActOnUsingDeclaration(Scope *S, AccessSpecifier AS, SourceLocation UsingLoc, SourceLocation TypenameLoc, CXXScopeSpec &SS, UnqualifiedId &Name, SourceLocation EllipsisLoc, const ParsedAttributesView &AttrList) {\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 \");"}}, | ||
[o]={ | [o]={ | ||
Line 253: | Line 273: | ||
}, | }, | ||
["err_access_dtor"]={ | ["err_access_dtor"]={ | ||
[ | [e]="calling a ... destructor of class A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="calling a %select{private|protected}1 destructor of class %0", | ||
[ | [b]=n, | ||
[ | [j]="calling a (?:private|protected) destructor of class (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"fa7781384ebb",1296575411,"Implement access checking for the \"delete\" operator. Fixes PR9050,","Implement access checking for the \"delete\" operator. Fixes PR9050,"}, | ||
[k]={{y,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 if (!Ex.get()->isTypeDependent()) {\n if (PointeeRD) {\n if (CXXDestructorDecl *Dtor = LookupDestructor(PointeeRD)) {\n CheckDestructorAccess(Ex.get()->getExprLoc(), Dtor, PDiag(diag::err_access_dtor) << PointeeElem);"}}, | [k]={{y,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 if (!Ex.get()->isTypeDependent()) {\n if (PointeeRD) {\n if (CXXDestructorDecl *Dtor = LookupDestructor(PointeeRD)) {\n CheckDestructorAccess(Ex.get()->getExprLoc(), Dtor, PDiag(diag::err_access_dtor) << PointeeElem);"}}, | ||
[o]={ | [o]={ | ||
Line 268: | Line 288: | ||
}, | }, | ||
["err_access_dtor_base"]={ | ["err_access_dtor_base"]={ | ||
[ | [e]="base class A has ... destructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="base class %0 has %select{private|protected}1 destructor", | ||
[ | [b]=n, | ||
[ | [j]="base class (.*?) has (?:private|protected) destructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Ib,1268716967,db,db}, | ||
[k]={{w,5847,"void Sema::MarkBaseAndMemberDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl) {\n // Bases.\n for (const auto &Base : ClassDecl->bases()) {\n CheckDestructorAccess(Base.getBeginLoc(), Dtor, PDiag(diag::err_access_dtor_base) << Base.getType() << Base.getSourceRange(), Context.getTypeDeclType(ClassDecl));"}}, | [k]={{w,5847,"void Sema::MarkBaseAndMemberDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl) {\n // Bases.\n for (const auto &Base : ClassDecl->bases()) {\n CheckDestructorAccess(Base.getBeginLoc(), Dtor, PDiag(diag::err_access_dtor_base) << Base.getType() << Base.getSourceRange(), Context.getTypeDeclType(ClassDecl));"}}, | ||
[o]={ | [o]={ | ||
Line 283: | Line 303: | ||
}, | }, | ||
["err_access_dtor_exception"]={ | ["err_access_dtor_exception"]={ | ||
[ | [e]="exception object of type A has ... destructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="exception object of type %0 has %select{private|protected}1 destructor", | ||
[ | [b]=n, | ||
[ | [j]="exception object of type (.*?) has (?:private|protected) destructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"442612c2853f",1278542113,"Do not use CXXZeroValueInitExpr for class types. Instead, use","Do not use CXXZeroValueInitExpr for class types. Instead, use"}, | ||
[k]={{y,1033,"/// CheckCXXThrowOperand - Validate the operand of a throw.\nbool Sema::CheckCXXThrowOperand(SourceLocation ThrowLoc, QualType ExceptionObjectTy, Expr *E) {\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 CheckDestructorAccess(E->getExprLoc(), Destructor, PDiag(diag::err_access_dtor_exception) << Ty);"}}, | [k]={{y,1033,"/// CheckCXXThrowOperand - Validate the operand of a throw.\nbool Sema::CheckCXXThrowOperand(SourceLocation ThrowLoc, QualType ExceptionObjectTy, Expr *E) {\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 CheckDestructorAccess(E->getExprLoc(), Destructor, PDiag(diag::err_access_dtor_exception) << Ty);"}}, | ||
[o]={ | [o]={ | ||
Line 298: | Line 318: | ||
}, | }, | ||
["err_access_dtor_field"]={ | ["err_access_dtor_field"]={ | ||
[ | [e]="field of type A has ... destructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="field of type %1 has %select{private|protected}2 destructor", | ||
[ | [b]=n, | ||
[ | [j]="field of type (.*?) has (?:private|protected) destructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Ib,1268716967,db,db}, | ||
[k]={{w,5797,"void Sema::MarkBaseAndMemberDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl) {\n // Non-static data members.\n for (auto *Field : ClassDecl->fields()) {\n CheckDestructorAccess(Field->getLocation(), Dtor, PDiag(diag::err_access_dtor_field) << Field->getDeclName() << FieldType);"}}, | [k]={{w,5797,"void Sema::MarkBaseAndMemberDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl) {\n // Non-static data members.\n for (auto *Field : ClassDecl->fields()) {\n CheckDestructorAccess(Field->getLocation(), Dtor, PDiag(diag::err_access_dtor_field) << Field->getDeclName() << FieldType);"}}, | ||
[o]={ | [o]={ | ||
Line 313: | Line 333: | ||
}, | }, | ||
["err_access_dtor_ivar"]={ | ["err_access_dtor_ivar"]={ | ||
[ | [e]="instance variable of type A has ... destructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="instance variable of type %0 has %select{private|protected}1 destructor", | ||
[ | [b]=n, | ||
[ | [j]="instance variable of type (.*?) has (?:private|protected) destructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"527786ea3a6a",1274322262,"Various small fixes for construction/destruction of Objective-C++","Various small fixes for construction/destruction of Objective-C++"}, | ||
[k]={{w,18491,"/// SetIvarInitializers - This routine builds initialization ASTs for the\n/// Objective-C implementation whose ivars need be initialized.\nvoid Sema::SetIvarInitializers(ObjCImplementationDecl *ObjCImplementation) {\n if (ObjCInterfaceDecl *OID = ObjCImplementation->getClassInterface()) {\n for (unsigned i = 0; i < ivars.size(); i++) {\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 if (CXXDestructorDecl *Destructor = LookupDestructor(RD)) {\n CheckDestructorAccess(Field->getLocation(), Destructor, PDiag(diag::err_access_dtor_ivar) << Context.getBaseElementType(Field->getType()));"}}, | [k]={{w,18491,"/// SetIvarInitializers - This routine builds initialization ASTs for the\n/// Objective-C implementation whose ivars need be initialized.\nvoid Sema::SetIvarInitializers(ObjCImplementationDecl *ObjCImplementation) {\n if (ObjCInterfaceDecl *OID = ObjCImplementation->getClassInterface()) {\n for (unsigned i = 0; i < ivars.size(); i++) {\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 if (CXXDestructorDecl *Destructor = LookupDestructor(RD)) {\n CheckDestructorAccess(Field->getLocation(), Destructor, PDiag(diag::err_access_dtor_ivar) << Context.getBaseElementType(Field->getType()));"}}, | ||
[o]={ | [o]={ | ||
Line 328: | Line 348: | ||
}, | }, | ||
["err_access_dtor_temp"]={ | ["err_access_dtor_temp"]={ | ||
[ | [e]="temporary of type A has ... destructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="temporary of type %0 has %select{private|protected}1 destructor", | ||
[ | [b]=n, | ||
[ | [j]="temporary of type (.*?) has (?:private|protected) destructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{y,7334,"ExprResult Sema::MaybeBindToTemporary(Expr *E) {\n if (Destructor) {\n CheckDestructorAccess(E->getExprLoc(), Destructor, PDiag(diag::err_access_dtor_temp) << E->getType());"},{y,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 // 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 CheckDestructorAccess(Bind->getExprLoc(), Destructor, PDiag(diag::err_access_dtor_temp) << Bind->getType());"},{ | [k]={{y,7334,"ExprResult Sema::MaybeBindToTemporary(Expr *E) {\n if (Destructor) {\n CheckDestructorAccess(E->getExprLoc(), Destructor, PDiag(diag::err_access_dtor_temp) << E->getType());"},{y,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 // 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 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 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 for (step_iterator Step = step_begin(), StepEnd = step_end(); Step != StepEnd; ++Step) {\n case SK_UserConversion: {\n if (shouldBindAsTemporary(Entity))\n else if (CreatedObject && shouldDestroyEntity(Entity)) {\n if (const RecordType *Record = T->getAs<RecordType>()) {\n S.CheckDestructorAccess(CurInit.get()->getBeginLoc(), Destructor, S.PDiag(diag::err_access_dtor_temp) << T);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 343: | Line 363: | ||
}, | }, | ||
["err_access_dtor_var"]={ | ["err_access_dtor_var"]={ | ||
[ | [e]="variable of type A has ... destructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="variable of type %1 has %select{private|protected}2 destructor", | ||
[ | [b]=n, | ||
[ | [j]="variable of type (.*?) has (?:private|protected) destructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Ib,1268716967,db,db}, | ||
[k]={{w,15869,"void Sema::FinalizeVarWithDestructor(VarDecl *VD, const RecordType *Record) {\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 CheckDestructorAccess(VD->getLocation(), Destructor, PDiag(diag::err_access_dtor_var) << VD->getDeclName() << VD->getType());"}}, | [k]={{w,15869,"void Sema::FinalizeVarWithDestructor(VarDecl *VD, const RecordType *Record) {\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 CheckDestructorAccess(VD->getLocation(), Destructor, PDiag(diag::err_access_dtor_var) << VD->getDeclName() << VD->getType());"}}, | ||
[o]={ | [o]={ | ||
Line 358: | Line 378: | ||
}, | }, | ||
["err_access_dtor_vbase"]={ | ["err_access_dtor_vbase"]={ | ||
[ | [e]="inherited virtual base class A has ... destructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="inherited virtual base class %1 has %select{private|protected}2 destructor", | ||
[ | [b]=n, | ||
[ | [j]="inherited virtual base class (.*?) has (?:private|protected) destructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Ib,1268716967,db,db}, | ||
[k]={{w,5885,"void Sema::MarkVirtualBaseDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl, llvm::SmallPtrSetImpl<const RecordType *> *DirectVirtualBases) {\n // Virtual bases.\n for (const auto &VBase : ClassDecl->vbases()) {\n if (CheckDestructorAccess(ClassDecl->getLocation(), Dtor, PDiag(diag::err_access_dtor_vbase) << Context.getTypeDeclType(ClassDecl) << VBase.getType(), Context.getTypeDeclType(ClassDecl)) == AR_accessible) {"},{w,5891,"void Sema::MarkVirtualBaseDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl, llvm::SmallPtrSetImpl<const RecordType *> *DirectVirtualBases) {\n // Virtual bases.\n for (const auto &VBase : ClassDecl->vbases()) {\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);"}}, | [k]={{w,5885,"void Sema::MarkVirtualBaseDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl, llvm::SmallPtrSetImpl<const RecordType *> *DirectVirtualBases) {\n // Virtual bases.\n for (const auto &VBase : ClassDecl->vbases()) {\n if (CheckDestructorAccess(ClassDecl->getLocation(), Dtor, PDiag(diag::err_access_dtor_vbase) << Context.getTypeDeclType(ClassDecl) << VBase.getType(), Context.getTypeDeclType(ClassDecl)) == AR_accessible) {"},{w,5891,"void Sema::MarkVirtualBaseDestructorsReferenced(SourceLocation Location, CXXRecordDecl *ClassDecl, llvm::SmallPtrSetImpl<const RecordType *> *DirectVirtualBases) {\n // Virtual bases.\n for (const auto &VBase : ClassDecl->vbases()) {\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);"}}, | ||
[o]={ | [o]={ | ||
Line 373: | Line 393: | ||
}, | }, | ||
["err_access_field_ctor"]={ | ["err_access_field_ctor"]={ | ||
[ | [e]="field of type A has ... ...constructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="field of type %0 has %select{private|protected}2 %select{default |copy |move |*ERROR* |*ERROR* |*ERROR* |}1constructor", | ||
[ | [b]=n, | ||
[ | [j]="field of type (.*?) has (?:private|protected) (?:default |copy |move |)constructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"80f00ff95d3b",1305054494,"Re-do R131114 without breaking code.","Re-do R131114 without breaking code."}, | ||
[k]={{ | [k]={{eb,1668,"/// Checks access to a constructor.\nSema::AccessResult Sema::CheckConstructorAccess(SourceLocation UseLoc, CXXConstructorDecl *Constructor, DeclAccessPair Found, const InitializedEntity &Entity, bool IsCopyBindingRefToTemp) {\n case InitializedEntity::EK_ParenAggInitMember: {\n PD = PDiag(diag::err_access_field_ctor);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 388: | Line 408: | ||
}, | }, | ||
["err_access_friend_function"]={ | ["err_access_friend_function"]={ | ||
[ | [e]="friend function A is a ... member of B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="friend function %1 is a %select{private|protected}0 member of %3", | ||
[ | [b]=n, | ||
[ | [j]="friend function (.*?) is a (?:private|protected) member of (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"a0a96895501e",1344568535,"Check access to friend declarations. There\'s a number of different","Check access to friend declarations. There\'s a number of different"}, | ||
[k]={{ | [k]={{eb,1836,"/// Checks access to the target of a friend declaration.\nSema::AccessResult Sema::CheckFriendAccess(NamedDecl *target) {\n entity.setDiag(diag::err_access_friend_function) << (method->getQualifier() ? method->getQualifierLoc().getSourceRange() : method->getNameInfo().getSourceRange());"}}, | ||
[o]={ | [o]={ | ||
["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>\'"} | ["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>\'"} | ||
Line 403: | Line 423: | ||
}, | }, | ||
["err_access_lambda_capture"]={ | ["err_access_lambda_capture"]={ | ||
[ | [e]="capture of variable \'A\' as type B calls ... ...constructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="capture of variable \'%0\' as type %1 calls %select{private|protected}3 %select{default |copy |move |*ERROR* |*ERROR* |*ERROR* |}2constructor", | ||
[ | [b]=n, | ||
[ | [j]="capture of variable \'(.*?)\' as type (.*?) calls (?:private|protected) (?:default |copy |move |)constructor", | ||
[ | [c]=a, | ||
[ | [i]="Lambda Issue", | ||
[ | [g]={"19666fb1aa7d",1329325046,"Introduce a new initialization entity for lambda captures, and","Introduce a new initialization entity for lambda captures, and"}, | ||
[k]={{ | [k]={{eb,1675,"/// Checks access to a constructor.\nSema::AccessResult Sema::CheckConstructorAccess(SourceLocation UseLoc, CXXConstructorDecl *Constructor, DeclAccessPair Found, const InitializedEntity &Entity, bool IsCopyBindingRefToTemp) {\n case InitializedEntity::EK_LambdaCapture: {\n PD = PDiag(diag::err_access_lambda_capture);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 418: | Line 438: | ||
}, | }, | ||
["err_access_specifier_interface"]={ | ["err_access_specifier_interface"]={ | ||
[ | [e]="interface types cannot specify \'...\' access", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="interface types cannot specify \'%select{private|protected}0\' access", | ||
[ | [b]=n, | ||
[ | [j]="interface types cannot specify \'(?:private|protected)\' access", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"db632ac004ae",1348558359,"Fix for r163013 regression and further __interface enhancement.","Fix for r163013 regression and further __interface enhancement."}, | ||
[k]={{ | [k]={{P,3403,"Parser::DeclGroupPtrTy Parser::ParseCXXClassMemberDeclarationWithPragmas(AccessSpecifier &AS, ParsedAttributes &AccessAttrs, DeclSpec::TST TagType, Decl *TagDecl) {\n case tok::kw_protected: {\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);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 433: | Line 453: | ||
}, | }, | ||
["err_addr_ovl_ambiguous"]={ | ["err_addr_ovl_ambiguous"]={ | ||
[ | [e]="address of overloaded function A is ambiguous", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address of overloaded function %0 is ambiguous", | ||
[ | [b]=n, | ||
[ | [j]="address of overloaded function (.*?) is ambiguous", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"b257e4fff8a9",1247096032,"Implement the simple form of overload resolution used when taking the","Implement the simple form of overload resolution used when taking the"}, | ||
[k]={{ | [k]={{ab,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 void EliminateAllExceptMostSpecializedTemplate() {\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);"},{ab,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 void ComplainMultipleMatchesFound() const {\n S.Diag(OvlExpr->getBeginLoc(), diag::err_addr_ovl_ambiguous) << OvlExpr->getName() << OvlExpr->getSourceRange();"},{ab,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 for (UnresolvedSetIterator I = ovl->decls_begin(), E = ovl->decls_end(); I != E; ++I) {\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();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 448: | Line 468: | ||
}, | }, | ||
["err_addr_ovl_no_qualifier"]={ | ["err_addr_ovl_no_qualifier"]={ | ||
[ | [e]="cannot form member pointer of type A without \'&\' and class name", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot form member pointer of type %0 without \'&\' and class name", | ||
[ | [b]=n, | ||
[ | [j]="cannot form member pointer of type (.*?) without \'&\' and class name", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"24d189484b44",1282690359,"When trying to resolve the address of an overloaded expression,","When trying to resolve the address of an overloaded expression,"}, | ||
[k]={{ | [k]={{ab,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 void ComplainIsInvalidFormOfPointerToMemberFunction() const {\n S.Diag(OvlExpr->getNameLoc(), diag::err_addr_ovl_no_qualifier) << TargetType << OvlExpr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 463: | Line 483: | ||
}, | }, | ||
["err_addr_ovl_no_viable"]={ | ["err_addr_ovl_no_viable"]={ | ||
[ | [e]="address of overloaded function A does not match required type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address of overloaded function %0 does not match required type %1", | ||
[ | [b]=n, | ||
[ | [j]="address of overloaded function (.*?) does not match required type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"064fdb2fe844",1271286681,"Always diagnose and complain about problems in","Always diagnose and complain about problems in"}, | ||
[k]={{ | [k]={{ab,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 void ComplainNoMatchesFound() const {\n S.Diag(OvlExpr->getBeginLoc(), diag::err_addr_ovl_no_viable) << OvlExpr->getName() << TargetFunctionType << OvlExpr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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)\'"} | ["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)\'"} | ||
Line 478: | Line 498: | ||
}, | }, | ||
["err_addr_ovl_not_func_ptrref"]={ | ["err_addr_ovl_not_func_ptrref"]={ | ||
[ | [e]="address of overloaded function A cannot be converted to type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address of overloaded function %0 cannot be converted to type %1", | ||
[ | [b]=n, | ||
[ | [j]="address of overloaded function (.*?) cannot be converted to type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"064fdb2fe844",1271286681,"Always diagnose and complain about problems in","Always diagnose and complain about problems in"}, | ||
[k]={{ | [k]={{ab,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 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"]={ | ["err_address_of_function_with_pass_object_size_params"]={ | ||
[ | [e]="cannot take address of function A because parameter B has pass_object_size attribute", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot take address of function %0 because parameter %1 has pass_object_size attribute", | ||
[ | [b]=n, | ||
[ | [j]="cannot take address of function (.*?) because parameter (.*?) has pass_object_size attribute", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3e3bb95b6951",1449093488,Sb,Sb}, | ||
[k]={{ | [k]={{ab,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 if (Complain) {\n if (InOverloadResolution)\n else\n S.Diag(Loc, diag::err_address_of_function_with_pass_object_size_params) << FD << ParamNo;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 505: | Line 525: | ||
}, | }, | ||
["err_address_of_label_outside_fn"]={ | ["err_address_of_label_outside_fn"]={ | ||
[e]="use of address-of-label extension outside of a function body", | |||
[d]=l, | |||
[f]=m, | |||
[h]="use of address-of-label extension outside of a function body", | [h]="use of address-of-label extension outside of a function body", | ||
[ | [b]=n, | ||
[ | [j]="use of address\\-of\\-label extension outside of a function body", | ||
[c]=a, | |||
[i]=D, | |||
[g]={"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."}, | |||
[ | [k]={{Gb,1460,"#include \"clang/Basic/TransformTypeTraits.def\"\n case tok::ampamp: { // unary-expression: \'&&\' identifier\n if (getCurScope()->getFnParent() == nullptr)\n return ExprError(Diag(Tok, diag::err_address_of_label_outside_fn));"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 520: | Line 540: | ||
}, | }, | ||
["err_address_space_mismatch_templ_inst"]={ | ["err_address_space_mismatch_templ_inst"]={ | ||
[ | [e]="conflicting address space qualifiers are provided between types A and B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="conflicting address space qualifiers are provided between types %0 and %1", | ||
[ | [b]=n, | ||
[ | [j]="conflicting address space qualifiers are provided between types (.*?) and (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"12e3a8af81da",1544029342,"[OpenCL] Diagnose conflicting address spaces in templates.","[OpenCL] Diagnose conflicting address spaces in templates."}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 534: | Line 554: | ||
}, | }, | ||
["err_address_space_qualified_delete"]={ | ["err_address_space_qualified_delete"]={ | ||
[ | [e]="\'delete\' cannot delete objects of type A in address space \'B\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'delete\' cannot delete objects of type %0 in address space \'%1\'", | ||
[ | [b]=n, | ||
[ | [j]="\'delete\' cannot delete objects of type (.*?) in address space \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{y,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 if (!Ex.get()->isTypeDependent()) {\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();"}}, | [k]={{y,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 if (!Ex.get()->isTypeDependent()) {\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();"}}, | ||
[o]={ | [o]={ | ||
Line 549: | Line 569: | ||
}, | }, | ||
["err_address_space_qualified_new"]={ | ["err_address_space_qualified_new"]={ | ||
[ | [e]="\'new\' cannot allocate objects of type A in address space \'B\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'new\' cannot allocate objects of type %0 in address space \'%1\'", | ||
[ | [b]=n, | ||
[ | [j]="\'new\' cannot allocate objects of type (.*?) in address space \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{y,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 else if (AllocType->isReferenceType())\n else if (!AllocType->isDependentType() && RequireCompleteSizedType(Loc, AllocType, diag::err_new_incomplete_or_sizeless_type, R))\n else if (RequireNonAbstractType(Loc, AllocType, diag::err_allocation_of_abstract_type))\n else if (AllocType->isVariablyModifiedType())\n else if (AllocType.getAddressSpace() != LangAS::Default && !getLangOpts().OpenCLCPlusPlus)\n return Diag(Loc, diag::err_address_space_qualified_new) << AllocType.getUnqualifiedType() << AllocType.getQualifiers().getAddressSpaceAttributePrintValue();"}}, | [k]={{y,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 else if (AllocType->isReferenceType())\n else if (!AllocType->isDependentType() && RequireCompleteSizedType(Loc, AllocType, diag::err_new_incomplete_or_sizeless_type, R))\n else if (RequireNonAbstractType(Loc, AllocType, diag::err_allocation_of_abstract_type))\n else if (AllocType->isVariablyModifiedType())\n else if (AllocType.getAddressSpace() != LangAS::Default && !getLangOpts().OpenCLCPlusPlus)\n return Diag(Loc, diag::err_address_space_qualified_new) << AllocType.getUnqualifiedType() << AllocType.getQualifiers().getAddressSpaceAttributePrintValue();"}}, | ||
[o]={ | [o]={ | ||
Line 564: | Line 584: | ||
}, | }, | ||
["err_addrof_function_constraints_not_satisfied"]={ | ["err_addrof_function_constraints_not_satisfied"]={ | ||
[ | [e]="cannot take address of function A because its constraints are not satisfied", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot take address of function %0 because its constraints are not satisfied", | ||
[ | [b]=n, | ||
[ | [j]="cannot take address of function (.*?) because its constraints are not satisfied", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"349636d2bfc3",1575555459,ub,ub}, | ||
[k]={{ | [k]={{ab,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 if (FD->getTrailingRequiresClause()) {\n if (!Satisfaction.IsSatisfied) {\n if (Complain) {\n if (InOverloadResolution) {\n } else\n S.Diag(Loc, diag::err_addrof_function_constraints_not_satisfied) << FD;"}} | ||
}, | }, | ||
["err_addrof_function_disabled_by_enable_if_attr"]={ | ["err_addrof_function_disabled_by_enable_if_attr"]={ | ||
[ | [e]="cannot take address of function A because it has one or more non-tautological enable_if conditions", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot take address of function %0 because it has one or more non-tautological enable_if conditions", | ||
[ | [b]=n, | ||
[ | [j]="cannot take address of function (.*?) because it has one or more non\\-tautological enable_if conditions", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3e3bb95b6951",1449093488,Sb,Sb}, | ||
[k]={{ | [k]={{ab,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 else\n S.Diag(Loc, diag::err_addrof_function_disabled_by_enable_if_attr) << FD;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 591: | Line 611: | ||
}, | }, | ||
["err_aix_attr_unsupported_tls_model"]={ | ["err_aix_attr_unsupported_tls_model"]={ | ||
[ | [e]="TLS model \'A\' is not yet supported on AIX", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="TLS model \'%0\' is not yet supported on AIX", | ||
[ | [b]=n, | ||
[ | [j]="TLS model \'(.*?)\' is not yet supported on AIX", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={hc,1615397021,lb,lb}, | ||
[k]={{q,2044,"static void handleTLSModelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"}} | [k]={{q,2044,"static void handleTLSModelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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"]={ | ["err_aix_unsupported_tls_model"]={ | ||
[ | [e]="TLS model \'A\' is not yet supported on AIX", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="TLS model \'%0\' is not yet supported on AIX", | ||
[ | [b]=n, | ||
[ | [j]="TLS model \'(.*?)\' is not yet supported on AIX", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"0687578728ea",1610286626,bc,bc}, | ||
[k]={{ | [k]={{V,1892,"#include \"clang/Driver/Options.inc\"\n if (Arg *A = Args.getLastArg(OPT_ftlsmodel_EQ)) {\n if (T.isOSAIX()) {\n if (Name != \"global-dynamic\" && Name != \"local-exec\")\n Diags.Report(diag::err_aix_unsupported_tls_model) << Name;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 618: | Line 638: | ||
}, | }, | ||
["err_alias_after_tentative"]={ | ["err_alias_after_tentative"]={ | ||
[ | [e]="alias definition of A after tentative definition", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="alias definition of %0 after tentative definition", | ||
[ | [b]=n, | ||
[ | [j]="alias definition of (.*?) after tentative definition", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"d53ffa0a70d8",1382477943,"Treat aliases as definitions.","Treat aliases as definitions."}, | ||
[k]={{ | [k]={{s,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 for (unsigned I = 0, E = NewAttributes.size(); I != E;) {\n if (isa<AliasAttr>(NewAttribute) || isa<IFuncAttr>(NewAttribute)) {\n if (FunctionDecl *FD = dyn_cast<FunctionDecl>(New)) {\n } else {\n unsigned Diag = cast<VarDecl>(Def)->isThisDeclarationADefinition() == VarDecl::TentativeDefinition ? diag::err_alias_after_tentative : diag::err_redefinition;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/alias-redefinition.c"]={"clang/test/Sema/alias-redefinition.c:32:12: error: alias definition of \'var4\' after tentative definition"} | ["clang/test/Sema/alias-redefinition.c"]={"clang/test/Sema/alias-redefinition.c:32:12: error: alias definition of \'var4\' after tentative definition"} | ||
Line 633: | Line 653: | ||
}, | }, | ||
["err_alias_declaration_not_identifier"]={ | ["err_alias_declaration_not_identifier"]={ | ||
[e]="name defined in alias declaration must be an identifier", | |||
[d]=l, | |||
[f]=m, | |||
[h]="name defined in alias declaration must be an identifier", | [h]="name defined in alias declaration must be an identifier", | ||
[ | [b]=n, | ||
[ | [j]="name defined in alias declaration must be an identifier", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={"dda56e4b4a9c",1302877477,"Support for C++11 (non-template) alias declarations.","Support for C++11 (non-template) alias declarations."}, | |||
[k]={{P,905,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\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);"},{P,910,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\n // Name must be an identifier.\n if (D.Name.getKind() != UnqualifiedIdKind::IK_Identifier) {\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));"},{P,915,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\n // Name must be an identifier.\n if (D.Name.getKind() != UnqualifiedIdKind::IK_Identifier) {\n } else if (D.TypenameLoc.isValid())\n else if (D.SS.isNotEmpty())\n Diag(D.SS.getBeginLoc(), diag::err_alias_declaration_not_identifier) << FixItHint::CreateRemoval(D.SS.getRange());"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 648: | Line 668: | ||
}, | }, | ||
["err_alias_declaration_pack_expansion"]={ | ["err_alias_declaration_pack_expansion"]={ | ||
[e]="alias declaration cannot be a pack expansion", | |||
[d]=l, | |||
[f]=m, | |||
[h]="alias declaration cannot be a pack expansion", | [h]="alias declaration cannot be a pack expansion", | ||
[ | [b]=n, | ||
[ | [j]="alias declaration cannot be a pack expansion", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={"22a250cd5d8e",1482120533,"[c++1z] P0195R2: Support pack-expansion of using-declarations.","[c++1z] P0195R2: Support pack-expansion of using-declarations."}, | |||
[ | [k]={{P,918,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\n if (D.EllipsisLoc.isValid())\n Diag(D.EllipsisLoc, diag::err_alias_declaration_pack_expansion) << FixItHint::CreateRemoval(SourceRange(D.EllipsisLoc));"}} | ||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_alias_declaration_specialization"]={ | ["err_alias_declaration_specialization"]={ | ||
[ | [e]="... of alias templates is not permitted", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{partial specialization|explicit specialization|explicit instantiation}0 of alias templates is not permitted", | ||
[ | [b]=n, | ||
[ | [j]="(?:partial specialization|explicit specialization|explicit instantiation) of alias templates is not permitted", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"3f1b5d077b7e",1304632627,"Implement support for C++0x alias templates.","Implement support for C++0x alias templates."}, | ||
[k]={{ | [k]={{P,897,"Decl *Parser::ParseAliasDeclarationAfterDeclarator(const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, UsingDeclarator &D, SourceLocation &DeclEnd, AccessSpecifier AS, ParsedAttributes &Attrs, Decl **OwnedType) {\n if (SpecKind != -1) {\n Diag(Range.getBegin(), diag::err_alias_declaration_specialization) << SpecKind << Range;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 675: | Line 695: | ||
}, | }, | ||
["err_alias_is_definition"]={ | ["err_alias_is_definition"]={ | ||
[ | [e]="definition A cannot also be an ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="definition %0 cannot also be an %select{alias|ifunc}1", | ||
[ | [b]=n, | ||
[ | [j]="definition (.*?) cannot also be an (?:alias|ifunc)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"2dc814664385",1421658028,"Sema: Variable definitions cannot be __attribute__((alias))","Sema: Variable definitions cannot be __attribute__((alias))"}, | ||
[k]={{ | [k]={{s,6968,"static void checkAttributesAfterMerging(Sema &S, NamedDecl &ND) {\n if (auto *VD = dyn_cast<VarDecl>(&ND)) {\n if (VD->hasInit()) {\n if (const auto *Attr = VD->getAttr<AliasAttr>()) {\n S.Diag(Attr->getLocation(), diag::err_alias_is_definition) << VD << 0;"},{s,15265,"Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D, SkipBodyInfo *SkipBody, FnBodyKind BodyKind) {\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;"},{s,15270,"Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D, SkipBodyInfo *SkipBody, FnBodyKind BodyKind) {\n if (const auto *Attr = FD->getAttr<IFuncAttr>()) {\n Diag(Attr->getLocation(), diag::err_alias_is_definition) << FD << 1;"},{q,1980,"static void handleIFuncAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (FD->isThisDeclarationADefinition()) {\n S.Diag(AL.getLoc(), diag::err_alias_is_definition) << FD << 1;"},{q,2003,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,2009,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Aliases should be on declarations, not definitions.\n if (const auto *FD = dyn_cast<FunctionDecl>(D)) {\n } else {\n if (VD->isThisDeclarationADefinition() && VD->isExternallyVisible()) {\n S.Diag(AL.getLoc(), diag::err_alias_is_definition) << VD << 0;"},{q,7662,"static void handleWebAssemblyExportNameAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (FD->isThisDeclarationADefinition()) {\n S.Diag(D->getLocation(), diag::err_alias_is_definition) << FD << 0;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 690: | Line 710: | ||
}, | }, | ||
["err_alias_not_supported_on_darwin"]={ | ["err_alias_not_supported_on_darwin"]={ | ||
[e]="aliases are not supported on darwin", | |||
[d]=l, | |||
[f]=m, | |||
[h]="aliases are not supported on darwin", | [h]="aliases are not supported on darwin", | ||
[ | [b]=n, | ||
[ | [j]="aliases are not supported on darwin", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"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."}, | |||
[ | |||
[ | |||
[k]={{q,1993,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (S.Context.getTargetInfo().getTriple().isOSDarwin()) {\n S.Diag(AL.getLoc(), diag::err_alias_not_supported_on_darwin);"}}, | [k]={{q,1993,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (S.Context.getTargetInfo().getTriple().isOSDarwin()) {\n S.Diag(AL.getLoc(), diag::err_alias_not_supported_on_darwin);"}}, | ||
[o]={ | [o]={ | ||
Line 705: | Line 725: | ||
}, | }, | ||
["err_alias_not_supported_on_nvptx"]={ | ["err_alias_not_supported_on_nvptx"]={ | ||
[e]="CUDA does not support aliases", | |||
[d]=l, | |||
[f]=m, | |||
[h]="CUDA does not support aliases", | [h]="CUDA does not support aliases", | ||
[ | [b]=n, | ||
[ | [j]="CUDA does not support aliases", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"a8f0254bc1a4",1453584490,"[CUDA] Reject the alias attribute in CUDA device code.","[CUDA] Reject the alias attribute in CUDA device code."}, | |||
[ | |||
[ | |||
[k]={{q,1997,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (S.Context.getTargetInfo().getTriple().isNVPTX()) {\n S.Diag(AL.getLoc(), diag::err_alias_not_supported_on_nvptx);"}}, | [k]={{q,1997,"static void handleAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (S.Context.getTargetInfo().getTriple().isNVPTX()) {\n S.Diag(AL.getLoc(), diag::err_alias_not_supported_on_nvptx);"}}, | ||
[o]={ | [o]={ | ||
Line 720: | Line 740: | ||
}, | }, | ||
["err_alias_template_extra_headers"]={ | ["err_alias_template_extra_headers"]={ | ||
[e]="extraneous template parameter list in alias template declaration", | |||
[d]=l, | |||
[f]=m, | |||
[h]="extraneous template parameter list in alias template declaration", | [h]="extraneous template parameter list in alias template declaration", | ||
[ | [b]=n, | ||
[ | [j]="extraneous template parameter list in alias template declaration", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"3f1b5d077b7e",1304632627,"Implement support for C++0x alias templates.","Implement support for C++0x alias templates."}, | |||
[ | |||
[ | |||
[k]={{w,13299,"Decl *Sema::ActOnAliasDeclaration(Scope *S, AccessSpecifier AS, MultiTemplateParamsArg TemplateParamLists, SourceLocation UsingLoc, UnqualifiedId &Name, const ParsedAttributesView &AttrList, TypeResult Type, Decl *DeclFromDeclSpec) {\n if (TemplateParamLists.size()) {\n if (TemplateParamLists.size() != 1) {\n Diag(UsingLoc, diag::err_alias_template_extra_headers) << SourceRange(TemplateParamLists[1]->getTemplateLoc(), TemplateParamLists[TemplateParamLists.size() - 1]->getRAngleLoc());"}}, | [k]={{w,13299,"Decl *Sema::ActOnAliasDeclaration(Scope *S, AccessSpecifier AS, MultiTemplateParamsArg TemplateParamLists, SourceLocation UsingLoc, UnqualifiedId &Name, const ParsedAttributesView &AttrList, TypeResult Type, Decl *DeclFromDeclSpec) {\n if (TemplateParamLists.size()) {\n if (TemplateParamLists.size() != 1) {\n Diag(UsingLoc, diag::err_alias_template_extra_headers) << SourceRange(TemplateParamLists[1]->getTemplateLoc(), TemplateParamLists[TemplateParamLists.size() - 1]->getRAngleLoc());"}}, | ||
[o]={ | [o]={ | ||
Line 735: | Line 755: | ||
}, | }, | ||
["err_alias_to_undefined"]={ | ["err_alias_to_undefined"]={ | ||
[ | [e]="... must point to a defined ...function", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{alias|ifunc}0 must point to a defined %select{variable or |}1function", | ||
[ | [b]=n, | ||
[ | [j]="(?:alias|ifunc) must point to a defined (?:variable or |)function", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"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"}, | ||
[k]={{"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 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 if (IsIFunc) {\n if (!F) {\n Diags.Report(Location, diag::err_alias_to_undefined) << IsIFunc << IsIFunc;"}}, | [k]={{"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 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 if (IsIFunc) {\n if (!F) {\n Diags.Report(Location, diag::err_alias_to_undefined) << IsIFunc << IsIFunc;"}}, | ||
[o]={ | [o]={ | ||
Line 750: | Line 770: | ||
}, | }, | ||
["err_align_value_attribute_argument_not_int"]={ | ["err_align_value_attribute_argument_not_int"]={ | ||
[e]="\'align_value\' attribute requires integer constant", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'align_value\' attribute requires integer constant", | [h]="\'align_value\' attribute requires integer constant", | ||
[ | [b]=n, | ||
[ | [j]="\'align_value\' attribute requires integer constant", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"1b0d24e03abf",1412284885,"Initial support for the align_value attribute","Initial support for the align_value attribute"}, | |||
[ | |||
[ | |||
[k]={{q,4331,"void Sema::AddAlignValueAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E) {\n if (!E->isValueDependent()) {\n ExprResult ICE = VerifyIntegerConstantExpression(E, &Alignment, diag::err_align_value_attribute_argument_not_int);"}}, | [k]={{q,4331,"void Sema::AddAlignValueAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E) {\n if (!E->isValueDependent()) {\n ExprResult ICE = VerifyIntegerConstantExpression(E, &Alignment, diag::err_align_value_attribute_argument_not_int);"}}, | ||
[o]={ | [o]={ | ||
Line 765: | Line 785: | ||
}, | }, | ||
["err_alignas_attribute_wrong_decl_type"]={ | ["err_alignas_attribute_wrong_decl_type"]={ | ||
[ | [e]="A attribute cannot be applied to ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%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", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute cannot be applied to (?:a function parameter|a variable with \'register\' storage class|a \'catch\' variable|a bit\\-field|an enumeration)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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."}, | ||
[k]={{q,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 if (DiagKind != -1) {\n return S.Diag(AttrLoc, diag::err_alignas_attribute_wrong_decl_type) << &Attr << DiagKind;"}}, | [k]={{q,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 if (DiagKind != -1) {\n return S.Diag(AttrLoc, diag::err_alignas_attribute_wrong_decl_type) << &Attr << DiagKind;"}}, | ||
[o]={ | [o]={ | ||
Line 780: | Line 800: | ||
}, | }, | ||
["err_alignas_mismatch"]={ | ["err_alignas_mismatch"]={ | ||
[ | [e]="redeclaration has different alignment requirement (A vs B)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="redeclaration has different alignment requirement (%1 vs %0)", | ||
[ | [b]=n, | ||
[ | [j]="redeclaration has different alignment requirement \\((.*?) vs (.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{ | [k]={{s,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 if (OldAlignasAttr && NewAlignasAttr && OldAlign != NewAlign) {\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();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 795: | Line 815: | ||
}, | }, | ||
["err_alignas_missing_on_definition"]={ | ["err_alignas_missing_on_definition"]={ | ||
[ | [e]="A must be specified on definition if it is specified on any declaration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 must be specified on definition if it is specified on any declaration", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) must be specified on definition if it is specified on any declaration", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{ | [k]={{s,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 if (OldAlignasAttr && !NewAlignasAttr && isAttributeTargetADefinition(New)) {\n S.Diag(New->getLocation(), diag::err_alignas_missing_on_definition) << OldAlignasAttr;"},{s,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 for (unsigned I = 0, E = NewAttributes.size(); I != E;) {\n if (isa<C11NoReturnAttr>(NewAttribute)) {\n } else if (isa<UuidAttr>(NewAttribute)) {\n } else if (const AlignedAttr *AA = dyn_cast<AlignedAttr>(NewAttribute)) {\n if (AA->isAlignas()) {\n S.Diag(Def->getLocation(), diag::err_alignas_missing_on_definition) << AA;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 810: | Line 830: | ||
}, | }, | ||
["err_alignas_underaligned"]={ | ["err_alignas_underaligned"]={ | ||
[ | [e]="requested alignment is less than minimum alignment of A for type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="requested alignment is less than minimum alignment of %1 for type %0", | ||
[ | [b]=n, | ||
[ | [j]="requested alignment is less than minimum alignment of (.*?) for type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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."}, | ||
[k]={{q,4616,"void Sema::CheckAlignasUnderalignment(Decl *D) {\n if (Align && DiagTy->isSizelessType()) {\n } else if (AlignasAttr && Align) {\n if (NaturalAlign > RequestedAlign)\n Diag(AlignasAttr->getLocation(), diag::err_alignas_underaligned) << DiagTy << (unsigned)NaturalAlign.getQuantity();"}}, | [k]={{q,4616,"void Sema::CheckAlignasUnderalignment(Decl *D) {\n if (Align && DiagTy->isSizelessType()) {\n } else if (AlignasAttr && Align) {\n if (NaturalAlign > RequestedAlign)\n Diag(AlignasAttr->getLocation(), diag::err_alignas_underaligned) << DiagTy << (unsigned)NaturalAlign.getQuantity();"}}, | ||
[o]={ | [o]={ | ||
Line 825: | Line 845: | ||
}, | }, | ||
["err_aligned_allocation_unavailable"]={ | ["err_aligned_allocation_unavailable"]={ | ||
[ | [e]="aligned ... function of type \'A\' is ... available on B...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="aligned %select{allocation|deallocation}0 function of type \'%1\' is %select{only|not}4 available on %2%select{ %3 or newer|}4", | ||
[ | [b]=n, | ||
[ | [j]="aligned (?:allocation|deallocation) function of type \'(.*?)\' is (?:only|not) available on (.*?)(?: (.*?) or newer|)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e5015abf185b",1533337957,"[Preprocessor] Allow libc++ to detect when aligned allocation is unavailable.","[Preprocessor] Allow libc++ to detect when aligned allocation is unavailable."}, | ||
[k]={{y,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 Diag(Loc, diag::err_aligned_allocation_unavailable) << IsDelete << FD.getType().getAsString() << OSName << OSVersion.getAsString() << OSVersion.empty();"}}, | [k]={{y,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 Diag(Loc, diag::err_aligned_allocation_unavailable) << IsDelete << FD.getType().getAsString() << OSName << OSVersion.getAsString() << OSVersion.empty();"}}, | ||
[o]={ | [o]={ | ||
Line 840: | Line 860: | ||
}, | }, | ||
["err_aligned_attribute_argument_not_int"]={ | ["err_aligned_attribute_argument_not_int"]={ | ||
[e]="\'aligned\' attribute requires integer constant", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'aligned\' attribute requires integer constant", | [h]="\'aligned\' attribute requires integer constant", | ||
[ | [b]=n, | ||
[ | [j]="\'aligned\' attribute requires integer constant", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"e2b3744890f6",1336171132,"Move Sema::VerifyIntegerConstantExpression() and","Move Sema::VerifyIntegerConstantExpression() and"}, | |||
[ | |||
[ | |||
[k]={{q,4473,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\n ExprResult ICE = VerifyIntegerConstantExpression(E, &Alignment, diag::err_aligned_attribute_argument_not_int);"}}, | [k]={{q,4473,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\n ExprResult ICE = VerifyIntegerConstantExpression(E, &Alignment, diag::err_aligned_attribute_argument_not_int);"}}, | ||
[o]={ | [o]={ | ||
Line 855: | Line 875: | ||
}, | }, | ||
["err_alignment_dependent_typedef_name"]={ | ["err_alignment_dependent_typedef_name"]={ | ||
[e]="requested alignment is dependent but declaration is not dependent", | |||
[d]=l, | |||
[f]=m, | |||
[h]="requested alignment is dependent but declaration is not dependent", | [h]="requested alignment is dependent but declaration is not dependent", | ||
[ | [b]=n, | ||
[ | [j]="requested alignment is dependent but declaration is not dependent", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"26a1e0ef760a",1428374229,"[Sema] Don\'t permit dependent alignments on non-dependent typedef-names","[Sema] Don\'t permit dependent alignments on non-dependent typedef-names"}, | |||
[ | |||
[ | |||
[k]={{q,4457,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\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();"},{q,4547,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, TypeSourceInfo *TS, bool IsPackExpansion) {\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();"}}, | [k]={{q,4457,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\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();"},{q,4547,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, TypeSourceInfo *TS, bool IsPackExpansion) {\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();"}}, | ||
[o]={ | [o]={ | ||
Line 870: | Line 890: | ||
}, | }, | ||
["err_alignment_not_power_of_two"]={ | ["err_alignment_not_power_of_two"]={ | ||
[e]="requested alignment is not a power of 2", | |||
[d]=l, | |||
[f]=m, | |||
[h]="requested alignment is not a power of 2", | [h]="requested alignment is not a power of 2", | ||
[ | [b]=n, | ||
[ | [j]="requested alignment is not a power of 2", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"bcc06085a894",1410130694,"Add __builtin_assume and __builtin_assume_aligned using @llvm.assume.","Add __builtin_assume and __builtin_assume_aligned using @llvm.assume."}, | |||
[k]={{u,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 // 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 if (!AlignValue.isPowerOf2()) {\n S.Diag(AlignOp->getExprLoc(), diag::err_alignment_not_power_of_two);"},{u,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 // We can\'t check the value of a dependent argument.\n if (!Arg->isTypeDependent() && !Arg->isValueDependent()) {\n if (!Result.isPowerOf2())\n return Diag(TheCall->getBeginLoc(), diag::err_alignment_not_power_of_two) << Arg->getSourceRange();"},{u,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 // We can\'t check the value of a dependent argument.\n if (!SecondArg->isValueDependent()) {\n if (!Result.isPowerOf2())\n return Diag(TheCall->getBeginLoc(), diag::err_alignment_not_power_of_two) << SecondArg->getSourceRange();"},{q,1711,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n if (!E->isValueDependent()) {\n if (!I->isPowerOf2()) {\n Diag(AttrLoc, diag::err_alignment_not_power_of_two) << E->getSourceRange();"},{q,4336,"void Sema::AddAlignValueAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E) {\n if (!E->isValueDependent()) {\n if (!Alignment.isPowerOf2()) {\n Diag(AttrLoc, diag::err_alignment_not_power_of_two) << E->getSourceRange();"},{q,4494,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\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();"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 885: | Line 905: | ||
}, | }, | ||
["err_alignment_too_big"]={ | ["err_alignment_too_big"]={ | ||
[ | [e]="requested alignment must be A or smaller", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="requested alignment must be %0 or smaller", | ||
[ | [b]=n, | ||
[ | [j]="requested alignment must be (.*?) or smaller", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"5116993f8ea7",1477892268,"Add support for __builtin_alloca_with_align","Add support for __builtin_alloca_with_align"}, | ||
[k]={{ | [k]={{u,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 // 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 if (llvm::APSInt::compareValues(AlignValue, MaxValue) > 0) {\n S.Diag(AlignOp->getExprLoc(), diag::err_alignment_too_big) << toString(MaxValue, 10);"},{u,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 // We can\'t check the value of a dependent argument.\n if (!Arg->isTypeDependent() && !Arg->isValueDependent()) {\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();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 900: | Line 920: | ||
}, | }, | ||
["err_alignment_too_small"]={ | ["err_alignment_too_small"]={ | ||
[ | [e]="requested alignment must be A or greater", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="requested alignment must be %0 or greater", | ||
[ | [b]=n, | ||
[ | [j]="requested alignment must be (.*?) or greater", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"5116993f8ea7",1477892268,"Add support for __builtin_alloca_with_align","Add support for __builtin_alloca_with_align"}, | ||
[k]={{ | [k]={{u,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 // 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 if (AlignValue < 1) {\n S.Diag(AlignOp->getExprLoc(), diag::err_alignment_too_small) << 1;"},{u,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 // We can\'t check the value of a dependent argument.\n if (!Arg->isTypeDependent() && !Arg->isValueDependent()) {\n if (Result < Context.getCharWidth())\n return Diag(TheCall->getBeginLoc(), diag::err_alignment_too_small) << (unsigned)Context.getCharWidth() << Arg->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/builtin-align-cxx.cpp"]={"clang/test/SemaCXX/builtin-align-cxx.cpp:47:64: error: requested alignment must be 1 or greater"} | ["clang/test/SemaCXX/builtin-align-cxx.cpp"]={"clang/test/SemaCXX/builtin-align-cxx.cpp:47:64: error: requested alignment must be 1 or greater"} | ||
Line 915: | Line 935: | ||
}, | }, | ||
["err_alignof_member_of_incomplete_type"]={ | ["err_alignof_member_of_incomplete_type"]={ | ||
[e]="invalid application of \'alignof\' to a field of a class still being defined", | |||
[d]=l, | |||
[f]=m, | |||
[h]="invalid application of \'alignof\' to a field of a class still being defined", | [h]="invalid application of \'alignof\' to a field of a class still being defined", | ||
[ | [b]=n, | ||
[ | [j]="invalid application of \'alignof\' to a field of a class still being defined", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"768439eb2e7e",1367826034,"Require the containing type to be complete when we see","Require the containing type to be complete when we see"}, | |||
[k]={{A,4687,"static bool CheckAlignOfExpr(Sema &S, Expr *E, UnaryExprOrTypeTrait ExprKind) {\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();"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 930: | Line 950: | ||
}, | }, | ||
["err_allocation_of_abstract_type"]={ | ["err_allocation_of_abstract_type"]={ | ||
[ | [e]="allocating an object of abstract class type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="allocating an object of abstract class type %0", | ||
[ | [b]=n, | ||
[ | [j]="allocating an object of abstract class type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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."}, | ||
[k]={{x,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)) {"},{y,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 else if (RequireNonAbstractType(Loc, AllocType, diag::err_allocation_of_abstract_type))"},{y,4120,"static ExprResult BuildCXXCastArgument(Sema &S, SourceLocation CastLoc, QualType Ty, CastKind Kind, CXXMethodDecl *Method, DeclAccessPair FoundDecl, bool HadMultipleCandidates, Expr *From) {\n case CK_ConstructorConversion: {\n if (S.RequireNonAbstractType(CastLoc, Ty, diag::err_allocation_of_abstract_type))"},{ | [k]={{x,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)) {"},{y,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 else if (RequireNonAbstractType(Loc, AllocType, diag::err_allocation_of_abstract_type))"},{y,4120,"static ExprResult BuildCXXCastArgument(Sema &S, SourceLocation CastLoc, QualType Ty, CastKind Kind, CXXMethodDecl *Method, DeclAccessPair FoundDecl, bool HadMultipleCandidates, Expr *From) {\n case CK_ConstructorConversion: {\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 // 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 return S.RequireNonAbstractType(Kind.getLocation(), T, diag::err_allocation_of_abstract_type);"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 945: | Line 965: | ||
}, | }, | ||
["err_altivec_empty_initializer"]={ | ["err_altivec_empty_initializer"]={ | ||
[e]="expected initializer", | |||
[d]=l, | |||
[f]=m, | |||
[h]="expected initializer", | [h]="expected initializer", | ||
[ | [b]=n, | ||
[ | [j]="expected initializer", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"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);"}, | |||
[k]={{A,8445,"ExprResult Sema::ActOnCastExpr(Scope *S, SourceLocation LParenLoc, Declarator &D, ParsedType &Ty, SourceLocation RParenLoc, Expr *CastExpr) {\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);"}} | |||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_ambiguous_base_to_derived_cast"]={ | ["err_ambiguous_base_to_derived_cast"]={ | ||
[ | [e]="ambiguous cast from base A to derived B:C", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="ambiguous cast from base %0 to derived %1:%2", | ||
[ | [b]=n, | ||
[ | [j]="ambiguous cast from base (.*?) to derived (.*?)\\:(.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,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 if (Paths.isAmbiguous(SrcType.getUnqualifiedType())) {\n Self.Diag(OpRange.getBegin(), diag::err_ambiguous_base_to_derived_cast) << QualType(SrcType).getUnqualifiedType() << QualType(DestType).getUnqualifiedType() << PathDisplayStr << OpRange;"}}, | [k]={{x,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 if (Paths.isAmbiguous(SrcType.getUnqualifiedType())) {\n Self.Diag(OpRange.getBegin(), diag::err_ambiguous_base_to_derived_cast) << QualType(SrcType).getUnqualifiedType() << QualType(DestType).getUnqualifiedType() << PathDisplayStr << OpRange;"}}, | ||
[o]={ | [o]={ | ||
Line 972: | Line 992: | ||
}, | }, | ||
["err_ambiguous_delete_operand"]={ | ["err_ambiguous_delete_operand"]={ | ||
[ | [e]="ambiguous conversion of delete expression of type A to a pointer", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="ambiguous conversion of delete expression of type %0 to a pointer", | ||
[ | [b]=n, | ||
[ | [j]="ambiguous conversion of delete expression of type (.*?) to a pointer", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"c34c179f4bcd",1253035307,"Perform overload resolution when selecting a pointer conversion","Perform overload resolution when selecting a pointer conversion"}, | ||
[k]={{y,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 if (!Ex.get()->isTypeDependent()) {\n class DeleteConverter : public ContextualImplicitConverter {\n SemaDiagnosticBuilder diagnoseAmbiguous(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_ambiguous_delete_operand) << T; }"}}, | [k]={{y,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 if (!Ex.get()->isTypeDependent()) {\n class DeleteConverter : public ContextualImplicitConverter {\n SemaDiagnosticBuilder diagnoseAmbiguous(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_ambiguous_delete_operand) << T; }"}}, | ||
[o]={ | [o]={ | ||
Line 987: | Line 1,007: | ||
}, | }, | ||
["err_ambiguous_derived_to_base_conv"]={ | ["err_ambiguous_derived_to_base_conv"]={ | ||
[ | [e]="ambiguous conversion from derived class A to base class B:C", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="ambiguous conversion from derived class %0 to base class %1:%2", | ||
[ | [b]=n, | ||
[ | [j]="ambiguous conversion from derived class (.*?) to base class (.*?)\\:(.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{w,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); }"},{ | [k]={{w,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); }"},{ab,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 if (const PointerType *ToPtrType = ToType->getAs<PointerType>()) {\n if (const PointerType *FromPtrType = FromType->getAs<PointerType>()) {\n if (FromPointeeType->isRecordType() && ToPointeeType->isRecordType() && !Context.hasSameUnqualifiedType(FromPointeeType, ToPointeeType)) {\n if (Diagnose) {\n AmbiguousID = diag::err_ambiguous_derived_to_base_conv;"}}, | ||
[o]={ | [o]={ | ||
[ | [Ab]={"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"]={ | ["err_ambiguous_destructor"]={ | ||
[ | [e]="destructor of class A is ambiguous", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="destructor of class %0 is ambiguous", | ||
[ | [b]=n, | ||
[ | [j]="destructor of class (.*?) is ambiguous", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{ | [k]={{s,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 case OR_Ambiguous:\n Msg = diag::err_ambiguous_destructor;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,017: | Line 1,037: | ||
}, | }, | ||
["err_ambiguous_inherited_constructor"]={ | ["err_ambiguous_inherited_constructor"]={ | ||
[ | [e]="constructor of A inherited from multiple base class subobjects", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="constructor of %0 inherited from multiple base class subobjects", | ||
[ | [b]=n, | ||
[ | [j]="constructor of (.*?) inherited from multiple base class subobjects", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"5179eb78210a",1467140637,"P0136R1, DR1573, DR1645, DR1715, DR1736, DR1903, DR1941, DR1959, DR1991:","P0136R1, DR1573, DR1645, DR1715, DR1736, DR1903, DR1941, DR1959, DR1991:"}, | ||
[k]={{w,7302,"class Sema::InheritedConstructorInfo {\n InheritedConstructorInfo(Sema &S, SourceLocation UseLoc, ConstructorUsingShadowDecl *Shadow) : S(S), UseLoc(UseLoc) {\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 // [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 } else if (ConstructedBase != DConstructedBase && !Shadow->isInvalidDecl()) {\n if (!DiagnosedMultipleConstructedBases) {\n S.Diag(UseLoc, diag::err_ambiguous_inherited_constructor) << Shadow->getTargetDecl();"}}, | [k]={{w,7302,"class Sema::InheritedConstructorInfo {\n InheritedConstructorInfo(Sema &S, SourceLocation UseLoc, ConstructorUsingShadowDecl *Shadow) : S(S), UseLoc(UseLoc) {\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 // [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 } else if (ConstructedBase != DConstructedBase && !Shadow->isInvalidDecl()) {\n if (!DiagnosedMultipleConstructedBases) {\n S.Diag(UseLoc, diag::err_ambiguous_inherited_constructor) << Shadow->getTargetDecl();"}}, | ||
[o]={ | [o]={ | ||
Line 1,032: | Line 1,052: | ||
}, | }, | ||
["err_ambiguous_member_multiple_subobject_types"]={ | ["err_ambiguous_member_multiple_subobject_types"]={ | ||
[ | [e]="member A found in multiple base classes of different types", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="member %0 found in multiple base classes of different types", | ||
[ | [b]=n, | ||
[ | [j]="member (.*?) found in multiple base classes of different types", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{"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 case LookupResult::AmbiguousBaseSubobjectTypes: {\n Diag(NameLoc, diag::err_ambiguous_member_multiple_subobject_types) << Name << LookupRange;"}}, | [k]={{"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 case LookupResult::AmbiguousBaseSubobjectTypes: {\n Diag(NameLoc, diag::err_ambiguous_member_multiple_subobject_types) << Name << LookupRange;"}}, | ||
[o]={ | [o]={ | ||
Line 1,047: | Line 1,067: | ||
}, | }, | ||
["err_ambiguous_member_multiple_subobjects"]={ | ["err_ambiguous_member_multiple_subobjects"]={ | ||
[ | [e]="non-static member A found in multiple base-class subobjects of type B:C", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="non-static member %0 found in multiple base-class subobjects of type %1:%2", | ||
[ | [b]=n, | ||
[ | [j]="non\\-static member (.*?) found in multiple base\\-class subobjects of type (.*?)\\:(.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{"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 case LookupResult::AmbiguousBaseSubobjects: {\n Diag(NameLoc, diag::err_ambiguous_member_multiple_subobjects) << Name << SubobjectType << getAmbiguousPathsDisplayString(*Paths) << LookupRange;"}}, | [k]={{"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 case LookupResult::AmbiguousBaseSubobjects: {\n Diag(NameLoc, diag::err_ambiguous_member_multiple_subobjects) << Name << SubobjectType << getAmbiguousPathsDisplayString(*Paths) << LookupRange;"}}, | ||
[o]={ | [o]={ | ||
Line 1,062: | Line 1,082: | ||
}, | }, | ||
["err_ambiguous_memptr_conv"]={ | ["err_ambiguous_memptr_conv"]={ | ||
[ | [e]="ambiguous conversion from pointer to member of ... class A to pointer to member of ... class B:C", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="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", | ||
[ | [b]=n, | ||
[ | [j]="ambiguous conversion from pointer to member of (?:base|derived) class (.*?) to pointer to member of (?:derived|base) class (.*?)\\:(.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,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 // 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 Self.Diag(OpRange.getBegin(), diag::err_ambiguous_memptr_conv) << 1 << SrcClass << DestClass << PathDisplayStr << OpRange;"},{ | [k]={{x,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 // 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 Self.Diag(OpRange.getBegin(), diag::err_ambiguous_memptr_conv) << 1 << SrcClass << DestClass << PathDisplayStr << OpRange;"},{ab,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 if (Paths.isAmbiguous(Context.getCanonicalType(FromClass).getUnqualifiedType())) {\n Diag(From->getExprLoc(), diag::err_ambiguous_memptr_conv) << 0 << FromClass << ToClass << PathDisplayStr << From->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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\':"} | ["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\':"} | ||
Line 1,077: | Line 1,097: | ||
}, | }, | ||
["err_ambiguous_reference"]={ | ["err_ambiguous_reference"]={ | ||
[ | [e]="reference to A is ambiguous", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="reference to %0 is ambiguous", | ||
[ | [b]=n, | ||
[ | [j]="reference to (.*?) is ambiguous", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{"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 case LookupResult::AmbiguousReference: {\n Diag(NameLoc, diag::err_ambiguous_reference) << Name << LookupRange;"}}, | [k]={{"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 case LookupResult::AmbiguousReference: {\n Diag(NameLoc, diag::err_ambiguous_reference) << Name << LookupRange;"}}, | ||
[o]={ | [o]={ | ||
Line 1,092: | Line 1,112: | ||
}, | }, | ||
["err_ambiguous_suitable_delete_member_function_found"]={ | ["err_ambiguous_suitable_delete_member_function_found"]={ | ||
[ | [e]="multiple suitable A functions in B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="multiple suitable %0 functions in %1", | ||
[ | [b]=n, | ||
[ | [j]="multiple suitable (.*?) functions in (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"66a8759400a9",1280881886,"Look through using declarations when deciding whether to use an operator","Look through using declarations when deciding whether to use an operator"}, | ||
[k]={{y,3300,"bool Sema::FindDeallocationFunction(SourceLocation StartLoc, CXXRecordDecl *RD, DeclarationName Name, FunctionDecl *&Operator, bool Diagnose, bool WantSize, bool WantAligned) {\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;"}}, | [k]={{y,3300,"bool Sema::FindDeallocationFunction(SourceLocation StartLoc, CXXRecordDecl *RD, DeclarationName Name, FunctionDecl *&Operator, bool Diagnose, bool WantSize, bool WantAligned) {\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;"}}, | ||
[o]={ | [o]={ | ||
Line 1,107: | Line 1,127: | ||
}, | }, | ||
["err_ambiguous_tag_hiding"]={ | ["err_ambiguous_tag_hiding"]={ | ||
[ | [e]="a type named A is hidden by a declaration in a different namespace", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="a type named %0 is hidden by a declaration in a different namespace", | ||
[ | [b]=n, | ||
[ | [j]="a type named (.*?) is hidden by a declaration in a different namespace", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"6538c930503a",1255153699,"Qualified lookup through using declarations. Diagnose a new type of ambiguity.","Qualified lookup through using declarations. Diagnose a new type of ambiguity."}, | ||
[k]={{"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 case LookupResult::AmbiguousTagHiding: {\n Diag(NameLoc, diag::err_ambiguous_tag_hiding) << Name << LookupRange;"}}, | [k]={{"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 case LookupResult::AmbiguousTagHiding: {\n Diag(NameLoc, diag::err_ambiguous_tag_hiding) << Name << LookupRange;"}}, | ||
[o]={ | [o]={ | ||
Line 1,122: | Line 1,142: | ||
}, | }, | ||
["err_analyzer_checker_incompatible_analyzer_option"]={ | ["err_analyzer_checker_incompatible_analyzer_option"]={ | ||
[ | [e]="checker cannot be enabled with analyzer option \'A\' == B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="checker cannot be enabled with analyzer option \'%0\' == %1", | ||
[ | [b]=n, | ||
[ | [j]="checker cannot be enabled with analyzer option \'(.*?)\' \\=\\= (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={Wb,1534346725,hb,hb}, | ||
[k]={{"clang/lib/StaticAnalyzer/Checkers/ContainerModeling.cpp",1064,"bool ento::shouldRegisterContainerModeling(const CheckerManager &mgr) {\n if (!mgr.getAnalyzerOptions().ShouldAggressivelySimplifyBinaryOperation) {\n mgr.getASTContext().getDiagnostics().Report(diag::err_analyzer_checker_incompatible_analyzer_option) << \"aggressive-binary-operation-simplification\""}}, | [k]={{"clang/lib/StaticAnalyzer/Checkers/ContainerModeling.cpp",1064,"bool ento::shouldRegisterContainerModeling(const CheckerManager &mgr) {\n if (!mgr.getAnalyzerOptions().ShouldAggressivelySimplifyBinaryOperation) {\n mgr.getASTContext().getDiagnostics().Report(diag::err_analyzer_checker_incompatible_analyzer_option) << \"aggressive-binary-operation-simplification\""}}, | ||
[o]={ | [o]={ | ||
Line 1,137: | Line 1,157: | ||
}, | }, | ||
["err_analyzer_checker_option_invalid_input"]={ | ["err_analyzer_checker_option_invalid_input"]={ | ||
[ | [e]="invalid input for checker option \'A\', that expects B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid input for checker option \'%0\', that expects %1", | ||
[ | [b]=n, | ||
[ | [j]="invalid input for checker option \'(.*?)\', that expects (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={Wb,1534346725,hb,hb}, | ||
[k]={{"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 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 if (Option.OptionType == \"int\") {\n if (HasFailed) {\n if (AnOpts.ShouldEmitErrorsOnInvalidConfigValue) {\n Diags.Report(diag::err_analyzer_checker_option_invalid_input) << FullOption << \"an integer value\";"}} | [k]={{"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 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 if (Option.OptionType == \"int\") {\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"]={ | ["err_analyzer_checker_option_unknown"]={ | ||
[ | [e]="checker \'A\' has no option called \'B\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="checker \'%0\' has no option called \'%1\'", | ||
[ | [b]=n, | ||
[ | [j]="checker \'(.*?)\' has no option called \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={Wb,1534346725,hb,hb}, | ||
[k]={{"clang/lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp",484,"static void isOptionContainedIn(const CmdLineOptionList &OptionList, StringRef SuppliedChecker, StringRef SuppliedOption, const AnalyzerOptions &AnOpts, DiagnosticsEngine &Diags) {\n if (llvm::none_of(OptionList, SameOptName)) {\n Diags.Report(diag::err_analyzer_checker_option_unknown) << SuppliedChecker << SuppliedOption;"}} | [k]={{"clang/lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp",484,"static void isOptionContainedIn(const CmdLineOptionList &OptionList, StringRef SuppliedChecker, StringRef SuppliedOption, const AnalyzerOptions &AnOpts, DiagnosticsEngine &Diags) {\n if (llvm::none_of(OptionList, SameOptName)) {\n Diags.Report(diag::err_analyzer_checker_option_unknown) << SuppliedChecker << SuppliedOption;"}} | ||
}, | }, | ||
["err_analyzer_config_invalid_input"]={ | ["err_analyzer_config_invalid_input"]={ | ||
[ | [e]="invalid input for analyzer-config option \'A\', that expects B value", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid input for analyzer-config option \'%0\', that expects %1 value", | ||
[ | [b]=n, | ||
[ | [j]="invalid input for analyzer\\-config option \'(.*?)\', that expects (.*?) value", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={Wb,1534346725,hb,hb}, | ||
[k]={{ | [k]={{V,1106,"static void initOption(AnalyzerOptions::ConfigTable &Config, DiagnosticsEngine *Diags, bool &OptionField, StringRef Name, bool DefaultVal) {\n if (!PossiblyInvalidVal) {\n if (Diags)\n Diags->Report(diag::err_analyzer_config_invalid_input) << Name << \"a boolean\";"},{V,1123,"static void initOption(AnalyzerOptions::ConfigTable &Config, DiagnosticsEngine *Diags, unsigned &OptionField, StringRef Name, unsigned DefaultVal) {\n if (Diags && HasFailed)\n Diags->Report(diag::err_analyzer_config_invalid_input) << Name << \"an unsigned\";"},{V,1181,"#include \"clang/StaticAnalyzer/Core/AnalyzerOptions.def\"\n if (AnOpts.ShouldTrackConditionsDebug && !AnOpts.ShouldTrackConditions)\n Diags->Report(diag::err_analyzer_config_invalid_input) << \"track-conditions-debug\""},{V,1185,"#include \"clang/StaticAnalyzer/Core/AnalyzerOptions.def\"\n if (!AnOpts.CTUDir.empty() && !llvm::sys::fs::is_directory(AnOpts.CTUDir))\n Diags->Report(diag::err_analyzer_config_invalid_input) << \"ctu-dir\""},{V,1190,"#include \"clang/StaticAnalyzer/Core/AnalyzerOptions.def\"\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"]={ | ["err_analyzer_config_multiple_values"]={ | ||
[ | [e]="analyzer-config option \'A\' should contain only one \'=\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="analyzer-config option \'%0\' should contain only one \'=\'", | ||
[ | [b]=n, | ||
[ | [j]="analyzer\\-config option \'(.*?)\' should contain only one \'\\=\'", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"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"}, | ||
[k]={{ | [k]={{V,1045,"#include \"clang/StaticAnalyzer/Core/Analyses.def\"\n // Go through the analyzer configuration options.\n for (const auto *A : Args.filtered(OPT_analyzer_config)) {\n for (const auto &configVal : configVals) {\n if (val.contains(\'=\')) {\n Diags.Report(SourceLocation(), diag::err_analyzer_config_multiple_values) << configVal;"}} | ||
}, | }, | ||
["err_analyzer_config_no_value"]={ | ["err_analyzer_config_no_value"]={ | ||
[ | [e]="analyzer-config option \'A\' has a key but no value", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="analyzer-config option \'%0\' has a key but no value", | ||
[ | [b]=n, | ||
[ | [j]="analyzer\\-config option \'(.*?)\' has a key but no value", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"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"}, | ||
[k]={{ | [k]={{V,1040,"#include \"clang/StaticAnalyzer/Core/Analyses.def\"\n // Go through the analyzer configuration options.\n for (const auto *A : Args.filtered(OPT_analyzer_config)) {\n for (const auto &configVal : configVals) {\n if (val.empty()) {\n Diags.Report(SourceLocation(), diag::err_analyzer_config_no_value) << configVal;"}} | ||
}, | }, | ||
["err_analyzer_config_unknown"]={ | ["err_analyzer_config_unknown"]={ | ||
[ | [e]="unknown analyzer-config \'A\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="unknown analyzer-config \'%0\'", | ||
[ | [b]=n, | ||
[ | [j]="unknown analyzer\\-config \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={Wb,1534346725,hb,hb}, | ||
[k]={{ | [k]={{V,1054,"#include \"clang/StaticAnalyzer/Core/Analyses.def\"\n // Go through the analyzer configuration options.\n for (const auto *A : Args.filtered(OPT_analyzer_config)) {\n for (const auto &configVal : configVals) {\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"]={ | ["err_analyzer_not_built_with_z3"]={ | ||
[e]="analyzer constraint manager \'z3\' is only available if LLVM was built with -DLLVM_ENABLE_Z3_SOLVER=ON", | |||
[d]=l, | |||
[f]=m, | |||
[h]="analyzer constraint manager \'z3\' is only available if LLVM was built with -DLLVM_ENABLE_Z3_SOLVER=ON", | [h]="analyzer constraint manager \'z3\' is only available if LLVM was built with -DLLVM_ENABLE_Z3_SOLVER=ON", | ||
[ | [b]=n, | ||
[ | [j]="analyzer constraint manager \'z3\' is only available if LLVM was built with \\-DLLVM_ENABLE_Z3_SOLVER\\=ON", | ||
[c]=a, | |||
[i]=a, | |||
[g]={"0687578728ea",1610286626,bc,bc}, | |||
[ | [k]={{V,960,"#ifndef LLVM_WITH_Z3\n if (Value == AnalysisConstraints::Z3ConstraintsModel) {\n Diags.Report(diag::err_analyzer_not_built_with_z3);"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_anon_bitfield_has_negative_width"]={ | ["err_anon_bitfield_has_negative_width"]={ | ||
[ | [e]="anonymous bit-field has negative width (A)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="anonymous bit-field has negative width (%0)", | ||
[ | [b]=n, | ||
[ | [j]="anonymous bit\\-field has negative width \\((.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"f9b00eb7dc88",1240248578,"clean up anonymous bitfield diagnostics, PR4017","clean up anonymous bitfield diagnostics, PR4017"}, | ||
[k]={{ | [k]={{s,17926,"// Note that FieldName may be null for anonymous bitfields.\nExprResult Sema::VerifyBitField(SourceLocation FieldLoc, IdentifierInfo *FieldName, QualType FieldTy, bool IsMsStruct, Expr *BitWidth) {\n if (Value.isSigned() && Value.isNegative()) {\n return Diag(FieldLoc, diag::err_anon_bitfield_has_negative_width) << toString(Value, 10);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/bitfield.c"]={"clang/test/Sema/bitfield.c:26:3: error: anonymous bit-field has negative width (-2)"} | ["clang/test/Sema/bitfield.c"]={"clang/test/Sema/bitfield.c:26:3: error: anonymous bit-field has negative width (-2)"} | ||
Line 1,236: | Line 1,256: | ||
}, | }, | ||
["err_anon_bitfield_member_init"]={ | ["err_anon_bitfield_member_init"]={ | ||
[e]="anonymous bit-field cannot have a default member initializer", | |||
[d]=l, | |||
[f]=m, | |||
[h]="anonymous bit-field cannot have a default member initializer", | [h]="anonymous bit-field cannot have a default member initializer", | ||
[ | [b]=n, | ||
[ | [j]="anonymous bit\\-field cannot have a default member initializer", | ||
[c]=a, | |||
[i]=D, | |||
[g]={"2e204e23911b",1601401476,"[clang] Enable support for #pragma STDC FENV_ACCESS","[clang] Enable support for #pragma STDC FENV_ACCESS"}, | |||
[ | [k]={{P,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 while (true) {\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 Diag(Tok, diag::err_anon_bitfield_member_init);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,251: | Line 1,271: | ||
}, | }, | ||
["err_anon_bitfield_qualifiers"]={ | ["err_anon_bitfield_qualifiers"]={ | ||
[e]="anonymous bit-field cannot have qualifiers", | |||
[d]=l, | |||
[f]=m, | |||
[h]="anonymous bit-field cannot have qualifiers", | [h]="anonymous bit-field cannot have qualifiers", | ||
[ | [b]=n, | ||
[ | [j]="anonymous bit\\-field cannot have qualifiers", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"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++."}, | |||
[ | [k]={{s,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 // Anonymous bit-fields cannot be cv-qualified (CWG 2229).\n if (!InvalidDecl && getLangOpts().CPlusPlus && !II && BitWidth && T.hasQualifiers()) {\n Diag(Loc, diag::err_anon_bitfield_qualifiers);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,266: | Line 1,286: | ||
}, | }, | ||
["err_anon_type_definition"]={ | ["err_anon_type_definition"]={ | ||
[ | [e]="declaration of anonymous A must be a definition", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="declaration of anonymous %0 must be a definition", | ||
[ | [b]=n, | ||
[ | [j]="declaration of anonymous (.*?) must be a definition", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{P,1949,"#include \"clang/Basic/TransformTypeTraits.def\"\n if (!Name && !TemplateId && (DS.getTypeSpecType() == DeclSpec::TST_error || TUK != Sema::TUK_Definition)) {\n if (DS.getTypeSpecType() != DeclSpec::TST_error) {\n Diag(StartLoc, diag::err_anon_type_definition) << DeclSpec::getSpecifierName(TagType, Policy);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,281: | Line 1,301: | ||
}, | }, | ||
["err_anonymous_enum_bitfield"]={ | ["err_anonymous_enum_bitfield"]={ | ||
[e]="ISO C++ only allows \':\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit-field", | |||
[d]=l, | |||
[f]=m, | |||
[h]="ISO C++ only allows \':\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit-field", | [h]="ISO C++ only allows \':\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit-field", | ||
[ | [b]=n, | ||
[ | [j]="ISO C\\+\\+ only allows \'\\:\' in member enumeration declaration to introduce a fixed underlying type, not an anonymous bit\\-field", | ||
[c]=a, | |||
[i]=D, | |||
[g]={"c90e19810743",1588991058,"Fix parsing of enum-base to follow C++11 rules.","Fix parsing of enum-base to follow C++11 rules."}, | |||
[ | [k]={{H,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 // Parse the fixed underlying type.\n if (Tok.is(tok::colon)) {\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);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,296: | Line 1,316: | ||
}, | }, | ||
["err_anonymous_property"]={ | ["err_anonymous_property"]={ | ||
[e]="anonymous property is not supported", | |||
[d]=l, | |||
[f]=m, | |||
[h]="anonymous property is not supported", | [h]="anonymous property is not supported", | ||
[ | [b]=n, | ||
[ | [j]="anonymous property is not supported", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"5e77d76c953d",1366097310,"Basic support for Microsoft property declarations and","Basic support for Microsoft property declarations and"}, | |||
[ | |||
[ | |||
[k]={{w,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 if (!II) {\n Diag(DeclStart, diag::err_anonymous_property);"}}, | [k]={{w,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 if (!II) {\n Diag(DeclStart, diag::err_anonymous_property);"}}, | ||
[o]={ | [o]={ | ||
Line 1,311: | Line 1,331: | ||
}, | }, | ||
["err_anonymous_record_bad_member"]={ | ["err_anonymous_record_bad_member"]={ | ||
[ | [e]="anonymous ... can only contain non-static data members", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="anonymous %select{struct|union}0 can only contain non-static data members", | ||
[ | [b]=n, | ||
[ | [j]="anonymous (?:struct|union) can only contain non\\-static data members", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,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 if (getLangOpts().CPlusPlus) {\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 if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n } else if (Mem->isImplicit()) {\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n } else if (isa<AccessSpecDecl>(Mem)) {\n } else if (isa<StaticAssertDecl>(Mem)) {\n } else {\n unsigned DK = diag::err_anonymous_record_bad_member;"}} | ||
}, | }, | ||
["err_anonymous_record_member_redecl"]={ | ["err_anonymous_record_member_redecl"]={ | ||
[ | [e]="member of anonymous ... redeclares A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="member of anonymous %select{struct|union}0 redeclares %1", | ||
[ | [b]=n, | ||
[ | [j]="member of anonymous (?:struct|union) redeclares (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"da7b27ff0b98",1447738809,"[Sema] Combine similar diagnostics using %select. NFC","[Sema] Combine similar diagnostics using %select. NFC"}, | ||
[k]={{ | [k]={{s,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 SemaRef.Diag(NameLoc, diag::err_anonymous_record_member_redecl) << IsUnion << Name;"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 1,338: | Line 1,358: | ||
}, | }, | ||
["err_anonymous_record_nonpublic_member"]={ | ["err_anonymous_record_nonpublic_member"]={ | ||
[ | [e]="anonymous ... cannot contain a ... data member", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="anonymous %select{struct|union}0 cannot contain a %select{private|protected}1 data member", | ||
[ | [b]=n, | ||
[ | [j]="anonymous (?:struct|union) cannot contain a (?:private|protected) data member", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,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 if (getLangOpts().CPlusPlus) {\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 if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n if (FD->getAccess() != AS_public) {\n Diag(FD->getLocation(), diag::err_anonymous_record_nonpublic_member) << Record->isUnion() << (FD->getAccess() == AS_protected);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,353: | Line 1,373: | ||
}, | }, | ||
["err_anonymous_record_with_function"]={ | ["err_anonymous_record_with_function"]={ | ||
[ | [e]="functions cannot be declared in an anonymous ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="functions cannot be declared in an anonymous %select{struct|union}0", | ||
[ | [b]=n, | ||
[ | [j]="functions cannot be declared in an anonymous (?:struct|union)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,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 if (getLangOpts().CPlusPlus) {\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 if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n } else if (Mem->isImplicit()) {\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n } else if (isa<AccessSpecDecl>(Mem)) {\n } else if (isa<StaticAssertDecl>(Mem)) {\n } else {\n if (isa<TypeDecl>(Mem))\n else if (isa<FunctionDecl>(Mem))\n DK = diag::err_anonymous_record_with_function;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/anonymous-union.cpp"]={"clang/test/SemaCXX/anonymous-union.cpp:115:10: error: functions cannot be declared in an anonymous union"} | ["clang/test/SemaCXX/anonymous-union.cpp"]={"clang/test/SemaCXX/anonymous-union.cpp:115:10: error: functions cannot be declared in an anonymous union"} | ||
Line 1,368: | Line 1,388: | ||
}, | }, | ||
["err_anonymous_record_with_static"]={ | ["err_anonymous_record_with_static"]={ | ||
[ | [e]="static members cannot be declared in an anonymous ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="static members cannot be declared in an anonymous %select{struct|union}0", | ||
[ | [b]=n, | ||
[ | [j]="static members cannot be declared in an anonymous (?:struct|union)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,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 if (getLangOpts().CPlusPlus) {\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 if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n } else if (Mem->isImplicit()) {\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n } else if (isa<AccessSpecDecl>(Mem)) {\n } else if (isa<StaticAssertDecl>(Mem)) {\n } else {\n if (isa<TypeDecl>(Mem))\n else if (isa<FunctionDecl>(Mem))\n else if (isa<VarDecl>(Mem))\n DK = diag::err_anonymous_record_with_static;"}} | ||
}, | }, | ||
["err_anonymous_record_with_type"]={ | ["err_anonymous_record_with_type"]={ | ||
[ | [e]="types cannot be declared in an anonymous ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="types cannot be declared in an anonymous %select{struct|union}0", | ||
[ | [b]=n, | ||
[ | [j]="types cannot be declared in an anonymous (?:struct|union)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,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 if (getLangOpts().CPlusPlus) {\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 if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n } else if (Mem->isImplicit()) {\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\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 else {\n Diag(MemRecord->getLocation(), diag::err_anonymous_record_with_type) << Record->isUnion();"},{s,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 if (getLangOpts().CPlusPlus) {\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 if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n } else if (Mem->isImplicit()) {\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n } else if (isa<AccessSpecDecl>(Mem)) {\n } else if (isa<StaticAssertDecl>(Mem)) {\n } else {\n if (isa<TypeDecl>(Mem))\n DK = diag::err_anonymous_record_with_type;"},{s,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 if (getLangOpts().CPlusPlus) {\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 if (auto *FD = dyn_cast<FieldDecl>(Mem)) {\n } else if (Mem->isImplicit()) {\n } else if (isa<TagDecl>(Mem) && Mem->getDeclContext() != Record) {\n } else if (auto *MemRecord = dyn_cast<RecordDecl>(Mem)) {\n } else if (isa<AccessSpecDecl>(Mem)) {\n } else if (isa<StaticAssertDecl>(Mem)) {\n } else {\n if (getLangOpts().MicrosoftExt && DK == diag::err_anonymous_record_with_type)"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/anonymous-union.cpp"]={"clang/test/SemaCXX/anonymous-union.cpp:112:12: error: types cannot be declared in an anonymous union"} | ["clang/test/SemaCXX/anonymous-union.cpp"]={"clang/test/SemaCXX/anonymous-union.cpp:112:12: error: types cannot be declared in an anonymous union"} | ||
Line 1,395: | Line 1,415: | ||
}, | }, | ||
["err_anonymous_struct_not_member"]={ | ["err_anonymous_struct_not_member"]={ | ||
[ | [e]="anonymous ... must be ... members", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="anonymous %select{structs|structs and classes}0 must be %select{struct or union|class}0 members", | ||
[ | [b]=n, | ||
[ | [j]="anonymous (?:structs|structs and classes) must be (?:struct or union|class) members", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,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 if (!Record->isUnion() && !Owner->isRecord()) {\n Diag(Record->getLocation(), diag::err_anonymous_struct_not_member) << getLangOpts().CPlusPlus;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,410: | Line 1,430: | ||
}, | }, | ||
["err_anonymous_union_not_static"]={ | ["err_anonymous_union_not_static"]={ | ||
[e]="anonymous unions at namespace or global scope must be declared \'static\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="anonymous unions at namespace or global scope must be declared \'static\'", | [h]="anonymous unions at namespace or global scope must be declared \'static\'", | ||
[ | [b]=n, | ||
[ | [j]="anonymous unions at namespace or global scope must be declared \'static\'", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{s,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 if (getLangOpts().CPlusPlus) {\n if (Record->isUnion()) {\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 \");"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 1,425: | Line 1,445: | ||
}, | }, | ||
["err_anonymous_union_with_storage_spec"]={ | ["err_anonymous_union_with_storage_spec"]={ | ||
[e]="anonymous union at class scope must not have a storage specifier", | |||
[d]=l, | |||
[f]=m, | |||
[h]="anonymous union at class scope must not have a storage specifier", | [h]="anonymous union at class scope must not have a storage specifier", | ||
[ | [b]=n, | ||
[ | [j]="anonymous union at class scope must not have a storage specifier", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[ | [k]={{s,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 if (getLangOpts().CPlusPlus) {\n if (Record->isUnion()) {\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());"}}, | ||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,440: | Line 1,460: | ||
}, | }, | ||
["err_anyx86_interrupt_attribute"]={ | ["err_anyx86_interrupt_attribute"]={ | ||
[ | [e]="... \'interrupt\' attribute only applies to functions that have ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%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", | ||
[ | [b]=n, | ||
[ | [j]="(?: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)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"d51e9933b6aa",1452830791,"[X86] Support \'interrupt\' attribute for x86","[X86] Support \'interrupt\' attribute for x86"}, | ||
[k]={{q,7536,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,7546,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,7556,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,7572,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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);"}}, | [k]={{q,7536,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,7546,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,7556,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,7572,"static void handleAnyX86InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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);"}}, | ||
[o]={ | [o]={ | ||
Line 1,455: | Line 1,475: | ||
}, | }, | ||
["err_anyx86_interrupt_called"]={ | ["err_anyx86_interrupt_called"]={ | ||
[e]="interrupt service routine cannot be called directly", | |||
[d]=l, | |||
[f]=m, | |||
[h]="interrupt service routine cannot be called directly", | [h]="interrupt service routine cannot be called directly", | ||
[ | [b]=n, | ||
[ | [j]="interrupt service routine cannot be called directly", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"d51e9933b6aa",1452830791,"[X86] Support \'interrupt\' attribute for x86","[X86] Support \'interrupt\' attribute for x86"}, | |||
[k]={{A,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 // Functions with \'interrupt\' attribute cannot be called directly.\n if (FDecl && FDecl->hasAttr<AnyX86InterruptAttr>()) {\n Diag(Fn->getExprLoc(), diag::err_anyx86_interrupt_called);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,470: | Line 1,490: | ||
}, | }, | ||
["err_arc_array_param_no_ownership"]={ | ["err_arc_array_param_no_ownership"]={ | ||
[e]="must explicitly describe intended ownership of an object array parameter", | |||
[d]=l, | |||
[f]=m, | |||
[h]="must explicitly describe intended ownership of an object array parameter", | [h]="must explicitly describe intended ownership of an object array parameter", | ||
[ | [b]=n, | ||
[ | [j]="must explicitly describe intended ownership of an object array parameter", | ||
[c]=a, | |||
[ | [i]=Q, | ||
[g]={ob,1308874139,mb,nb}, | |||
[k]={{s,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 // 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));"},{s,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 // 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 else\n Diag(NameLoc, diag::err_arc_array_param_no_ownership) << TSInfo->getTypeLoc().getSourceRange();"},{q,9835,"/// Handle a delayed forbidden-type diagnostic.\nstatic void handleDelayedForbiddenType(Sema &S, DelayedDiagnostic &DD, Decl *D) {\n if (S.getLangOpts().ObjCAutoRefCount)\n if (const auto *FD = dyn_cast<FunctionDecl>(D)) {\n if (FD->hasAttr<UnavailableAttr>() && DD.getForbiddenTypeDiagnostic() == diag::err_arc_array_param_no_ownership) {"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,485: | Line 1,505: | ||
}, | }, | ||
["err_arc_assign_property_ownership"]={ | ["err_arc_assign_property_ownership"]={ | ||
[ | [e]="existing instance variable A for property B with ... attribute must be __unsafe_unretained", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="existing instance variable %1 for property %0 with %select{unsafe_unretained|assign}2 attribute must be __unsafe_unretained", | ||
[ | [b]=n, | ||
[ | [j]="existing instance variable (.*?) for property (.*?) with (?:unsafe_unretained|assign) attribute must be __unsafe_unretained", | ||
[ | [c]=a, | ||
[ | [i]="ARC and @properties", | ||
[ | [g]={ob,1308874139,mb,nb}, | ||
[k]={{ | [k]={{kb,208,"class PropertiesRewriter {\n void removeAssignForDefaultStrong(PropsTy &props, SourceLocation atLoc) const {\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());"},{kb,237,"class PropertiesRewriter {\n void rewriteAssign(PropsTy &props, SourceLocation atLoc) const {\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());"},{kb,262,"class PropertiesRewriter {\n void maybeAddWeakOrUnsafeUnretainedAttr(PropsTy &props, SourceLocation atLoc) const {\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());"},{Y,777,"static void checkARCPropertyImpl(Sema &S, SourceLocation propertyImplLoc, ObjCPropertyDecl *property, ObjCIvarDecl *ivar) {\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);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,500: | Line 1,520: | ||
}, | }, | ||
["err_arc_atomic_ownership"]={ | ["err_arc_atomic_ownership"]={ | ||
[ | [e]="cannot perform atomic operation on a pointer to type A: type has non-trivial ownership", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot perform atomic operation on a pointer to type %0: type has non-trivial ownership", | ||
[ | [b]=n, | ||
[ | [j]="cannot perform atomic operation on a pointer to type (.*?)\\: type has non\\-trivial ownership", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={ob,1308874139,mb,nb}, | ||
[k]={{ | [k]={{u,3238,"bool Sema::CheckARMBuiltinExclusiveCall(unsigned BuiltinID, CallExpr *TheCall, unsigned MaxWidth) {\n case Qualifiers::OCL_Autoreleasing:\n Diag(DRE->getBeginLoc(), diag::err_arc_atomic_ownership) << ValType << PointerArg->getSourceRange();"},{u,7247,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n case Qualifiers::OCL_Autoreleasing:\n Diag(ExprRange.getBegin(), diag::err_arc_atomic_ownership) << ValType << Ptr->getSourceRange();"},{u,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 case Qualifiers::OCL_Autoreleasing:\n Diag(DRE->getBeginLoc(), diag::err_arc_atomic_ownership) << ValType << FirstArg->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Cb]={"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"]={ | ["err_arc_autoreleasing_capture"]={ | ||
[ | [e]="cannot capture __autoreleasing variable in a ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot capture __autoreleasing variable in a %select{block|lambda by copy}0", | ||
[ | [b]=n, | ||
[ | [j]="cannot capture __autoreleasing variable in a (?:block|lambda by copy)", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={"67cd5e094e43",1333085028,"Forbid the block and lambda copy-capture of __autoreleasing variables","Forbid the block and lambda copy-capture of __autoreleasing variables"}, | ||
[k]={{ | [k]={{A,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 // 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;"},{A,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 // Compute the type of the field that will capture this variable.\n if (ByRef) {\n } else {\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;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/arc-invalid.m"]={"clang/test/SemaObjC/arc-invalid.m:17:23: error: cannot capture __autoreleasing variable in a block"} | ["clang/test/SemaObjC/arc-invalid.m"]={"clang/test/SemaObjC/arc-invalid.m:17:23: error: cannot capture __autoreleasing variable in a block"} | ||
Line 1,530: | Line 1,550: | ||
}, | }, | ||
["err_arc_autoreleasing_var"]={ | ["err_arc_autoreleasing_var"]={ | ||
[ | [e]="... cannot have __autoreleasing ownership", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{__block variables|global variables|fields|instance variables}0 cannot have __autoreleasing ownership", | ||
[ | [b]=n, | ||
[ | [j]="(?:__block variables|global variables|fields|instance variables) cannot have __autoreleasing ownership", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{s,6876,"bool Sema::inferObjCARCLifetime(ValueDecl *decl) {\n if (lifetime == Qualifiers::OCL_Autoreleasing) {\n if (kind != -1U) {\n Diag(decl->getLocation(), diag::err_arc_autoreleasing_var) << kind;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,545: | Line 1,565: | ||
}, | }, | ||
["err_arc_bridge_cast_incompatible"]={ | ["err_arc_bridge_cast_incompatible"]={ | ||
[ | [e]="incompatible types casting A to B with a ... cast", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="incompatible types casting %0 to %1 with a %select{__bridge|__bridge_transfer|__bridge_retained}2 cast", | ||
[ | [b]=n, | ||
[ | [j]="incompatible types casting (.*?) to (.*?) with a (?:__bridge|__bridge_transfer|__bridge_retained) cast", | ||
[ | [c]=a, | ||
[ | [i]="ARC Casting Rules", | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{M,4728,"ExprResult Sema::BuildObjCBridgedCast(SourceLocation LParenLoc, ObjCBridgeCastKind Kind, SourceLocation BridgeKeywordLoc, TypeSourceInfo *TSInfo, Expr *SubExpr) {\n if (T->isDependentType() || SubExpr->isTypeDependent()) {\n } else if (T->isObjCARCBridgableType() && FromType->isCARCBridgableType()) {\n } else if (T->isCARCBridgableType() && FromType->isObjCARCBridgableType()) {\n } else {\n Diag(LParenLoc, diag::err_arc_bridge_cast_incompatible) << FromType << T << Kind << SubExpr->getSourceRange() << TSInfo->getTypeLoc().getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,560: | Line 1,580: | ||
}, | }, | ||
["err_arc_bridge_cast_wrong_kind"]={ | ["err_arc_bridge_cast_wrong_kind"]={ | ||
[ | [e]="cast of ... pointer type A to ... pointer type B cannot use ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="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", | ||
[ | [b]=n, | ||
[ | [j]="cast of (?:Objective\\-C|block|C) pointer type (.*?) to (?:Objective\\-C|block|C) pointer type (.*?) cannot use (?:__bridge|__bridge_transfer|__bridge_retained)", | ||
[ | [c]=a, | ||
[ | [i]="ARC Casting Rules", | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{M,4665,"ExprResult Sema::BuildObjCBridgedCast(SourceLocation LParenLoc, ObjCBridgeCastKind Kind, SourceLocation BridgeKeywordLoc, TypeSourceInfo *TSInfo, Expr *SubExpr) {\n if (T->isDependentType() || SubExpr->isTypeDependent()) {\n } else if (T->isObjCARCBridgableType() && FromType->isCARCBridgableType()) {\n case OBC_BridgeRetained: {\n Diag(BridgeKeywordLoc, diag::err_arc_bridge_cast_wrong_kind) << 2 << FromType << (T->isBlockPointerType() ? 1 : 0) << T << SubExpr->getSourceRange() << Kind;"},{M,4708,"ExprResult Sema::BuildObjCBridgedCast(SourceLocation LParenLoc, ObjCBridgeCastKind Kind, SourceLocation BridgeKeywordLoc, TypeSourceInfo *TSInfo, Expr *SubExpr) {\n if (T->isDependentType() || SubExpr->isTypeDependent()) {\n } else if (T->isObjCARCBridgableType() && FromType->isCARCBridgableType()) {\n } else if (T->isCARCBridgableType() && FromType->isObjCARCBridgableType()) {\n case OBC_BridgeTransfer: {\n Diag(BridgeKeywordLoc, diag::err_arc_bridge_cast_wrong_kind) << (FromType->isBlockPointerType() ? 1 : 0) << FromType << 2 << T << SubExpr->getSourceRange() << Kind;"}} | ||
}, | }, | ||
["err_arc_bridge_retain"]={ | ["err_arc_bridge_retain"]={ | ||
[e]="unknown cast annotation __bridge_retain; did you mean __bridge_retained?", | |||
[d]=l, | |||
[f]=m, | |||
[h]="unknown cast annotation __bridge_retain; did you mean __bridge_retained?", | [h]="unknown cast annotation __bridge_retain; did you mean __bridge_retained?", | ||
[ | [b]=n, | ||
[ | [j]="unknown cast annotation __bridge_retain; did you mean __bridge_retained\\?", | ||
[c]=a, | |||
[i]="ARC Parse Issue", | |||
[g]={"0c07bee8bd2c",1308347772,"Only accept __bridge_retain in system headers, as Doug suggested.","Only accept __bridge_retain in system headers, as Doug suggested."}, | |||
[ | [k]={{Gb,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 // 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 } else if (ExprType >= CompoundLiteral && BridgeCast) {\n if (tokenKind == tok::kw___bridge)\n else if (tokenKind == tok::kw___bridge_transfer)\n else if (tokenKind == tok::kw___bridge_retained)\n else {\n if (!PP.getSourceManager().isInSystemHeader(BridgeKeywordLoc))\n Diag(BridgeKeywordLoc, diag::err_arc_bridge_retain) << FixItHint::CreateReplacement(BridgeKeywordLoc, \"__bridge_retained\");"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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?"} | ["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?"} | ||
Line 1,587: | Line 1,607: | ||
}, | }, | ||
["err_arc_cast_requires_bridge"]={ | ["err_arc_cast_requires_bridge"]={ | ||
[ | [e]="... of ... pointer type A to ... pointer type B requires a bridged cast", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%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", | ||
[ | [b]=n, | ||
[ | [j]="(?:cast|implicit conversion) of (?:Objective\\-C|block|C) pointer type (.*?) to (?:Objective\\-C|block|C) pointer type (.*?) requires a bridged cast", | ||
[ | [c]=a, | ||
[ | [i]="ARC Casting Rules", | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{qb,210,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n void rewriteToBridgedCast(CastExpr *E, ObjCBridgeCastKind Kind, Transaction &Trans) {\n if (!TA.hasDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, E->getBeginLoc())) {"},{qb,227,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n void rewriteToBridgedCast(CastExpr *E, ObjCBridgeCastKind Kind, Transaction &Trans) {\n TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, E->getBeginLoc());"},{qb,303,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n void rewriteBlockCopyMacro(CastExpr *E) {\n Pass.TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, OuterRange);"},{qb,313,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n void removeBlockReleaseMacro(CastExpr *E) {\n Pass.TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, OuterRange);"},{M,3918,"static void diagnoseObjCARCConversion(Sema &S, SourceRange castRange, QualType castType, ARCConversionTypeClass castACTC, Expr *castExpr, Expr *realCast, ARCConversionTypeClass exprACTC, Sema::CheckedConversionKind CCK) {\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"},{M,3960,"static void diagnoseObjCARCConversion(Sema &S, SourceRange castRange, QualType castType, ARCConversionTypeClass castACTC, Expr *castExpr, Expr *realCast, ARCConversionTypeClass exprACTC, Sema::CheckedConversionKind CCK) {\n // Bridge from a CF type to an ARC type.\n if (exprACTC == ACTC_retainable && isAnyRetainable(castACTC)) {\n S.Diag(loc, diag::err_arc_cast_requires_bridge) << convKindForDiag << unsigned(castExprType->isBlockPointerType()) // of ObjC|block type"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,602: | Line 1,622: | ||
}, | }, | ||
["err_arc_collection_forward"]={ | ["err_arc_collection_forward"]={ | ||
[ | [e]="collection expression type A is a forward declaration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="collection expression type %0 is a forward declaration", | ||
[ | [b]=n, | ||
[ | [j]="collection expression type (.*?) is a forward declaration", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={"538482373bba",1311728835,"Clean up the analysis of the collection operand to ObjC","Clean up the analysis of the collection operand to ObjC"}, | ||
[k]={{ | [k]={{bb,2244,"ExprResult Sema::CheckObjCForCollectionOperand(SourceLocation forLoc, Expr *collection) {\n if (iface && (getLangOpts().ObjCAutoRefCount ? RequireCompleteType(forLoc, QualType(objectType, 0), diag::err_arc_collection_forward, collection) : !isCompleteType(forLoc, QualType(objectType, 0)))) {"}}, | ||
[o]={ | [o]={ | ||
[ | [Cb]={"clang/test/SemaObjC/arc.m:690:3: error: collection expression type \'Test37\' is a forward declaration"} | ||
} | } | ||
}, | }, | ||
["err_arc_convesion_of_weak_unavailable"]={ | ["err_arc_convesion_of_weak_unavailable"]={ | ||
[ | [e]="... of weak-unavailable object of type A to a __weak object of type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{implicit conversion|cast}0 of weak-unavailable object of type %1 to a __weak object of type %2", | ||
[ | [b]=n, | ||
[ | [j]="(?:implicit conversion|cast) of weak\\-unavailable object of type (.*?) to a __weak object of type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=ec, | ||
[ | [g]={"f2913401fc81",1310146902,"objc++-arc: more diagnosis of converting a weak-unavailable","objc++-arc: more diagnosis of converting a weak-unavailable"}, | ||
[k]={{x,3215,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n // ARC imposes extra restrictions on casts.\n if (Self.getLangOpts().allowsNonTrivialObjCLifetimeQualifiers()) {\n if (Self.getLangOpts().ObjCAutoRefCount && CastPtr) {\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();"},{y,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 case ICK_Pointer_Conversion: {\n if (SCS.IncompatibleObjC && Action != AA_Casting) {\n } else if (getLangOpts().allowsNonTrivialObjCLifetimeQualifiers() && !CheckObjCARCUnavailableWeakConversion(ToType, From->getType())) {\n if (Action == AA_Initializing)\n else\n Diag(From->getBeginLoc(), diag::err_arc_convesion_of_weak_unavailable) << (Action == AA_Casting) << From->getType() << ToType << From->getSourceRange();"}}, | [k]={{x,3215,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n // ARC imposes extra restrictions on casts.\n if (Self.getLangOpts().allowsNonTrivialObjCLifetimeQualifiers()) {\n if (Self.getLangOpts().ObjCAutoRefCount && CastPtr) {\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();"},{y,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 case ICK_Pointer_Conversion: {\n if (SCS.IncompatibleObjC && Action != AA_Casting) {\n } else if (getLangOpts().allowsNonTrivialObjCLifetimeQualifiers() && !CheckObjCARCUnavailableWeakConversion(ToType, From->getType())) {\n if (Action == AA_Initializing)\n else\n Diag(From->getBeginLoc(), diag::err_arc_convesion_of_weak_unavailable) << (Action == AA_Casting) << From->getType() << ToType << From->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 1,632: | Line 1,652: | ||
}, | }, | ||
["err_arc_gained_method_convention"]={ | ["err_arc_gained_method_convention"]={ | ||
[e]="method implementation does not match its declaration", | |||
[d]=l, | |||
[f]=m, | |||
[h]="method implementation does not match its declaration", | [h]="method implementation does not match its declaration", | ||
[ | [b]=n, | ||
[ | [j]="method implementation does not match its declaration", | ||
[c]=a, | |||
[ | [i]=Q, | ||
[g]={N,1308178962,z,z}, | |||
[k]={{O,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 if (declFamily == OMF_None) {\n errorID = diag::err_arc_gained_method_convention;"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [oc]={"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"]={ | ["err_arc_illegal_explicit_message"]={ | ||
[ | [e]="ARC forbids explicit message send of A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="ARC forbids explicit message send of %0", | ||
[ | [b]=n, | ||
[ | [j]="ARC forbids explicit message send of (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=zb, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{"clang/lib/ARCMigrate/TransRetainReleaseDealloc.cpp",390,"class RetainReleaseDeallocRemover : public RecursiveASTVisitor<RetainReleaseDeallocRemover> {\n void clearDiagnostics(SourceLocation loc) const { Pass.TA.clearDiagnostic(diag::err_arc_illegal_explicit_message, diag::err_unavailable, diag::err_unavailable_message, loc); }"},{ | [k]={{"clang/lib/ARCMigrate/TransRetainReleaseDealloc.cpp",390,"class RetainReleaseDeallocRemover : public RecursiveASTVisitor<RetainReleaseDeallocRemover> {\n void clearDiagnostics(SourceLocation loc) const { Pass.TA.clearDiagnostic(diag::err_arc_illegal_explicit_message, diag::err_unavailable, diag::err_unavailable_message, loc); }"},{M,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 // In ARC, forbid the user from sending messages to\n // retain/release/autorelease/dealloc/retainCount explicitly.\n if (getLangOpts().ObjCAutoRefCount) {\n case OMF_retainCount:\n Diag(SelLoc, diag::err_arc_illegal_explicit_message) << Sel << RecRange;"}}, | ||
[o]={ | [o]={ | ||
[ | [oc]={"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"]={ | ["err_arc_illegal_method_def"]={ | ||
[ | [e]="ARC forbids ... of A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="ARC forbids %select{implementation|synthesis}0 of %1", | ||
[ | [b]=n, | ||
[ | [j]="ARC forbids (?:implementation|synthesis) of (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=zb, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{O,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 // In ARC, disallow definition of retain/release/autorelease/retainCount\n if (getLangOpts().ObjCAutoRefCount) {\n case OMF_autorelease:\n Diag(MDecl->getLocation(), diag::err_arc_illegal_method_def) << 0 << MDecl->getSelector();"},{Y,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 if (ObjCMethodDecl *getterMethod = property->getGetterMethodDecl()) {\n if (getLangOpts().ObjCAutoRefCount && Synthesize)\n case OMF_autorelease:\n Diag(getterMethod->getLocation(), diag::err_arc_illegal_method_def) << 1 << getterMethod->getSelector();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/arc-property-lifetime.m"]={"clang/test/SemaObjC/arc-property-lifetime.m:199:36: error: ARC forbids synthesis of \'retain\'"} | ["clang/test/SemaObjC/arc-property-lifetime.m"]={"clang/test/SemaObjC/arc-property-lifetime.m:199:36: error: ARC forbids synthesis of \'retain\'"} | ||
Line 1,677: | Line 1,697: | ||
}, | }, | ||
["err_arc_illegal_selector"]={ | ["err_arc_illegal_selector"]={ | ||
[ | [e]="ARC forbids use of A in a @selector", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="ARC forbids use of %0 in a @selector", | ||
[ | [b]=n, | ||
[ | [j]="ARC forbids use of (.*?) in a @selector", | ||
[ | [c]=a, | ||
[ | [i]=zb, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{M,1364,"ExprResult Sema::ParseObjCSelectorExpression(Selector Sel, SourceLocation AtLoc, SourceLocation SelLoc, SourceLocation LParenLoc, SourceLocation RParenLoc, bool WarnMultipleSelectors) {\n // In ARC, forbid the user from using @selector for\n // retain/release/autorelease/dealloc/retainCount.\n if (getLangOpts().ObjCAutoRefCount) {\n case OMF_dealloc:\n Diag(AtLoc, diag::err_arc_illegal_selector) << Sel << SourceRange(LParenLoc, RParenLoc);"}}, | ||
[o]={ | [o]={ | ||
[ | [oc]={"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"]={ | ["err_arc_inconsistent_property_ownership"]={ | ||
[ | [e]="... property A may not also be declared ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{|unsafe_unretained|strong|weak}1 property %0 may not also be declared %select{|__unsafe_unretained|__strong|__weak|__autoreleasing}2", | ||
[ | [b]=n, | ||
[ | [j]="(?:|unsafe_unretained|strong|weak) property (.*?) may not also be declared (?:|__unsafe_unretained|__strong|__weak|__autoreleasing)", | ||
[ | [c]=a, | ||
[ | [i]="ARC and @properties", | ||
[ | [g]={ob,1308874139,mb,nb}, | ||
[k]={{"clang/lib/ARCMigrate/TransGCAttrs.cpp",291,"static void checkAllAtProps(MigrationContext &MigrateCtx, SourceLocation AtLoc, IndivPropsTy &IndProps) {\n for (unsigned i = 0, e = ATLs.size(); i != e; ++i) {\n TA.clearDiagnostic(diag::err_arc_inconsistent_property_ownership, ATLs[i].second->getLocation());"},{ | [k]={{"clang/lib/ARCMigrate/TransGCAttrs.cpp",291,"static void checkAllAtProps(MigrationContext &MigrateCtx, SourceLocation AtLoc, IndivPropsTy &IndProps) {\n for (unsigned i = 0, e = ATLs.size(); i != e; ++i) {\n TA.clearDiagnostic(diag::err_arc_inconsistent_property_ownership, ATLs[i].second->getLocation());"},{kb,209,"class PropertiesRewriter {\n void removeAssignForDefaultStrong(PropsTy &props, SourceLocation atLoc) const {\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());"},{kb,238,"class PropertiesRewriter {\n void rewriteAssign(PropsTy &props, SourceLocation atLoc) const {\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());"},{kb,263,"class PropertiesRewriter {\n void maybeAddWeakOrUnsafeUnretainedAttr(PropsTy &props, SourceLocation atLoc) const {\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());"},{Y,99,"/// Check the internal consistency of a property declaration with\n/// an explicit ownership qualifier.\nstatic void checkPropertyDeclWithOwnership(Sema &S, ObjCPropertyDecl *property) {\n S.Diag(property->getLocation(), diag::err_arc_inconsistent_property_ownership) << property->getDeclName() << expectedLifetime << propertyLifetime;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,707: | Line 1,727: | ||
}, | }, | ||
["err_arc_indirect_no_ownership"]={ | ["err_arc_indirect_no_ownership"]={ | ||
[ | [e]="... to non-const type A with no explicit ownership", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{pointer|reference}1 to non-const type %0 with no explicit ownership", | ||
[ | [b]=n, | ||
[ | [j]="(?:pointer|reference) to non\\-const type (.*?) with no explicit ownership", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={ob,1308874139,mb,nb}, | ||
[k]={{ | [k]={{t,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 // 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 } else if (type->isObjCARCImplicitlyUnretainedType()) {\n } else if (S.isUnevaluatedContext()) {\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));"},{t,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 // 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 } else if (type->isObjCARCImplicitlyUnretainedType()) {\n } else if (S.isUnevaluatedContext()) {\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 } else {\n S.Diag(loc, diag::err_arc_indirect_no_ownership) << type << isReference;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,722: | Line 1,742: | ||
}, | }, | ||
["err_arc_init_method_unrelated_result_type"]={ | ["err_arc_init_method_unrelated_result_type"]={ | ||
[e]="init methods must return a type related to the receiver type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="init methods must return a type related to the receiver type", | [h]="init methods must return a type related to the receiver type", | ||
[ | [b]=n, | ||
[ | [j]="init methods must return a type related to the receiver type", | ||
[c]=a, | |||
[ | [i]=Q, | ||
[g]={N,1308178962,z,z}, | |||
[k]={{O,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 Diag(loc, diag::err_arc_init_method_unrelated_result_type);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [oc]={"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"]={ | ["err_arc_lost_method_convention"]={ | ||
[ | [e]="method was declared as ... method, but its implementation doesn\'t match because ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="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", | ||
[ | [b]=n, | ||
[ | [j]="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)", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{O,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 unsigned errorID = diag::err_arc_lost_method_convention;"}}, | ||
[o]={ | [o]={ | ||
[ | [oc]={"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"]={ | ["err_arc_may_not_respond"]={ | ||
[ | [e]="no visible @interface for A declares the selector B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="no visible @interface for %0 declares the selector %1", | ||
[ | [b]=n, | ||
[ | [j]="no visible @interface for (.*?) declares the selector (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{M,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 if (!Method) {\n if (receiverIsIdLike || ReceiverType->isBlockPointerType() || (Receiver && Context.isObjCNSObjectType(Receiver->getType()))) {\n } else if (ReceiverType->isObjCClassOrClassKindOfType() || ReceiverType->isObjCQualifiedClassType()) {\n } else {\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 } else if (const ObjCObjectPointerType *OCIType = ReceiverType->getAsObjCInterfacePointerType()) {\n if (!Method) {\n if (!Method && getLangOpts().ObjCAutoRefCount) {\n Diag(SelLoc, diag::err_arc_may_not_respond) << OCIType->getPointeeType() << Sel << RecRange << SourceRange(SelectorLocs.front(), SelectorLocs.back());"}}, | ||
[o]={ | [o]={ | ||
["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:\'"} | ["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:\'"} | ||
Line 1,767: | Line 1,787: | ||
}, | }, | ||
["err_arc_method_not_found"]={ | ["err_arc_method_not_found"]={ | ||
[ | [e]="no known ... method for selector A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="no known %select{instance|class}1 method for selector %0", | ||
[ | [b]=n, | ||
[ | [j]="no known (?:instance|class) method for selector (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{M,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 if (!Method) {\n if (getLangOpts().ObjCAutoRefCount)\n DiagID = diag::err_arc_method_not_found;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/method-direct-arc.m"]={"clang/test/SemaObjC/method-direct-arc.m:46:9: error: no known class method for selector \'directMethod\'"} | ["clang/test/SemaObjC/method-direct-arc.m"]={"clang/test/SemaObjC/method-direct-arc.m:46:9: error: no known class method for selector \'directMethod\'"} | ||
Line 1,782: | Line 1,802: | ||
}, | }, | ||
["err_arc_mismatched_cast"]={ | ["err_arc_mismatched_cast"]={ | ||
[ | [e]="... of ... to A is disallowed with ARC", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%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", | ||
[ | [b]=n, | ||
[ | [j]="(?: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", | ||
[ | [c]=a, | ||
[ | [i]=zb, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{qb,209,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n void rewriteToBridgedCast(CastExpr *E, ObjCBridgeCastKind Kind, Transaction &Trans) {\n if (!TA.hasDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, E->getBeginLoc())) {"},{qb,226,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n void rewriteToBridgedCast(CastExpr *E, ObjCBridgeCastKind Kind, Transaction &Trans) {\n TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, E->getBeginLoc());"},{qb,302,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n void rewriteBlockCopyMacro(CastExpr *E) {\n Pass.TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, OuterRange);"},{qb,312,"class UnbridgedCastRewriter : public RecursiveASTVisitor<UnbridgedCastRewriter> {\n void removeBlockReleaseMacro(CastExpr *E) {\n Pass.TA.clearDiagnostic(diag::err_arc_mismatched_cast, diag::err_arc_cast_requires_bridge, OuterRange);"},{M,3997,"static void diagnoseObjCARCConversion(Sema &S, SourceRange castRange, QualType castType, ARCConversionTypeClass castACTC, Expr *castExpr, Expr *realCast, ARCConversionTypeClass exprACTC, Sema::CheckedConversionKind CCK) {\n S.Diag(loc, diag::err_arc_mismatched_cast) << !convKindForDiag << srcKind << castExprType << castType << castRange << castExpr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,797: | Line 1,817: | ||
}, | }, | ||
["err_arc_multiple_method_decl"]={ | ["err_arc_multiple_method_decl"]={ | ||
[ | [e]="multiple methods named A found with mismatched result, parameter type or attributes", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="multiple methods named %0 found with mismatched result, parameter type or attributes", | ||
[ | [b]=n, | ||
[ | [j]="multiple methods named (.*?) found with mismatched result, parameter type or attributes", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{O,3635,"void Sema::DiagnoseMultipleMethodInGlobalPool(SmallVectorImpl<ObjCMethodDecl *> &Methods, Selector Sel, SourceRange R, bool receiverIdOrClass) {\n if (issueDiagnostic) {\n if (issueError)\n Diag(R.getBegin(), diag::err_arc_multiple_method_decl) << Sel << R;"}}, | ||
[o]={ | [o]={ | ||
[ | [Cb]={"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"]={ | ["err_arc_new_array_without_ownership"]={ | ||
[ | [e]="\'new\' cannot allocate an array of A with no explicit ownership", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'new\' cannot allocate an array of %0 with no explicit ownership", | ||
[ | [b]=n, | ||
[ | [j]="\'new\' cannot allocate an array of (.*?) with no explicit ownership", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={ob,1308874139,mb,nb}, | ||
[k]={{y,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 else if (AllocType->isReferenceType())\n else if (!AllocType->isDependentType() && RequireCompleteSizedType(Loc, AllocType, diag::err_new_incomplete_or_sizeless_type, R))\n else if (RequireNonAbstractType(Loc, AllocType, diag::err_allocation_of_abstract_type))\n else if (AllocType->isVariablyModifiedType())\n else if (AllocType.getAddressSpace() != LangAS::Default && !getLangOpts().OpenCLCPlusPlus)\n else if (getLangOpts().ObjCAutoRefCount) {\n if (const ArrayType *AT = Context.getAsArrayType(AllocType)) {\n if (BaseAllocType.getObjCLifetime() == Qualifiers::OCL_None && BaseAllocType->isObjCLifetimeType())\n return Diag(Loc, diag::err_arc_new_array_without_ownership) << BaseAllocType;"}} | [k]={{y,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 else if (AllocType->isReferenceType())\n else if (!AllocType->isDependentType() && RequireCompleteSizedType(Loc, AllocType, diag::err_new_incomplete_or_sizeless_type, R))\n else if (RequireNonAbstractType(Loc, AllocType, diag::err_allocation_of_abstract_type))\n else if (AllocType->isVariablyModifiedType())\n else if (AllocType.getAddressSpace() != LangAS::Default && !getLangOpts().OpenCLCPlusPlus)\n else if (getLangOpts().ObjCAutoRefCount) {\n if (const ArrayType *AT = Context.getAsArrayType(AllocType)) {\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"]={ | ["err_arc_nolifetime_behavior"]={ | ||
[e]="explicit ownership qualifier on cast result has no effect", | |||
[d]=l, | |||
[f]=m, | |||
[h]="explicit ownership qualifier on cast result has no effect", | [h]="explicit ownership qualifier on cast result has no effect", | ||
[ | [b]=n, | ||
[ | [j]="explicit ownership qualifier on cast result has no effect", | ||
[c]=a, | |||
[ | [i]=zb, | ||
[g]={"2fa646d59623",1319832367,"objective-c arc: type-casting of an objc pointer to","objective-c arc: type-casting of an objc pointer to"}, | |||
[k]={{M,4426,"Sema::ARCConversionResult Sema::CheckObjCConversion(SourceRange castRange, QualType castType, Expr *&castExpr, CheckedConversionKind CCK, bool Diagnose, bool DiagnoseCFAudited, BinaryOperatorKind Opc) {\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 if (QDT != castType && QDT.getObjCLifetime() != Qualifiers::OCL_None) {\n if (Diagnose) {\n Diag(loc, diag::err_arc_nolifetime_behavior);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,839: | Line 1,859: | ||
}, | }, | ||
["err_arc_nonlocal_writeback"]={ | ["err_arc_nonlocal_writeback"]={ | ||
[ | [e]="passing address of ... object to __autoreleasing parameter for write-back", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="passing address of %select{non-local|non-scalar}0 object to __autoreleasing parameter for write-back", | ||
[ | [b]=n, | ||
[ | [j]="passing address of (?:non\\-local|non\\-scalar) object to __autoreleasing parameter for write\\-back", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{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 S.Diag(src->getExprLoc(), diag::err_arc_nonlocal_writeback) << ((unsigned)iik - 1) // shift index into diagnostic explanations"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,854: | Line 1,874: | ||
}, | }, | ||
["err_arc_objc_property_default_assign_on_object"]={ | ["err_arc_objc_property_default_assign_on_object"]={ | ||
[e]="ARC forbids synthesizing a property of an Objective-C object with unspecified ownership or storage attribute", | |||
[d]=l, | |||
[f]=m, | |||
[h]="ARC forbids synthesizing a property of an Objective-C object with unspecified ownership or storage attribute", | [h]="ARC forbids synthesizing a property of an Objective-C object with unspecified ownership or storage attribute", | ||
[ | [b]=n, | ||
[ | [j]="ARC forbids synthesizing a property of an Objective\\-C object with unspecified ownership or storage attribute", | ||
[c]=a, | |||
[i]=zb, | |||
[g]={N,1308178962,z,z}, | |||
[ | [k]={{kb,266,"class PropertiesRewriter {\n void maybeAddWeakOrUnsafeUnretainedAttr(PropsTy &props, SourceLocation atLoc) const {\n for (PropsTy::iterator I = props.begin(), E = props.end(); I != E; ++I) {\n if (I->ImplD) {\n Pass.TA.clearDiagnostic(diag::err_arc_objc_property_default_assign_on_object, I->ImplD->getLocation());"},{Y,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 // Check that we have a valid, previously declared ivar for @synthesize\n if (Synthesize) {\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);"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_arc_perform_selector_retains"]={ | ["err_arc_perform_selector_retains"]={ | ||
[e]="performSelector names a selector which retains the object", | |||
[d]=l, | |||
[f]=m, | |||
[h]="performSelector names a selector which retains the object", | [h]="performSelector names a selector which retains the object", | ||
[ | [b]=n, | ||
[ | [j]="performSelector names a selector which retains the object", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"b7a773626fea",1309905539,"objc-arc: enforce performSelector rules in rejecting retaining selectors","objc-arc: enforce performSelector rules in rejecting retaining selectors"}, | |||
[k]={{M,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 // In ARC, forbid the user from sending messages to\n // retain/release/autorelease/dealloc/retainCount explicitly.\n if (getLangOpts().ObjCAutoRefCount) {\n case OMF_performSelector:\n if (Method && NumArgs >= 1) {\n if (const auto *SelExp = dyn_cast<ObjCSelectorExpr>(Args[0]->IgnoreParens())) {\n if (SelMethod) {\n case OMF_init:\n // Issue error, unless ns_returns_not_retained.\n if (!SelMethod->hasAttr<NSReturnsNotRetainedAttr>()) {\n Diag(SelLoc, diag::err_arc_perform_selector_retains);"},{M,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 // In ARC, forbid the user from sending messages to\n // retain/release/autorelease/dealloc/retainCount explicitly.\n if (getLangOpts().ObjCAutoRefCount) {\n case OMF_performSelector:\n if (Method && NumArgs >= 1) {\n if (const auto *SelExp = dyn_cast<ObjCSelectorExpr>(Args[0]->IgnoreParens())) {\n if (SelMethod) {\n default:\n // +0 call. OK. unless ns_returns_retained.\n if (SelMethod->hasAttr<NSReturnsRetainedAttr>()) {\n Diag(SelLoc, diag::err_arc_perform_selector_retains);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,881: | Line 1,901: | ||
}, | }, | ||
["err_arc_pseudo_dtor_inconstant_quals"]={ | ["err_arc_pseudo_dtor_inconstant_quals"]={ | ||
[ | [e]="pseudo-destructor destroys object of type A with inconsistently-qualified type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="pseudo-destructor destroys object of type %0 with inconsistently-qualified type %1", | ||
[ | [b]=n, | ||
[ | [j]="pseudo\\-destructor destroys object of type (.*?) with inconsistently\\-qualified type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{y,7822,"ExprResult Sema::BuildPseudoDestructorExpr(Expr *Base, SourceLocation OpLoc, tok::TokenKind OpKind, const CXXScopeSpec &SS, TypeSourceInfo *ScopeTypeInfo, SourceLocation CCLoc, SourceLocation TildeLoc, PseudoDestructorTypeStorage Destructed) {\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 if (!DestructedType->isDependentType() && !ObjectType->isDependentType()) {\n if (!Context.hasSameUnqualifiedType(DestructedType, ObjectType)) {\n } else if (DestructedType.getObjCLifetime() != ObjectType.getObjCLifetime()) {\n if (DestructedType.getObjCLifetime() == Qualifiers::OCL_None) {\n } else {\n Diag(DestructedTypeStart, diag::err_arc_pseudo_dtor_inconstant_quals) << ObjectType << DestructedType << Base->getSourceRange() << DestructedTypeInfo->getTypeLoc().getSourceRange();"}} | [k]={{y,7822,"ExprResult Sema::BuildPseudoDestructorExpr(Expr *Base, SourceLocation OpLoc, tok::TokenKind OpKind, const CXXScopeSpec &SS, TypeSourceInfo *ScopeTypeInfo, SourceLocation CCLoc, SourceLocation TildeLoc, PseudoDestructorTypeStorage Destructed) {\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 if (!DestructedType->isDependentType() && !ObjectType->isDependentType()) {\n if (!Context.hasSameUnqualifiedType(DestructedType, ObjectType)) {\n } else if (DestructedType.getObjCLifetime() != ObjectType.getObjCLifetime()) {\n if (DestructedType.getObjCLifetime() == Qualifiers::OCL_None) {\n } else {\n Diag(DestructedTypeStart, diag::err_arc_pseudo_dtor_inconstant_quals) << ObjectType << DestructedType << Base->getSourceRange() << DestructedTypeInfo->getTypeLoc().getSourceRange();"}} | ||
}, | }, | ||
["err_arc_receiver_forward_class"]={ | ["err_arc_receiver_forward_class"]={ | ||
[ | [e]="receiver A for class message is a forward declaration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="receiver %0 for class message is a forward declaration", | ||
[ | [b]=n, | ||
[ | [j]="receiver (.*?) for class message is a forward declaration", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{M,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 // Find the method we are messaging.\n if (!Method) {\n if (RequireCompleteType(Loc, Context.getObjCInterfaceType(Class), (getLangOpts().ObjCAutoRefCount ? diag::err_arc_receiver_forward_class : diag::warn_receiver_forward_class), TypeRange)) {"}}, | ||
[o]={ | [o]={ | ||
[ | [Cb]={"clang/test/SemaObjC/arc.m:427:4: error: receiver \'Test17\' for class message is a forward declaration"} | ||
} | } | ||
}, | }, | ||
["err_arc_receiver_forward_instance"]={ | ["err_arc_receiver_forward_instance"]={ | ||
[ | [e]="receiver type A for instance message is a forward declaration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="receiver type %0 for instance message is a forward declaration", | ||
[ | [b]=n, | ||
[ | [j]="receiver type (.*?) for instance message is a forward declaration", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={N,1308178962,z,z}, | ||
[k]={{ | [k]={{M,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 if (!Method) {\n if (receiverIsIdLike || ReceiverType->isBlockPointerType() || (Receiver && Context.isObjCNSObjectType(Receiver->getType()))) {\n } else if (ReceiverType->isObjCClassOrClassKindOfType() || ReceiverType->isObjCQualifiedClassType()) {\n } else {\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 } else if (const ObjCObjectPointerType *OCIType = ReceiverType->getAsObjCInterfacePointerType()) {\n if (RequireCompleteType(Loc, OCIType->getPointeeType(), getLangOpts().ObjCAutoRefCount ? diag::err_arc_receiver_forward_instance : diag::warn_receiver_forward_instance, RecRange)) {"}}, | ||
[o]={ | [o]={ | ||
[ | [Cb]={"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"]={ | ["err_arc_strong_property_ownership"]={ | ||
[ | [e]="existing instance variable A for strong property B may not be ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="existing instance variable %1 for strong property %0 may not be %select{|__unsafe_unretained||__weak}2", | ||
[ | [b]=n, | ||
[ | [j]="existing instance variable (.*?) for strong property (.*?) may not be (?:|__unsafe_unretained||__weak)", | ||
[ | [c]=a, | ||
[ | [i]="ARC and @properties", | ||
[ | [g]={ob,1308874139,mb,nb}, | ||
[k]={{ | [k]={{kb,207,"class PropertiesRewriter {\n void removeAssignForDefaultStrong(PropsTy &props, SourceLocation atLoc) const {\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());"},{kb,236,"class PropertiesRewriter {\n void rewriteAssign(PropsTy &props, SourceLocation atLoc) const {\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());"},{kb,261,"class PropertiesRewriter {\n void maybeAddWeakOrUnsafeUnretainedAttr(PropsTy &props, SourceLocation atLoc) const {\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());"},{Y,764,"static void checkARCPropertyImpl(Sema &S, SourceLocation propertyImplLoc, ObjCPropertyDecl *property, ObjCIvarDecl *ivar) {\n case Qualifiers::OCL_Strong:\n S.Diag(ivar->getLocation(), diag::err_arc_strong_property_ownership) << property->getDeclName() << ivar->getDeclName() << ivarLifetime;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,938: | Line 1,958: | ||
}, | }, | ||
["err_arc_thread_ownership"]={ | ["err_arc_thread_ownership"]={ | ||
[ | [e]="thread-local variable has non-trivial ownership: type is A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="thread-local variable has non-trivial ownership: type is %0", | ||
[ | [b]=n, | ||
[ | [j]="thread\\-local variable has non\\-trivial ownership\\: type is (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=Q, | ||
[ | [g]={ob,1308874139,mb,nb}, | ||
[k]={{ | [k]={{s,6893,"bool Sema::inferObjCARCLifetime(ValueDecl *decl) {\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();"}}, | ||
[o]={ | [o]={ | ||
[ | [Cb]={"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"]={ | ["err_arc_typecheck_convert_incompatible_pointer"]={ | ||
[ | [e]="incompatible pointer types passing retainable parameter of type Ato a CF function expecting B type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="incompatible pointer types passing retainable parameter of type %0to a CF function expecting %1 type", | ||
[ | [b]=n, | ||
[ | [j]="incompatible pointer types passing retainable parameter of type (.*?)to a CF function expecting (.*?) type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3a25d0d59395",1375312774,"ObjectiveC ARC: finishing off issuing error when","ObjectiveC ARC: finishing off issuing error when"}, | ||
[k]={{ | [k]={{A,17563,"bool Sema::DiagnoseAssignmentResult(AssignConvertType ConvTy, SourceLocation Loc, QualType DstType, QualType SrcType, Expr *SrcExpr, AssignmentAction Action, bool *Complained) {\n case IncompatiblePointer:\n if (Action == AA_Passing_CFAudited) {\n DiagKind = diag::err_arc_typecheck_convert_incompatible_pointer;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 1,968: | Line 1,988: | ||
}, | }, | ||
["err_arc_unsupported_on_runtime"]={ | ["err_arc_unsupported_on_runtime"]={ | ||
[e]="-fobjc-arc is not supported on platforms using the legacy runtime", | |||
[d]=l, | |||
[f]=m, | |||
[h]="-fobjc-arc is not supported on platforms using the legacy runtime", | [h]="-fobjc-arc is not supported on platforms using the legacy runtime", | ||
[ | [b]=n, | ||
[ | [j]="\\-fobjc\\-arc is not supported on platforms using the legacy runtime", | ||
[c]=a, | |||
[i]=a, | |||
[g]={"3deb1ad40ca6",1345517263,"Screw around with ObjCRuntime some more, changing the","Screw around with ObjCRuntime some more, changing the"}, | |||
[ | [k]={{V,3665,"#include \"clang/Driver/Options.inc\"\n if (Opts.ObjC) {\n if (Args.hasArg(OPT_fobjc_gc_only))\n else if (Args.hasArg(OPT_fobjc_gc))\n else if (Args.hasArg(OPT_fobjc_arc)) {\n if (!Opts.ObjCRuntime.allowsARC())\n Diags.Report(diag::err_arc_unsupported_on_runtime);"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_arc_unsupported_on_toolchain"]={ | ["err_arc_unsupported_on_toolchain"]={ | ||
[e]="-fobjc-arc is not supported on versions of OS X prior to 10.6", | |||
[d]=l, | |||
[f]=m, | |||
[h]="-fobjc-arc is not supported on versions of OS X prior to 10.6", | [h]="-fobjc-arc is not supported on versions of OS X prior to 10.6", | ||
[ | [b]=n, | ||
[ | [j]="\\-fobjc\\-arc is not supported on versions of OS X prior to 10\\.6", | ||
[c]=a, | |||
[i]=a, | |||
[g]={"3deb1ad40ca6",1345517263,"Screw around with ObjCRuntime some more, changing the","Screw around with ObjCRuntime some more, changing the"}, | |||
[ | |||
[ | |||
[ | |||
[k]={{"clang/lib/Driver/ToolChains/Darwin.cpp",3295,"void Darwin::CheckObjCARC() const {\n getDriver().Diag(diag::err_arc_unsupported_on_toolchain);"}} | [k]={{"clang/lib/Driver/ToolChains/Darwin.cpp",3295,"void Darwin::CheckObjCARC() const {\n getDriver().Diag(diag::err_arc_unsupported_on_toolchain);"}} | ||
}, | }, | ||
["err_arc_unsupported_weak_class"]={ | ["err_arc_unsupported_weak_class"]={ | ||
[e]="class is incompatible with __weak references", | |||
[d]=l, | |||
[f]=m, | |||
[h]="class is incompatible with __weak references", | [h]="class is incompatible with __weak references", | ||
[ | [b]=n, | ||
[ | [j]="class is incompatible with __weak references", | ||
[c]=a, | |||
[ | [i]=ec, | ||
[g]={"1f626d6fd1ca",1309980245,"objc-arc: Support objc_arc_weak_unavailable on those","objc-arc: Support objc_arc_weak_unavailable on those"}, | |||
[k]={{"clang/lib/ARCMigrate/TransGCAttrs.cpp",211,"static void checkWeakGCAttrs(MigrationContext &MigrateCtx) {\n for (unsigned i = 0, e = MigrateCtx.GCAttrs.size(); i != e; ++i) {\n if (Attr.Kind == MigrationContext::GCAttrOccurrence::Weak) {\n if (!canApplyWeak(MigrateCtx.Pass.Ctx, Attr.ModifiedType,\n TA.clearDiagnostic(diag::err_arc_weak_no_runtime, diag::err_arc_unsupported_weak_class, Attr.Loc);"},{t,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 // 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);"}}, | |||
[ | |||
[ | |||
[k]={{"clang/lib/ARCMigrate/TransGCAttrs.cpp",211,"static void checkWeakGCAttrs(MigrationContext &MigrateCtx) {\n for (unsigned i = 0, e = MigrateCtx.GCAttrs.size(); i != e; ++i) {\n if (Attr.Kind == MigrationContext::GCAttrOccurrence::Weak) {\n if (!canApplyWeak(MigrateCtx.Pass.Ctx, Attr.ModifiedType,\n TA.clearDiagnostic(diag::err_arc_weak_no_runtime, diag::err_arc_unsupported_weak_class, Attr.Loc);"},{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,007: | Line 2,027: | ||
}, | }, | ||
["err_arc_unused_init_message"]={ | ["err_arc_unused_init_message"]={ | ||
[e]="the result of a delegate init call must be immediately returned or assigned to \'self\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="the result of a delegate init call must be immediately returned or assigned to \'self\'", | [h]="the result of a delegate init call must be immediately returned or assigned to \'self\'", | ||
[ | [b]=n, | ||
[ | [j]="the result of a delegate init call must be immediately returned or assigned to \'self\'", | ||
[c]=a, | |||
[ | [i]=zb, | ||
[g]={N,1308178962,z,z}, | |||
[k]={{"clang/lib/ARCMigrate/TransUnusedInitDelegate.cpp",53,"class UnusedInitRewriter : public RecursiveASTVisitor<UnusedInitRewriter> {\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 bool VisitObjCMessageExpr(ObjCMessageExpr *ME) {\n if (ME->isDelegateInitCall() && isRemovable(ME) && Pass.TA.hasDiagnostic(diag::err_arc_unused_init_message, ME->getExprLoc())) {\n Pass.TA.clearDiagnostic(diag::err_arc_unused_init_message, ME->getExprLoc());"},{bb,328,"void Sema::DiagnoseUnusedExprResult(const Stmt *S, unsigned DiagID) {\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;"}}, | |||
[ | |||
[ | |||
[k]={{"clang/lib/ARCMigrate/TransUnusedInitDelegate.cpp",53,"class UnusedInitRewriter : public RecursiveASTVisitor<UnusedInitRewriter> {\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 bool VisitObjCMessageExpr(ObjCMessageExpr *ME) {\n if (ME->isDelegateInitCall() && isRemovable(ME) && Pass.TA.hasDiagnostic(diag::err_arc_unused_init_message, ME->getExprLoc())) {\n Pass.TA.clearDiagnostic(diag::err_arc_unused_init_message, ME->getExprLoc());"},{ | |||
[o]={ | [o]={ | ||
[ | [Cb]={"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"]={ | ["err_arc_weak_disabled"]={ | ||
[e]="cannot create __weak reference in file using manual reference counting", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot create __weak reference in file using manual reference counting", | [h]="cannot create __weak reference in file using manual reference counting", | ||
[ | [b]=n, | ||
[ | [j]="cannot create __weak reference in file using manual reference counting", | ||
[c]=a, | |||
[ | [i]=ec, | ||
[g]={"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."}, | |||
[k]={{q,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 // 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) {"},{O,3794,"/// Diagnose attempts to define ARC-__weak ivars when __weak is disabled.\nstatic void DiagnoseWeakIvars(Sema &S, ObjCImplementationDecl *ID) {\n for (auto ivar = ID->getClassInterface()->all_declared_ivar_begin(); ivar; ivar = ivar->getNextIvar()) {\n if (ivar->getType().getObjCLifetime() == Qualifiers::OCL_Weak) {\n if (S.getLangOpts().ObjCWeakRuntime) {\n S.Diag(ivar->getLocation(), diag::err_arc_weak_disabled);"},{t,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 // Sometimes, __weak isn\'t allowed.\n if (lifetime == Qualifiers::OCL_Weak && !S.getLangOpts().ObjCWeak && !NonObjCPointer) {\n unsigned diagnostic = (S.getLangOpts().ObjCWeakRuntime ? diag::err_arc_weak_disabled : diag::err_arc_weak_no_runtime);"}}, | |||
[ | |||
[ | |||
[k]={{q,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 // 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) {"},{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,037: | Line 2,057: | ||
}, | }, | ||
["err_arc_weak_ivar_access"]={ | ["err_arc_weak_ivar_access"]={ | ||
[e]="dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first", | |||
[d]=l, | |||
[f]=m, | |||
[h]="dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first", | [h]="dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first", | ||
[ | [b]=n, | ||
[ | [j]="dereferencing a __weak pointer is not allowed due to possible null value caused by race condition, assign it to strong variable first", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={Xb,1480718311,gb,gb}, | |||
[ | |||
[ | |||
[k]={{"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 // Handle ivar access to Objective-C objects.\n if (const ObjCObjectType *OTy = BaseType->getAs<ObjCObjectType>()) {\n if (S.getLangOpts().ObjCWeak) {\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);"}}, | [k]={{"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 // Handle ivar access to Objective-C objects.\n if (const ObjCObjectType *OTy = BaseType->getAs<ObjCObjectType>()) {\n if (S.getLangOpts().ObjCWeak) {\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);"}}, | ||
[o]={ | [o]={ | ||
Line 2,052: | Line 2,072: | ||
}, | }, | ||
["err_arc_weak_no_runtime"]={ | ["err_arc_weak_no_runtime"]={ | ||
[e]="cannot create __weak reference because the current deployment target does not support weak references", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot create __weak reference because the current deployment target does not support weak references", | [h]="cannot create __weak reference because the current deployment target does not support weak references", | ||
[ | [b]=n, | ||
[ | [j]="cannot create __weak reference because the current deployment target does not support weak references", | ||
[c]=a, | |||
[ | [i]=ec, | ||
[g]={N,1308178962,z,z}, | |||
[k]={{"clang/lib/ARCMigrate/TransGCAttrs.cpp",210,"static void checkWeakGCAttrs(MigrationContext &MigrateCtx) {\n for (unsigned i = 0, e = MigrateCtx.GCAttrs.size(); i != e; ++i) {\n if (Attr.Kind == MigrationContext::GCAttrOccurrence::Weak) {\n if (!canApplyWeak(MigrateCtx.Pass.Ctx, Attr.ModifiedType,\n TA.clearDiagnostic(diag::err_arc_weak_no_runtime, diag::err_arc_unsupported_weak_class, Attr.Loc);"},{q,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 // 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) {"},{O,3796,"/// Diagnose attempts to define ARC-__weak ivars when __weak is disabled.\nstatic void DiagnoseWeakIvars(Sema &S, ObjCImplementationDecl *ID) {\n for (auto ivar = ID->getClassInterface()->all_declared_ivar_begin(); ivar; ivar = ivar->getNextIvar()) {\n if (ivar->getType().getObjCLifetime() == Qualifiers::OCL_Weak) {\n if (S.getLangOpts().ObjCWeakRuntime) {\n } else {\n S.Diag(ivar->getLocation(), diag::err_arc_weak_no_runtime);"},{t,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 // Sometimes, __weak isn\'t allowed.\n if (lifetime == Qualifiers::OCL_Weak && !S.getLangOpts().ObjCWeak && !NonObjCPointer) {\n unsigned diagnostic = (S.getLangOpts().ObjCWeakRuntime ? diag::err_arc_weak_disabled : diag::err_arc_weak_no_runtime);"}}, | |||
[ | |||
[ | |||
[k]={{"clang/lib/ARCMigrate/TransGCAttrs.cpp",210,"static void checkWeakGCAttrs(MigrationContext &MigrateCtx) {\n for (unsigned i = 0, e = MigrateCtx.GCAttrs.size(); i != e; ++i) {\n if (Attr.Kind == MigrationContext::GCAttrOccurrence::Weak) {\n if (!canApplyWeak(MigrateCtx.Pass.Ctx, Attr.ModifiedType,\n TA.clearDiagnostic(diag::err_arc_weak_no_runtime, diag::err_arc_unsupported_weak_class, Attr.Loc);"},{q,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 // 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) {"},{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,067: | Line 2,087: | ||
}, | }, | ||
["err_arc_weak_unavailable_assign"]={ | ["err_arc_weak_unavailable_assign"]={ | ||
[e]="assignment of a weak-unavailable object to a __weak object", | |||
[d]=l, | |||
[f]=m, | |||
[h]="assignment of a weak-unavailable object to a __weak object", | [h]="assignment of a weak-unavailable object to a __weak object", | ||
[ | [b]=n, | ||
[ | [j]="assignment of a weak\\-unavailable object to a __weak object", | ||
[c]=a, | |||
[i]=ec, | |||
[g]={"6f472e803bf8",1310064947,"objc-arc: diagnose assignment/cast of a weak-unavailable","objc-arc: diagnose assignment/cast of a weak-unavailable"}, | |||
[ | [k]={{A,17705,"bool Sema::DiagnoseAssignmentResult(AssignConvertType ConvTy, SourceLocation Loc, QualType DstType, QualType SrcType, Expr *SrcExpr, AssignmentAction Action, bool *Complained) {\n case IncompatibleObjCWeakRef:\n DiagKind = diag::err_arc_weak_unavailable_assign;"},{y,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 case ICK_Pointer_Conversion: {\n if (SCS.IncompatibleObjC && Action != AA_Casting) {\n } else if (getLangOpts().allowsNonTrivialObjCLifetimeQualifiers() && !CheckObjCARCUnavailableWeakConversion(ToType, From->getType())) {\n if (Action == AA_Initializing)\n Diag(From->getBeginLoc(), diag::err_arc_weak_unavailable_assign);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,082: | Line 2,102: | ||
}, | }, | ||
["err_arc_weak_unavailable_property"]={ | ["err_arc_weak_unavailable_property"]={ | ||
[ | [e]="synthesizing __weak instance variable of type A, which does not support weak references", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="synthesizing __weak instance variable of type %0, which does not support weak references", | ||
[ | [b]=n, | ||
[ | [j]="synthesizing __weak instance variable of type (.*?), which does not support weak references", | ||
[ | [c]=a, | ||
[ | [i]=ec, | ||
[ | [g]={"e283346d0bf4",1323460511,"objc-arc: diagnose synthesis of a \'weak unavailable\' property.","objc-arc: diagnose synthesis of a \'weak unavailable\' property."}, | ||
[k]={{ | [k]={{Y,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 // Check that we have a valid, previously declared ivar for @synthesize\n if (Synthesize) {\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 } else {\n if (!getLangOpts().ObjCWeak) {\n } else {\n if (const ObjCObjectPointerType *ObjT = PropertyIvarType->getAs<ObjCObjectPointerType>()) {\n if (ObjI && ObjI->isArcWeakrefUnavailable()) {\n Diag(property->getLocation(), diag::err_arc_weak_unavailable_property) << PropertyIvarType;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,097: | Line 2,117: | ||
}, | }, | ||
["err_arch_unsupported_isa"]={ | ["err_arch_unsupported_isa"]={ | ||
[ | [e]="architecture \'A\' does not support \'B\' execution mode", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="architecture \'%0\' does not support \'%1\' execution mode", | ||
[ | [b]=n, | ||
[ | [j]="architecture \'(.*?)\' does not support \'(.*?)\' execution mode", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"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."}, | ||
[k]={{"clang/lib/Driver/ToolChains/Arch/ARM.cpp",267,"void arm::setArchNameInTriple(const Driver &D, const ArgList &Args, types::ID InputType, llvm::Triple &Triple) {\n if (IsMProfile && ARMModeRequested) {\n if (MCPU.size())\n else\n D.Diag(diag::err_arch_unsupported_isa) << tools::arm::getARMArch(MArch, Triple) << \"ARM\";"}} | [k]={{"clang/lib/Driver/ToolChains/Arch/ARM.cpp",267,"void arm::setArchNameInTriple(const Driver &D, const ArgList &Args, types::ID InputType, llvm::Triple &Triple) {\n if (IsMProfile && ARMModeRequested) {\n if (MCPU.size())\n else\n D.Diag(diag::err_arch_unsupported_isa) << tools::arm::getARMArch(MArch, Triple) << \"ARM\";"}} | ||
}, | }, | ||
["err_arcmt_nsinvocation_ownership"]={ | ["err_arcmt_nsinvocation_ownership"]={ | ||
[ | [e]="NSInvocation\'s A is not safe to be used with an object with ownership other than __unsafe_unretained", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="NSInvocation\'s %0 is not safe to be used with an object with ownership other than __unsafe_unretained", | ||
[ | [b]=n, | ||
[ | [j]="NSInvocation\'s (.*?) is not safe to be used with an object with ownership other than __unsafe_unretained", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"42aa21222d37",1390712852,"ARCMigrate: Introduce proper diagnostics for TransformActions","ARCMigrate: Introduce proper diagnostics for TransformActions"}, | ||
[k]={{"clang/lib/ARCMigrate/TransAPIUses.cpp",79,"class APIChecker : public RecursiveASTVisitor<APIChecker> {\n bool VisitObjCMessageExpr(ObjCMessageExpr *E) {\n // NSInvocation.\n if (E->isInstanceMessage() && E->getReceiverInterface() && E->getReceiverInterface()->getName() == \"NSInvocation\") {\n if (pointee.getObjCLifetime() > Qualifiers::OCL_ExplicitNone)\n Pass.TA.report(parm->getBeginLoc(), diag::err_arcmt_nsinvocation_ownership, parm->getSourceRange()) << selName;"}}, | [k]={{"clang/lib/ARCMigrate/TransAPIUses.cpp",79,"class APIChecker : public RecursiveASTVisitor<APIChecker> {\n bool VisitObjCMessageExpr(ObjCMessageExpr *E) {\n // NSInvocation.\n if (E->isInstanceMessage() && E->getReceiverInterface() && E->getReceiverInterface()->getName() == \"NSInvocation\") {\n if (pointee.getObjCLifetime() > Qualifiers::OCL_ExplicitNone)\n Pass.TA.report(parm->getBeginLoc(), diag::err_arcmt_nsinvocation_ownership, parm->getSourceRange()) << selName;"}}, | ||
[o]={ | [o]={ | ||
Line 2,124: | Line 2,144: | ||
}, | }, | ||
["err_arg_with_address_space"]={ | ["err_arg_with_address_space"]={ | ||
[e]="parameter may not be qualified with an address space", | |||
[d]=l, | |||
[f]=m, | |||
[h]="parameter may not be qualified with an address space", | [h]="parameter may not be qualified with an address space", | ||
[ | [b]=n, | ||
[ | [j]="parameter may not be qualified with an address space", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"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."}, | |||
[k]={{s,14958,"ParmVarDecl *Sema::CheckParameter(DeclContext *DC, SourceLocation StartLoc, SourceLocation NameLoc, IdentifierInfo *Name, QualType T, TypeSourceInfo *TSInfo, StorageClass SC) {\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(NameLoc, diag::err_arg_with_address_space);"},{O,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);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,139: | Line 2,159: | ||
}, | }, | ||
["err_argument_invalid_range"]={ | ["err_argument_invalid_range"]={ | ||
[ | [e]="argument value A is outside the valid range [B, C]", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="argument value %0 is outside the valid range [%1, %2]", | ||
[ | [b]=n, | ||
[ | [j]="argument value (.*?) is outside the valid range \\[(.*?), (.*?)\\]", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{u,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 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();"}}, | ||
[o]={ | [o]={ | ||
["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]"} | ["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]"} | ||
Line 2,154: | Line 2,174: | ||
}, | }, | ||
["err_argument_not_contiguous_bit_field"]={ | ["err_argument_not_contiguous_bit_field"]={ | ||
[ | [e]="argument A value should represent a contiguous bit field", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="argument %0 value should represent a contiguous bit field", | ||
[ | [b]=n, | ||
[ | [j]="argument (.*?) value should represent a contiguous bit field", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={hc,1615397021,lb,lb}, | ||
[k]={{ | [k]={{u,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 return Diag(TheCall->getBeginLoc(), diag::err_argument_not_contiguous_bit_field) << ArgNum << Arg->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,169: | Line 2,189: | ||
}, | }, | ||
["err_argument_not_multiple"]={ | ["err_argument_not_multiple"]={ | ||
[ | [e]="argument should be a multiple of A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="argument should be a multiple of %0", | ||
[ | [b]=n, | ||
[ | [j]="argument should be a multiple of (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"1f90f2d33f72",1476899452,"[mips][msa] Range check MSA intrinsics with immediates","[mips][msa] Range check MSA intrinsics with immediates"}, | ||
[k]={{ | [k]={{u,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 if (Result.getSExtValue() % Num != 0)\n return Diag(TheCall->getBeginLoc(), diag::err_argument_not_multiple) << Num << Arg->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,184: | Line 2,204: | ||
}, | }, | ||
["err_argument_not_power_of_2"]={ | ["err_argument_not_power_of_2"]={ | ||
[e]="argument should be a power of 2", | |||
[d]=l, | |||
[f]=m, | |||
[h]="argument should be a power of 2", | [h]="argument should be a power of 2", | ||
[ | [b]=n, | ||
[ | [j]="argument should be a power of 2", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"08074cc96557",1567435850,Lb,Lb}, | |||
[ | [k]={{u,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 return Diag(TheCall->getBeginLoc(), diag::err_argument_not_power_of_2) << Arg->getSourceRange();"}}, | ||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,199: | Line 2,219: | ||
}, | }, | ||
["err_argument_not_shifted_byte"]={ | ["err_argument_not_shifted_byte"]={ | ||
[e]="argument should be an 8-bit value shifted by a multiple of 8 bits", | |||
[d]=l, | |||
[f]=m, | |||
[h]="argument should be an 8-bit value shifted by a multiple of 8 bits", | [h]="argument should be an 8-bit value shifted by a multiple of 8 bits", | ||
[ | [b]=n, | ||
[ | [j]="argument should be an 8\\-bit value shifted by a multiple of 8 bits", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"08074cc96557",1567435850,Lb,Lb}, | |||
[ | [k]={{u,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 return Diag(TheCall->getBeginLoc(), diag::err_argument_not_shifted_byte) << Arg->getSourceRange();"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,214: | Line 2,234: | ||
}, | }, | ||
["err_argument_not_shifted_byte_or_xxff"]={ | ["err_argument_not_shifted_byte_or_xxff"]={ | ||
[e]="argument should be an 8-bit value shifted by a multiple of 8 bits, or in the form 0x??FF", | |||
[d]=l, | |||
[f]=m, | |||
[h]="argument should be an 8-bit value shifted by a multiple of 8 bits, or in the form 0x??FF", | [h]="argument should be an 8-bit value shifted by a multiple of 8 bits, or in the form 0x??FF", | ||
[ | [b]=n, | ||
[ | [j]="argument should be an 8\\-bit value shifted by a multiple of 8 bits, or in the form 0x\\?\\?FF", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"08074cc96557",1567435850,Lb,Lb}, | |||
[ | [k]={{u,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 return Diag(TheCall->getBeginLoc(), diag::err_argument_not_shifted_byte_or_xxff) << Arg->getSourceRange();"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,229: | Line 2,249: | ||
}, | }, | ||
["err_argument_required_after_attribute"]={ | ["err_argument_required_after_attribute"]={ | ||
[e]="argument required after attribute", | |||
[d]=l, | |||
[f]=m, | |||
[h]="argument required after attribute", | [h]="argument required after attribute", | ||
[ | [b]=n, | ||
[ | [j]="argument required after attribute", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={E,1236199783,F,C}, | |||
[k]={{H,1569,"void Parser::ParseSwiftNewTypeAttribute(IdentifierInfo &AttrName, SourceLocation AttrNameLoc, ParsedAttributes &Attrs, SourceLocation *EndLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n if (Tok.is(tok::r_paren)) {\n Diag(Tok.getLocation(), diag::err_argument_required_after_attribute);"},{H,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 if (isFunctionDeclaratorIdentifierList()) {\n if (RequiresArg)\n Diag(Tok, diag::err_argument_required_after_attribute);"},{H,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 if (isFunctionDeclaratorIdentifierList()) {\n } else {\n if (Tok.isNot(tok::r_paren))\n else if (RequiresArg)\n Diag(Tok, diag::err_argument_required_after_attribute);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/attr-swift_newtype.m"]={"clang/test/SemaObjC/attr-swift_newtype.m:5:47: error: argument required after attribute"} | ["clang/test/SemaObjC/attr-swift_newtype.m"]={"clang/test/SemaObjC/attr-swift_newtype.m:5:47: error: argument required after attribute"} | ||
Line 2,244: | Line 2,264: | ||
}, | }, | ||
["err_arithmetic_nonfragile_interface"]={ | ["err_arithmetic_nonfragile_interface"]={ | ||
[ | [e]="arithmetic on pointer to interface A, which is not a constant size for this architecture and platform", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="arithmetic on pointer to interface %0, which is not a constant size for this architecture and platform", | ||
[ | [b]=n, | ||
[ | [j]="arithmetic on pointer to interface (.*?), which is not a constant size for this architecture and platform", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{ | [k]={{A,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 S.Diag(opLoc, diag::err_arithmetic_nonfragile_interface) << op->getType()->castAs<ObjCObjectPointerType>()->getPointeeType() << op->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,259: | Line 2,279: | ||
}, | }, | ||
["err_arm_invalid_coproc"]={ | ["err_arm_invalid_coproc"]={ | ||
[ | [e]="coprocessor A must be configured as ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="coprocessor %0 must be configured as %select{GCP|CDE}1", | ||
[ | [b]=n, | ||
[ | [j]="coprocessor (.*?) must be configured as (?:GCP|CDE)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={ib,1576908663,K,K}, | ||
[k]={{ | [k]={{u,3142,"bool Sema::CheckARMCoprocessorImmediate(const TargetInfo &TI, const Expr *CoprocArg, bool WantCDE) {\n if (IsCDECoproc != WantCDE)\n return Diag(CoprocArg->getBeginLoc(), diag::err_arm_invalid_coproc) << (int)CoprocNo << (int)WantCDE << CoprocArg->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,274: | Line 2,294: | ||
}, | }, | ||
["err_arm_invalid_specialreg"]={ | ["err_arm_invalid_specialreg"]={ | ||
[e]="invalid special register for builtin", | |||
[d]=l, | |||
[f]=m, | |||
[h]="invalid special register for builtin", | [h]="invalid special register for builtin", | ||
[ | [b]=n, | ||
[ | [j]="invalid special register for builtin", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"59b2d8390941",1434390661,"This patch implements clang support for the ACLE special register intrinsics","This patch implements clang support for the ACLE special register intrinsics"}, | |||
[k]={{u,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 if (Fields.size() != ExpectedFieldNum && !(AllowName && Fields.size() == 1))\n return Diag(TheCall->getBeginLoc(), diag::err_arm_invalid_specialreg) << Arg->getSourceRange();"},{u,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 // 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 if (!ValidString)\n return Diag(TheCall->getBeginLoc(), diag::err_arm_invalid_specialreg) << Arg->getSourceRange();"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,289: | Line 2,309: | ||
}, | }, | ||
["err_array_designator_empty_range"]={ | ["err_array_designator_empty_range"]={ | ||
[ | [e]="array designator range [A, B] is empty", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array designator range [%0, %1] is empty", | ||
[ | [b]=n, | ||
[ | [j]="array designator range \\[(.*?), (.*?)\\] is empty", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{L,3400,"ExprResult Sema::ActOnDesignatedInitializer(Designation &Desig, SourceLocation EqualOrColonLoc, bool GNUSyntax, ExprResult Init) {\n // Build designators and check array designator expressions.\n for (unsigned Idx = 0; Idx < Desig.getNumDesignators(); ++Idx) {\n if (D.isFieldDesignator()) {\n } else if (D.isArrayDesignator()) {\n } else if (D.isArrayRangeDesignator()) {\n if (!StartIndex || !EndIndex)\n else {\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();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:11:7: error: array designator range [8, 7] is empty"} | ["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:11:7: error: array designator range [8, 7] is empty"} | ||
Line 2,304: | Line 2,324: | ||
}, | }, | ||
["err_array_designator_negative"]={ | ["err_array_designator_negative"]={ | ||
[ | [e]="array designator value \'A\' is negative", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array designator value \'%0\' is negative", | ||
[ | [b]=n, | ||
[ | [j]="array designator value \'(.*?)\' is negative", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{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 if (Value.isSigned() && Value.isNegative())\n return S.Diag(Loc, diag::err_array_designator_negative) << toString(Value, 10) << Index->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:13:4: error: array designator value \'-1\' is negative"} | ["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:13:4: error: array designator value \'-1\' is negative"} | ||
Line 2,319: | Line 2,339: | ||
}, | }, | ||
["err_array_designator_non_array"]={ | ["err_array_designator_non_array"]={ | ||
[ | [e]="array designator cannot initialize non-array type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array designator cannot initialize non-array type %0", | ||
[ | [b]=n, | ||
[ | [j]="array designator cannot initialize non\\-array type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{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 if (!AT) {\n if (!VerifyOnly)\n SemaRef.Diag(D->getLBracketLoc(), diag::err_array_designator_non_array) << CurrentObjectType;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:37:3: error: array designator cannot initialize non-array type \'struct point\'"} | ["clang/test/Sema/designated-initializers.c"]={"clang/test/Sema/designated-initializers.c:37:3: error: array designator cannot initialize non-array type \'struct point\'"} | ||
Line 2,334: | Line 2,354: | ||
}, | }, | ||
["err_array_designator_too_large"]={ | ["err_array_designator_too_large"]={ | ||
[ | [e]="array designator index (A) exceeds array bounds (B)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array designator index (%0) exceeds array bounds (%1)", | ||
[ | [b]=n, | ||
[ | [j]="array designator index \\((.*?)\\) exceeds array bounds \\((.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{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 if (isa<ConstantArrayType>(AT)) {\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();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 2,349: | Line 2,369: | ||
}, | }, | ||
["err_array_element_alignment"]={ | ["err_array_element_alignment"]={ | ||
[ | [e]="size of array element of type A (B bytes) isn\'t a multiple of its alignment (C bytes)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="size of array element of type %0 (%1 bytes) isn\'t a multiple of its alignment (%2 bytes)", | ||
[ | [b]=n, | ||
[ | [j]="size of array element of type (.*?) \\((.*?) bytes\\) isn\'t a multiple of its alignment \\((.*?) bytes\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{ | [k]={{t,2448,"bool Sema::checkArrayElementAlignment(QualType EltTy, SourceLocation Loc) {\n Diag(Loc, diag::err_array_element_alignment) << EltTy << Size.getQuantity() << Alignment.getQuantity();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 2,364: | Line 2,384: | ||
}, | }, | ||
["err_array_incomplete_or_sizeless_type"]={ | ["err_array_incomplete_or_sizeless_type"]={ | ||
[ | [e]="array has ... element type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array has %select{incomplete|sizeless}0 element type %1", | ||
[ | [b]=n, | ||
[ | [j]="array has (?:incomplete|sizeless) element type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={ib,1576908663,K,K}, | ||
[k]={{ | [k]={{s,13802,"void Sema::ActOnUninitializedDecl(Decl *RealDecl) {\n if (VarDecl *Var = dyn_cast<VarDecl>(RealDecl)) {\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))"},{A,7674,"ExprResult Sema::BuildCompoundLiteralExpr(SourceLocation LParenLoc, TypeSourceInfo *TInfo, SourceLocation RParenLoc, Expr *LiteralExpr) {\n if (literalType->isArrayType()) {\n if (RequireCompleteSizedType(LParenLoc, Context.getBaseElementType(literalType), diag::err_array_incomplete_or_sizeless_type, SourceRange(LParenLoc, LiteralExpr->getSourceRange().getEnd())))"},{t,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 if (getLangOpts().CPlusPlus) {\n if (T->isVoidType() || T->isIncompleteArrayType()) {\n Diag(Loc, diag::err_array_incomplete_or_sizeless_type) << 0 << T;"},{t,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 if (getLangOpts().CPlusPlus) {\n } else {\n if (!T.isWebAssemblyReferenceType() && RequireCompleteSizedType(Loc, T, diag::err_array_incomplete_or_sizeless_type))"},{t,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 if (T->isSizelessType() && !T.isWebAssemblyReferenceType()) {\n Diag(Loc, diag::err_array_incomplete_or_sizeless_type) << 1 << T;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Parser/typeof.c"]={"clang/test/Parser/typeof.c:13:11: error: array has incomplete element type \'void\'"} | ["clang/test/Parser/typeof.c"]={"clang/test/Parser/typeof.c:13:11: error: array has incomplete element type \'void\'"} | ||
Line 2,379: | Line 2,399: | ||
}, | }, | ||
["err_array_init_different_type"]={ | ["err_array_init_different_type"]={ | ||
[ | [e]="cannot initialize array of type A with array of type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot initialize array %diff{of type $ with array of type $|with different type of array}0,1", | ||
[ | [b]=n, | ||
[ | [j]="cannot initialize array (?:of type (.*?) with array of type (.*?)|with different type of array)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e2f943b5cb44",1298399391,"Implement the GNU C extension which permits the initialization of an","Implement the GNU C extension which permits the initialization of an"}, | ||
[k]={{ | [k]={{L,9611,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\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();"}}, | ||
[o]={ | [o]={ | ||
["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]\'"} | ["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]\'"} | ||
Line 2,394: | Line 2,414: | ||
}, | }, | ||
["err_array_init_incompat_wide_string_into_wchar"]={ | ["err_array_init_incompat_wide_string_into_wchar"]={ | ||
[e]="initializing wide char array with incompatible wide string literal", | |||
[d]=l, | |||
[f]=m, | |||
[h]="initializing wide char array with incompatible wide string literal", | [h]="initializing wide char array with incompatible wide string literal", | ||
[ | [b]=n, | ||
[ | [j]="initializing wide char array with incompatible wide string literal", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"8f62c5ca22f4",1368615784,Ub,Ub}, | |||
[k]={{L,9594,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n case FK_IncompatWideStringIntoWideChar:\n S.Diag(Kind.getLocation(), diag::err_array_init_incompat_wide_string_into_wchar);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,409: | Line 2,429: | ||
}, | }, | ||
["err_array_init_narrow_string_into_wchar"]={ | ["err_array_init_narrow_string_into_wchar"]={ | ||
[e]="initializing wide char array with non-wide string literal", | |||
[d]=l, | |||
[f]=m, | |||
[h]="initializing wide char array with non-wide string literal", | [h]="initializing wide char array with non-wide string literal", | ||
[ | [b]=n, | ||
[ | [j]="initializing wide char array with non\\-wide string literal", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"8f62c5ca22f4",1368615784,Ub,Ub}, | |||
[ | [k]={{L,9587,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n case FK_NarrowStringIntoWideCharArray:\n S.Diag(Kind.getLocation(), diag::err_array_init_narrow_string_into_wchar);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,424: | Line 2,444: | ||
}, | }, | ||
["err_array_init_non_constant_array"]={ | ["err_array_init_non_constant_array"]={ | ||
[ | [e]="cannot initialize array of type A with non-constant array of type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot initialize array %diff{of type $ with non-constant array of type $|with different type of array}0,1", | ||
[ | [b]=n, | ||
[ | [j]="cannot initialize array (?:of type (.*?) with non\\-constant array of type (.*?)|with different type of array)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e2f943b5cb44",1298399391,"Implement the GNU C extension which permits the initialization of an","Implement the GNU C extension which permits the initialization of an"}, | ||
[k]={{ | [k]={{L,9612,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\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"]={ | ["err_array_init_not_init_list"]={ | ||
[ | [e]="array initializer must be an initializer list...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array initializer must be an initializer list%select{| or string literal| or wide string literal}0", | ||
[ | [b]=n, | ||
[ | [j]="array initializer must be an initializer list(?:| or string literal| or wide string literal)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3e1e52782604",1260399737,"Reimplement reference initialization (C++ [dcl.init.ref]) using the","Reimplement reference initialization (C++ [dcl.init.ref]) using the"}, | ||
[k]={{ | [k]={{L,9578,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\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 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 case FK_ArrayNeedsInitListOrWideStringLiteral:\n S.Diag(Kind.getLocation(), diag::err_array_init_not_init_list) << 2;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,451: | Line 2,471: | ||
}, | }, | ||
["err_array_init_plain_string_into_char8_t"]={ | ["err_array_init_plain_string_into_char8_t"]={ | ||
[e]="initializing \'char8_t\' array with plain string literal", | |||
[d]=l, | |||
[f]=m, | |||
[h]="initializing \'char8_t\' array with plain string literal", | [h]="initializing \'char8_t\' array with plain string literal", | ||
[ | [b]=n, | ||
[ | [j]="initializing \'char8_t\' array with plain string literal", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"3a8244df6fb8",1525150965,"Implement P0482R2, support for char8_t type.","Implement P0482R2, support for char8_t type."}, | |||
[k]={{L,9598,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n case FK_PlainStringIntoUTF8Char:\n S.Diag(Kind.getLocation(), diag::err_array_init_plain_string_into_char8_t);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/char8_t.cpp"]={"clang/test/SemaCXX/char8_t.cpp:9:9: error: initializing \'char8_t\' array with plain string literal"} | ["clang/test/SemaCXX/char8_t.cpp"]={"clang/test/SemaCXX/char8_t.cpp:9:9: error: initializing \'char8_t\' array with plain string literal"} | ||
Line 2,466: | Line 2,486: | ||
}, | }, | ||
["err_array_init_utf8_string_into_char"]={ | ["err_array_init_utf8_string_into_char"]={ | ||
[ | [e]="initialization of ...char array with UTF-8 string literal is not permitted by ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="initialization of %select{|signed }0char array with UTF-8 string literal is not permitted by %select{\'-fchar8_t\'|C++20}1", | ||
[ | [b]=n, | ||
[ | [j]="initialization of (?:|signed )char array with UTF\\-8 string literal is not permitted by (?:\'\\-fchar8_t\'|C\\+\\+20)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3a8244df6fb8",1525150965,"Implement P0482R2, support for char8_t type.","Implement P0482R2, support for char8_t type."}, | ||
[k]={{ | [k]={{L,9604,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n case FK_UTF8StringIntoPlainChar:\n S.Diag(Kind.getLocation(), diag::err_array_init_utf8_string_into_char) << DestType->isSignedIntegerType() << S.getLangOpts().CPlusPlus20;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,481: | Line 2,501: | ||
}, | }, | ||
["err_array_init_wide_string_into_char"]={ | ["err_array_init_wide_string_into_char"]={ | ||
[e]="initializing char array with wide string literal", | |||
[d]=l, | |||
[f]=m, | |||
[h]="initializing char array with wide string literal", | [h]="initializing char array with wide string literal", | ||
[ | [b]=n, | ||
[ | [j]="initializing char array with wide string literal", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"8f62c5ca22f4",1368615784,Ub,Ub}, | |||
[k]={{L,9590,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n case FK_WideStringIntoCharArray:\n S.Diag(Kind.getLocation(), diag::err_array_init_wide_string_into_char);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,496: | Line 2,516: | ||
}, | }, | ||
["err_array_new_needs_size"]={ | ["err_array_new_needs_size"]={ | ||
[e]="array size must be specified in new expression with no initializer", | |||
[d]=l, | |||
[f]=m, | |||
[h]="array size must be specified in new expression with no initializer", | [h]="array size must be specified in new expression with no initializer", | ||
[ | [b]=n, | ||
[ | [j]="array size must be specified in new expression with no initializer", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[ | |||
[ | |||
[k]={{y,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 // 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 if (!Chunk.Arr.NumElts && !Initializer)\n return ExprError(Diag(Chunk.Loc, diag::err_array_new_needs_size) << D.getSourceRange());"}}, | [k]={{y,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 // 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 if (!Chunk.Arr.NumElts && !Initializer)\n return ExprError(Diag(Chunk.Loc, diag::err_array_new_needs_size) << D.getSourceRange());"}}, | ||
[o]={ | [o]={ | ||
Line 2,511: | Line 2,531: | ||
}, | }, | ||
["err_array_of_abstract_type"]={ | ["err_array_of_abstract_type"]={ | ||
[ | [e]="array of abstract class type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array of abstract class type %0", | ||
[ | [b]=n, | ||
[ | [j]="array of abstract class type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"7d8072e03860",1272397094,"Diagnose the use of abstract types as array element types. Previously,","Diagnose the use of abstract types as array element types. Previously,"}, | ||
[k]={{w,6095,"#include \"clang/AST/TypeLocNodes.def\"\n CheckPolymorphic(PointerTypeLoc) CheckPolymorphic(ReferenceTypeLoc) CheckPolymorphic(MemberPointerTypeLoc) CheckPolymorphic(BlockPointerTypeLoc) CheckPolymorphic(AtomicTypeLoc)\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();"},{ | [k]={{w,6095,"#include \"clang/AST/TypeLocNodes.def\"\n CheckPolymorphic(PointerTypeLoc) CheckPolymorphic(ReferenceTypeLoc) CheckPolymorphic(MemberPointerTypeLoc) CheckPolymorphic(BlockPointerTypeLoc) CheckPolymorphic(AtomicTypeLoc)\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();"},{t,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 if (getLangOpts().CPlusPlus) {\n if (RequireNonAbstractType(Brackets.getBegin(), T, diag::err_array_of_abstract_type))"}}, | ||
[o]={ | [o]={ | ||
["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>\')"} | ["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>\')"} | ||
Line 2,526: | Line 2,546: | ||
}, | }, | ||
["err_array_section_does_not_specify_contiguous_storage"]={ | ["err_array_section_does_not_specify_contiguous_storage"]={ | ||
[e]="array section does not specify contiguous storage", | |||
[d]=l, | |||
[f]=m, | |||
[h]="array section does not specify contiguous storage", | [h]="array section does not specify contiguous storage", | ||
[ | [b]=n, | ||
[ | [j]="array section does not specify contiguous storage", | ||
[c]=a, | |||
[ | [i]="OpenMP Issue", | ||
[g]={"a9f35cb7d665",1457538365,"[OpenMP] Add support for multidimensional array sections in map clause SEMA.","[OpenMP] Add support for multidimensional array sections in map clause SEMA."}, | |||
[ | |||
[ | |||
[k]={{"clang/lib/Sema/SemaOpenMP.cpp",21302,"class MapBaseChecker final : public StmtVisitor<MapBaseChecker, bool> {\n bool VisitOMPArraySectionExpr(OMPArraySectionExpr *OASE) {\n if (AllowWholeSizeArraySection) {\n } else if (DKind == OMPD_target_update && SemaRef.getLangOpts().OpenMP >= 50) {\n } else if (AllowUnitySizeArraySection && NotUnity) {\n SemaRef.Diag(ELoc, diag::err_array_section_does_not_specify_contiguous_storage) << OASE->getSourceRange();"}}, | [k]={{"clang/lib/Sema/SemaOpenMP.cpp",21302,"class MapBaseChecker final : public StmtVisitor<MapBaseChecker, bool> {\n bool VisitOMPArraySectionExpr(OMPArraySectionExpr *OASE) {\n if (AllowWholeSizeArraySection) {\n } else if (DKind == OMPD_target_update && SemaRef.getLangOpts().OpenMP >= 50) {\n } else if (AllowUnitySizeArraySection && NotUnity) {\n SemaRef.Diag(ELoc, diag::err_array_section_does_not_specify_contiguous_storage) << OASE->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 2,541: | Line 2,561: | ||
}, | }, | ||
["err_array_section_does_not_specify_length"]={ | ["err_array_section_does_not_specify_length"]={ | ||
[e]="array section does not specify length for outermost dimension", | |||
[d]=l, | |||
[f]=m, | |||
[h]="array section does not specify length for outermost dimension", | [h]="array section does not specify length for outermost dimension", | ||
[ | [b]=n, | ||
[ | [j]="array section does not specify length for outermost dimension", | ||
[c]=a, | |||
[ | [i]="OpenMP Issue", | ||
[g]={sb,1590001902,T,T}, | |||
[ | |||
[ | |||
[k]={{"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 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 for (; CI != CE; ++CI) {\n SemaRef.Diag(ELoc, diag::err_array_section_does_not_specify_length) << ERange;"}}, | [k]={{"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 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 for (; CI != CE; ++CI) {\n SemaRef.Diag(ELoc, diag::err_array_section_does_not_specify_length) << ERange;"}}, | ||
[o]={ | [o]={ | ||
Line 2,556: | Line 2,576: | ||
}, | }, | ||
["err_array_size_ambiguous_conversion"]={ | ["err_array_size_ambiguous_conversion"]={ | ||
[ | [e]="ambiguous conversion of array size expression of type A to an integral or enumeration type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="ambiguous conversion of array size expression of type %0 to an integral or enumeration type", | ||
[ | [b]=n, | ||
[ | [j]="ambiguous conversion of array size expression of type (.*?) to an integral or enumeration type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"4799d03ce841",1277857243,Mb,Mb}, | ||
[k]={{y,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 if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n if (getLangOpts().CPlusPlus14) {\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n SemaDiagnosticBuilder diagnoseAmbiguous(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_ambiguous_conversion) << T; }"}}, | [k]={{y,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 if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n if (getLangOpts().CPlusPlus14) {\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n SemaDiagnosticBuilder diagnoseAmbiguous(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_ambiguous_conversion) << T; }"}}, | ||
[o]={ | [o]={ | ||
Line 2,571: | Line 2,591: | ||
}, | }, | ||
["err_array_size_explicit_conversion"]={ | ["err_array_size_explicit_conversion"]={ | ||
[ | [e]="array size expression of type A requires explicit conversion to type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array size expression of type %0 requires explicit conversion to type %1", | ||
[ | [b]=n, | ||
[ | [j]="array size expression of type (.*?) requires explicit conversion to type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"4799d03ce841",1277857243,Mb,Mb}, | ||
[k]={{y,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 if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n if (getLangOpts().CPlusPlus14) {\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n SemaDiagnosticBuilder diagnoseExplicitConv(Sema &S, SourceLocation Loc, QualType T, QualType ConvTy) override { return S.Diag(Loc, diag::err_array_size_explicit_conversion) << T << ConvTy; }"}}, | [k]={{y,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 if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n if (getLangOpts().CPlusPlus14) {\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n SemaDiagnosticBuilder diagnoseExplicitConv(Sema &S, SourceLocation Loc, QualType T, QualType ConvTy) override { return S.Diag(Loc, diag::err_array_size_explicit_conversion) << T << ConvTy; }"}}, | ||
[o]={ | [o]={ | ||
Line 2,586: | Line 2,606: | ||
}, | }, | ||
["err_array_size_incomplete_type"]={ | ["err_array_size_incomplete_type"]={ | ||
[ | [e]="array size expression has incomplete class type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array size expression has incomplete class type %0", | ||
[ | [b]=n, | ||
[ | [j]="array size expression has incomplete class type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"4799d03ce841",1277857243,Mb,Mb}, | ||
[k]={{y,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 if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n if (getLangOpts().CPlusPlus14) {\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n SemaDiagnosticBuilder diagnoseIncomplete(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_incomplete_type) << T << ArraySize->getSourceRange(); }"}} | [k]={{y,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 if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n if (getLangOpts().CPlusPlus14) {\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\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"]={ | ["err_array_size_non_int"]={ | ||
[ | [e]="size of array has non-integer type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="size of array has non-integer type %0", | ||
[ | [b]=n, | ||
[ | [j]="size of array has non\\-integer type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{t,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 // 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 Sema::SemaDiagnosticBuilder diagnoseNotICEType(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_non_int) << T; }"},{t,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 // 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();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 2,613: | Line 2,633: | ||
}, | }, | ||
["err_array_size_not_integral"]={ | ["err_array_size_not_integral"]={ | ||
[ | [e]="array size expression must have integral or ...enumeration type, not A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array size expression must have integral or %select{|unscoped }0enumeration type, not %1", | ||
[ | [b]=n, | ||
[ | [j]="array size expression must have integral or (?:|unscoped )enumeration type, not (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{y,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 if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n if (getLangOpts().CPlusPlus14) {\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n SemaDiagnosticBuilder diagnoseNotInt(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_not_integral) << S.getLangOpts().CPlusPlus11 << T; }"}}, | [k]={{y,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 if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\n if (getLangOpts().CPlusPlus14) {\n } else {\n class SizeConvertDiagnoser : public ICEConvertDiagnoser {\n SemaDiagnosticBuilder diagnoseNotInt(Sema &S, SourceLocation Loc, QualType T) override { return S.Diag(Loc, diag::err_array_size_not_integral) << S.getLangOpts().CPlusPlus11 << T; }"}}, | ||
[o]={ | [o]={ | ||
Line 2,628: | Line 2,648: | ||
}, | }, | ||
["err_array_star_in_function_definition"]={ | ["err_array_star_in_function_definition"]={ | ||
[e]="variable length array must be bound in function definition", | |||
[d]=l, | |||
[f]=m, | |||
[h]="variable length array must be bound in function definition", | [h]="variable length array must be bound in function definition", | ||
[ | [b]=n, | ||
[ | [j]="variable length array must be bound in function definition", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"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."}, | |||
[k]={{u,16617,"static void diagnoseArrayStarInParamType(Sema &S, QualType PType, SourceLocation Loc) {\n S.Diag(Loc, diag::err_array_star_in_function_definition);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,643: | Line 2,663: | ||
}, | }, | ||
["err_array_star_outside_prototype"]={ | ["err_array_star_outside_prototype"]={ | ||
[e]="star modifier used outside of function prototype", | |||
[d]=l, | |||
[f]=m, | |||
[h]="star modifier used outside of function prototype", | [h]="star modifier used outside of function prototype", | ||
[ | [b]=n, | ||
[ | [j]="star modifier used outside of function prototype", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"4e2ab5550284",1240783071,"Add a bit more handling for declarations like \"int a[*]\".","Add a bit more handling for declarations like \"int a[*]\"."}, | |||
[k]={{t,5134,"static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, QualType declSpecType, TypeSourceInfo *TInfo) {\n for (unsigned i = 0, e = D.getNumTypeObjects(); i != e; ++i) {\n case DeclaratorChunk::Array: {\n if (ASM == ArrayType::Star && !D.isPrototypeContext()) {\n S.Diag(DeclType.Loc, diag::err_array_star_outside_prototype);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/vla.c"]={"clang/test/Sema/vla.c:47:6: error: star modifier used outside of function prototype"} | ["clang/test/Sema/vla.c"]={"clang/test/Sema/vla.c:47:6: error: star modifier used outside of function prototype"} | ||
Line 2,658: | Line 2,678: | ||
}, | }, | ||
["err_array_static_not_outermost"]={ | ["err_array_static_not_outermost"]={ | ||
[ | [e]="A used in non-outermost array type derivation", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 used in non-outermost array type derivation", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) used in non\\-outermost array type derivation", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"420052640f7c",1345016550,"Check for improper use of \'static\' and type qualifiers in array","Check for improper use of \'static\' and type qualifiers in array"}, | ||
[k]={{ | [k]={{t,5157,"static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, QualType declSpecType, TypeSourceInfo *TInfo) {\n for (unsigned i = 0, e = D.getNumTypeObjects(); i != e; ++i) {\n case DeclaratorChunk::Array: {\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 // 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\");"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,673: | Line 2,693: | ||
}, | }, | ||
["err_array_static_outside_prototype"]={ | ["err_array_static_outside_prototype"]={ | ||
[ | [e]="A used in array declarator outside of function prototype", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 used in array declarator outside of function prototype", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) used in array declarator outside of function prototype", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"420052640f7c",1345016550,"Check for improper use of \'static\' and type qualifiers in array","Check for improper use of \'static\' and type qualifiers in array"}, | ||
[k]={{ | [k]={{t,5145,"static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, QualType declSpecType, TypeSourceInfo *TInfo) {\n for (unsigned i = 0, e = D.getNumTypeObjects(); i != e; ++i) {\n case DeclaratorChunk::Array: {\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\");"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,688: | Line 2,708: | ||
}, | }, | ||
["err_array_too_large"]={ | ["err_array_too_large"]={ | ||
[ | [e]="array is too large (A elements)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="array is too large (%0 elements)", | ||
[ | [b]=n, | ||
[ | [j]="array is too large \\((.*?) elements\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{ | [k]={{s,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 if (SizeIsNegative)\n else if (Oversized.getBoolValue())\n Diag(Loc, diag::err_array_too_large) << toString(Oversized, 10);"},{s,6730,"void Sema::CheckTypedefForVariablyModifiedType(Scope *S, TypedefNameDecl *NewTD) {\n if (T->isVariablyModifiedType()) {\n if (S->getFnParent() == nullptr) {\n if (FixedTInfo) {\n } else {\n if (SizeIsNegative)\n else if (T->isVariableArrayType())\n else if (Oversized.getBoolValue())\n Diag(NewTD->getLocation(), diag::err_array_too_large) << toString(Oversized, 10);"},{y,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 if (ArraySize && *ArraySize && !(*ArraySize)->isTypeDependent()) {\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 if (!AllocType->isDependentType()) {\n if (ActiveSizeBits > ConstantArrayType::getMaxSizeBits(Context))\n return ExprError(Diag((*ArraySize)->getBeginLoc(), diag::err_array_too_large) << toString(*Value, 10) << (*ArraySize)->getSourceRange());"},{t,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 if (!ArraySize) {\n } else if (ArraySize->isTypeDependent() || ArraySize->isValueDependent()) {\n } else {\n if (!R.isUsable()) {\n } else if (!T->isDependentType() && !T->isIncompleteType() && !T->isConstantSizeType()) {\n } else {\n if (ActiveSizeBits > ConstantArrayType::getMaxSizeBits(Context)) {\n Diag(ArraySize->getBeginLoc(), diag::err_array_too_large) << toString(ConstVal, 10) << ArraySize->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/offsetof-64.c"]={"clang/test/Sema/offsetof-64.c:16:8: error: array is too large (1152921504606846976 elements)"} | ["clang/test/Sema/offsetof-64.c"]={"clang/test/Sema/offsetof-64.c:16:8: error: array is too large (1152921504606846976 elements)"} | ||
Line 2,703: | Line 2,723: | ||
}, | }, | ||
["err_as_qualified_auto_decl"]={ | ["err_as_qualified_auto_decl"]={ | ||
[ | [e]="automatic variable qualified with an... address space", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="automatic variable qualified with an%select{| invalid}0 address space", | ||
[ | [b]=n, | ||
[ | [j]="automatic variable qualified with an(?:| invalid) address space", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{s,8537,"void Sema::CheckVariableDeclarationType(VarDecl *NewVD) {\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;"},{s,8638,"void Sema::CheckVariableDeclarationType(VarDecl *NewVD) {\n if (getLangOpts().OpenCL) {\n // FIXME: Adding local AS in C++ for OpenCL might make sense.\n if (NewVD->isFileVarDecl() || NewVD->isStaticLocal() || NewVD->hasExternalStorage()) {\n } else {\n if (T.getAddressSpace() == LangAS::opencl_constant || T.getAddressSpace() == LangAS::opencl_local) {\n } else if (T.getAddressSpace() != LangAS::opencl_private &&\n Diag(NewVD->getLocation(), diag::err_as_qualified_auto_decl) << 1;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaHLSL/group_shared.hlsl"]={"clang/test/SemaHLSL/group_shared.hlsl:9:22: error: automatic variable qualified with an address space"} | ["clang/test/SemaHLSL/group_shared.hlsl"]={"clang/test/SemaHLSL/group_shared.hlsl:9:22: error: automatic variable qualified with an address space"} | ||
Line 2,718: | Line 2,738: | ||
}, | }, | ||
["err_asm_bad_register_type"]={ | ["err_asm_bad_register_type"]={ | ||
[e]="bad type for named register variable", | |||
[d]=l, | |||
[f]=m, | |||
[h]="bad type for named register variable", | [h]="bad type for named register variable", | ||
[ | [b]=n, | ||
[ | [j]="bad type for named register variable", | ||
[c]=a, | |||
[ | [i]=G, | ||
[g]={"2e31e4e47b09",1401986722,"Add pointer types to global named register","Add pointer types to global named register"}, | |||
[k]={{s,7969,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n if (S->getFnParent() != nullptr) {\n } else if (SC == SC_Register) {\n if (!R->isIntegralType(Context) && !R->isPointerType()) {\n Diag(D.getBeginLoc(), diag::err_asm_bad_register_type);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [W]={"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"]={ | ["err_asm_duplicate_qual"]={ | ||
[ | [e]="duplicate asm qualifier \'A\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="duplicate asm qualifier \'%0\'", | ||
[ | [b]=n, | ||
[ | [j]="duplicate asm qualifier \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"f08df464ae89",1582039343,"[OPENMP50]Add initial support for OpenMP 5.0 iterator.","[OPENMP50]Add initial support for OpenMP 5.0 iterator."}, | ||
[k]={{"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 if (AQ.setAsmQualifier(A))\n Diag(Tok.getLocation(), diag::err_asm_duplicate_qual) << GNUAsmQualifiers::getQualifierName(A);"}}, | [k]={{"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 if (AQ.setAsmQualifier(A))\n Diag(Tok.getLocation(), diag::err_asm_duplicate_qual) << GNUAsmQualifiers::getQualifierName(A);"}}, | ||
[o]={ | [o]={ | ||
Line 2,748: | Line 2,768: | ||
}, | }, | ||
["err_asm_empty"]={ | ["err_asm_empty"]={ | ||
[e]="__asm used with no assembly instructions", | |||
[d]=l, | |||
[f]=m, | |||
[h]="__asm used with no assembly instructions", | [h]="__asm used with no assembly instructions", | ||
[ | [b]=n, | ||
[ | [j]="__asm used with no assembly instructions", | ||
[c]=a, | |||
[ | [i]=G, | ||
[g]={"317be45091d7",1348516679,"Replace an assertion with an error for empty __asm statements.","Replace an assertion with an error for empty __asm statements."}, | |||
[ | |||
[ | |||
[k]={{"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 for (unsigned i = 0, e = AsmToks.size(); i < e; ++i) {\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);"}}, | [k]={{"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 for (unsigned i = 0, e = AsmToks.size(); i < e; ++i) {\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);"}}, | ||
[o]={ | [o]={ | ||
Line 2,763: | Line 2,783: | ||
}, | }, | ||
["err_asm_empty_symbolic_operand_name"]={ | ["err_asm_empty_symbolic_operand_name"]={ | ||
[e]="empty symbolic operand name in inline assembly string", | |||
[d]=l, | |||
[f]=m, | |||
[h]="empty symbolic operand name in inline assembly string", | [h]="empty symbolic operand name in inline assembly string", | ||
[ | [b]=n, | ||
[ | [j]="empty symbolic operand name in inline assembly string", | ||
[c]=a, | |||
[ | [i]=G, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{Eb,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 while (true) {\n // Handle operands that have asmSymbolicName (e.g., %x[foo]).\n if (EscapedChar == \'[\') {\n if (NameEnd == CurPtr)\n return diag::err_asm_empty_symbolic_operand_name;"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [W]={"clang/test/Sema/asm.c:81:10: error: empty symbolic operand name in inline assembly string"} | ||
} | } | ||
}, | }, | ||
["err_asm_incomplete_type"]={ | ["err_asm_incomplete_type"]={ | ||
[ | [e]="asm operand has incomplete type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="asm operand has incomplete type %0", | ||
[ | [b]=n, | ||
[ | [j]="asm operand has incomplete type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"f413f5ed44dd",1367539813,"Move parsing of identifiers in MS-style inline assembly into","Move parsing of identifiers in MS-style inline assembly into"}, | ||
[k]={{ | [k]={{J,816,"ExprResult Sema::LookupInlineAsmIdentifier(CXXScopeSpec &SS, SourceLocation TemplateKWLoc, UnqualifiedId &Id, bool IsUnevaluatedContext) {\n if (RequireCompleteExprType(Result.get(), diag::err_asm_incomplete_type)) {"},{J,864,"bool Sema::LookupInlineAsmField(StringRef Base, StringRef Member, unsigned &Offset, SourceLocation AsmLoc) {\n for (StringRef NextMember : Members) {\n if (RequireCompleteType(AsmLoc, QualType(RT, 0), diag::err_asm_incomplete_type))"}} | ||
}, | }, | ||
["err_asm_input_duplicate_match"]={ | ["err_asm_input_duplicate_match"]={ | ||
[ | [e]="more than one input constraint matches the same output \'A\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="more than one input constraint matches the same output \'%0\'", | ||
[ | [b]=n, | ||
[ | [j]="more than one input constraint matches the same output \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"8e261be91106",1442846460,"Fix assertion in inline assembler IR gen","Fix assertion in inline assembler IR gen"}, | ||
[k]={{ | [k]={{J,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 for (unsigned i = 0, e = InputConstraintInfos.size(); i != e; ++i) {\n if (InputMatchedToOutput[TiedTo] != ~0U) {\n targetDiag(NS->getInputExpr(i)->getBeginLoc(), diag::err_asm_input_duplicate_match) << TiedTo;"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"clang/test/Sema/asm.c:292:17: error: more than one input constraint matches the same output \'1\'"} | ||
} | } | ||
}, | }, | ||
["err_asm_invalid_escape"]={ | ["err_asm_invalid_escape"]={ | ||
[ | [e]="invalid % escape in inline assembly string", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid %% escape in inline assembly string", | ||
[ | [b]=n, | ||
[ | [j]="invalid % escape in inline assembly string", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{Eb,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 while (true) {\n // Escaped \"%\" character in asm string.\n if (CurPtr == StrEnd) {\n return diag::err_asm_invalid_escape;"},{Eb,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 while (true) {\n if (isLetter(EscapedChar)) {\n if (CurPtr == StrEnd) { // Premature end.\n return diag::err_asm_invalid_escape;"},{Eb,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 while (true) {\n return diag::err_asm_invalid_escape;"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"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"]={ | ["err_asm_invalid_global_var_reg"]={ | ||
[ | [e]="register \'A\' unsuitable for global register variables on this target", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="register \'%0\' unsuitable for global register variables on this target", | ||
[ | [b]=n, | ||
[ | [j]="register \'(.*?)\' unsuitable for global register variables on this target", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"8c26ea663d43",1447805728,"Produce a better diagnostic for global register variables.","Produce a better diagnostic for global register variables."}, | ||
[k]={{ | [k]={{s,7963,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n if (S->getFnParent() != nullptr) {\n } else if (SC == SC_Register) {\n // Global Named register\n if (DeclAttrsMatchCUDAMode(getLangOpts(), NewVD)) {\n if (!TI.isValidGCCRegisterName(Label))\n else if (!TI.validateGlobalRegisterVariable(Label, Context.getTypeSize(R), HasSizeMismatch))\n Diag(E->getExprLoc(), diag::err_asm_invalid_global_var_reg) << Label;"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"clang/test/Sema/asm.c:203:22: error: register \'edi\' unsuitable for global register variables on this target"} | ||
} | } | ||
}, | }, | ||
["err_asm_invalid_input_constraint"]={ | ["err_asm_invalid_input_constraint"]={ | ||
[ | [e]="invalid input constraint \'A\' in asm", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid input constraint \'%0\' in asm", | ||
[ | [b]=n, | ||
[ | [j]="invalid input constraint \'(.*?)\' in asm", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{J,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 for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n if (!Context.getTargetInfo().validateInputConstraint(OutputConstraintInfos, Info)) {\n targetDiag(Literal->getBeginLoc(), diag::err_asm_invalid_input_constraint) << Info.getConstraintStr();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,850: | Line 2,870: | ||
}, | }, | ||
["err_asm_invalid_input_size"]={ | ["err_asm_invalid_input_size"]={ | ||
[ | [e]="invalid input size for constraint \'A\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid input size for constraint \'%0\'", | ||
[ | [b]=n, | ||
[ | [j]="invalid input size for constraint \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"887b485dbe3d",1352702571,"Check that the input size is correct for the given constraint.","Check that the input size is correct for the given constraint."}, | ||
[k]={{ | [k]={{J,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 for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n if (!Context.getTargetInfo().validateInputSize(FeatureMap, Literal->getString(), Size))\n return targetDiag(InputExpr->getBeginLoc(), diag::err_asm_invalid_input_size) << Info.getConstraintStr();"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 2,865: | Line 2,885: | ||
}, | }, | ||
["err_asm_invalid_lvalue_in_input"]={ | ["err_asm_invalid_lvalue_in_input"]={ | ||
[ | [e]="invalid lvalue in asm input for constraint \'A\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid lvalue in asm input for constraint \'%0\'", | ||
[ | [b]=n, | ||
[ | [j]="invalid lvalue in asm input for constraint \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{J,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 for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\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());"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"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"]={ | ["err_asm_invalid_lvalue_in_output"]={ | ||
[e]="invalid lvalue in asm output", | |||
[d]=l, | |||
[f]=m, | |||
[h]="invalid lvalue in asm output", | [h]="invalid lvalue in asm output", | ||
[ | [b]=n, | ||
[ | [j]="invalid lvalue in asm output", | ||
[c]=a, | |||
[ | [i]=G, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{J,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 for (unsigned i = 0; i != NumOutputs; i++) {\n default:\n return StmtError(Diag(OutputExpr->getBeginLoc(), diag::err_asm_invalid_lvalue_in_output) << OutputExpr->getSourceRange());"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,895: | Line 2,915: | ||
}, | }, | ||
["err_asm_invalid_operand_number"]={ | ["err_asm_invalid_operand_number"]={ | ||
[e]="invalid operand number in inline asm string", | |||
[d]=l, | |||
[f]=m, | |||
[h]="invalid operand number in inline asm string", | [h]="invalid operand number in inline asm string", | ||
[ | [b]=n, | ||
[ | [j]="invalid operand number in inline asm string", | ||
[c]=a, | |||
[ | [i]=G, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{Eb,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 while (true) {\n // Handle operands that don\'t have asmSymbolicName (e.g., %x4).\n if (isDigit(EscapedChar)) {\n if (N >= NumOperands) {\n return diag::err_asm_invalid_operand_number;"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [W]={"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"]={ | ["err_asm_invalid_output_constraint"]={ | ||
[ | [e]="invalid output constraint \'A\' in asm", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid output constraint \'%0\' in asm", | ||
[ | [b]=n, | ||
[ | [j]="invalid output constraint \'(.*?)\' in asm", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{J,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 for (unsigned i = 0; i != NumOutputs; i++) {\n if (!Context.getTargetInfo().validateOutputConstraint(Info)) {\n targetDiag(Literal->getBeginLoc(), diag::err_asm_invalid_output_constraint) << Info.getConstraintStr();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/arm-asm.c"]={"clang/test/Sema/arm-asm.c:5:37: error: invalid output constraint \'=&b\' in asm"} | ["clang/test/Sema/arm-asm.c"]={"clang/test/Sema/arm-asm.c:5:37: error: invalid output constraint \'=&b\' in asm"} | ||
Line 2,925: | Line 2,945: | ||
}, | }, | ||
["err_asm_invalid_output_size"]={ | ["err_asm_invalid_output_size"]={ | ||
[ | [e]="invalid output size for constraint \'A\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid output size for constraint \'%0\'", | ||
[ | [b]=n, | ||
[ | [j]="invalid output size for constraint \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"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."}, | ||
[k]={{ | [k]={{J,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 for (unsigned i = 0; i != NumOutputs; i++) {\n if (!Context.getTargetInfo().validateOutputSize(FeatureMap, Literal->getString(), Size)) {\n targetDiag(OutputExpr->getBeginLoc(), diag::err_asm_invalid_output_size) << Info.getConstraintStr();"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 2,940: | Line 2,960: | ||
}, | }, | ||
["err_asm_invalid_type"]={ | ["err_asm_invalid_type"]={ | ||
[ | [e]="invalid type A in asm ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid type %0 in asm %select{input|output}1", | ||
[ | [b]=n, | ||
[ | [j]="invalid type (.*?) in asm (?:input|output)", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"60ee88599098",1589228634,"[clang][asm goto][slh] Warn if asm goto + SLH","[clang][asm goto][slh] Warn if asm goto + SLH"}, | ||
[k]={{ | [k]={{J,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 for (unsigned i = 0; i != NumOutputs; i++) {\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*/"},{J,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 for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n if (InputExpr->getType()->isBitIntType())\n return StmtError(Diag(InputExpr->getBeginLoc(), diag::err_asm_invalid_type) << InputExpr->getType() << 1 /*Output*/"},{J,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 for (uint64_t I = 0; I < NumOutputs + NumInputs; ++I) {\n if (E->getType()->isBitIntType()) {\n Diag(E->getBeginLoc(), diag::err_asm_invalid_type) << E->getType() << (I < NumOutputs) << E->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,955: | Line 2,975: | ||
}, | }, | ||
["err_asm_invalid_type_in_input"]={ | ["err_asm_invalid_type_in_input"]={ | ||
[ | [e]="invalid type A in asm input for constraint \'B\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid type %0 in asm input for constraint \'%1\'", | ||
[ | [b]=n, | ||
[ | [j]="invalid type (.*?) in asm input for constraint \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{"clang/lib/CodeGen/CGStmt.cpp",2565,"void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) {\n for (unsigned i = 0, e = S.getNumOutputs(); i != e; i++) {\n if (!Info.allowsMemory() && IsScalarOrAggregate) {\n if (llvm::Type *AdjTy = getTargetHooks().adjustInlineAsmType(*this, OutputConstraint, ResultRegTypes.back()))\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 for (unsigned i = 0, e = S.getNumInputs(); i != e; i++) {\n if (llvm::Type *AdjTy = getTargetHooks().adjustInlineAsmType(*this, ReplaceConstraint, Arg->getType()))\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 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 bool HandleNamedDecl(const NamedDecl *ND, MangledSymbols &Symbols, int RDO) {\n Instance.getDiagnostics().Report(diag::err_asm_invalid_type_in_input) << \"Expected a function or function template decl.\";"},{ | [k]={{"clang/lib/CodeGen/CGStmt.cpp",2565,"void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) {\n for (unsigned i = 0, e = S.getNumOutputs(); i != e; i++) {\n if (!Info.allowsMemory() && IsScalarOrAggregate) {\n if (llvm::Type *AdjTy = getTargetHooks().adjustInlineAsmType(*this, OutputConstraint, ResultRegTypes.back()))\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 for (unsigned i = 0, e = S.getNumInputs(); i != e; i++) {\n if (llvm::Type *AdjTy = getTargetHooks().adjustInlineAsmType(*this, ReplaceConstraint, Arg->getType()))\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 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 bool HandleNamedDecl(const NamedDecl *ND, MangledSymbols &Symbols, int RDO) {\n Instance.getDiagnostics().Report(diag::err_asm_invalid_type_in_input) << \"Expected a function or function template decl.\";"},{J,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 for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\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());"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"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"]={ | ["err_asm_naked_parm_ref"]={ | ||
[e]="parameter references not allowed in naked functions", | |||
[d]=l, | |||
[f]=m, | |||
[h]="parameter references not allowed in naked functions", | [h]="parameter references not allowed in naked functions", | ||
[ | [b]=n, | ||
[ | [j]="parameter references not allowed in naked functions", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"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"}, | |||
[k]={{J,149,"static bool CheckNakedParmReference(Expr *E, Sema &S) {\n while (WorkList.size()) {\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);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 2,985: | Line 3,005: | ||
}, | }, | ||
["err_asm_naked_this_ref"]={ | ["err_asm_naked_this_ref"]={ | ||
[e]="\'this\' pointer references not allowed in naked functions", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'this\' pointer references not allowed in naked functions", | [h]="\'this\' pointer references not allowed in naked functions", | ||
[ | [b]=n, | ||
[ | [j]="\'this\' pointer references not allowed in naked functions", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"71ac240620c4",1423002958,"Diagnose CXX \'this\' pointer reference in funcs with naked attr","Diagnose CXX \'this\' pointer reference in funcs with naked attr"}, | |||
[k]={{J,143,"static bool CheckNakedParmReference(Expr *E, Sema &S) {\n while (WorkList.size()) {\n if (isa<CXXThisExpr>(E)) {\n S.Diag(E->getBeginLoc(), diag::err_asm_naked_this_ref);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/attr-naked.cpp"]={"clang/test/Sema/attr-naked.cpp:12:28: error: \'this\' pointer references not allowed in naked functions"} | ["clang/test/Sema/attr-naked.cpp"]={"clang/test/Sema/attr-naked.cpp:12:28: error: \'this\' pointer references not allowed in naked functions"} | ||
Line 3,000: | Line 3,020: | ||
}, | }, | ||
["err_asm_non_addr_value_in_memory_constraint"]={ | ["err_asm_non_addr_value_in_memory_constraint"]={ | ||
[ | [e]="reference to a ... in asm ... with a memory constraint \'A\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="reference to a %select{bit-field|vector element|global register variable}0 in asm %select{input|output}1 with a memory constraint \'%2\'", | ||
[ | [b]=n, | ||
[ | [j]="reference to a (?:bit\\-field|vector element|global register variable) in asm (?:input|output) with a memory constraint \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"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."}, | ||
[k]={{ | [k]={{J,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 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();"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"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"]={ | ["err_asm_operand_wide_string_literal"]={ | ||
[ | [e]="cannot use ... string literal in \'asm\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot use %select{unicode|wide|an empty}0 string literal in \'asm\'", | ||
[ | [b]=n, | ||
[ | [j]="cannot use (?:unicode|wide|an empty) string literal in \'asm\'", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"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>."}, | ||
[k]={{ | [k]={{lc,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 if (!AsmString.isInvalid()) {\n if (!SL->isOrdinary()) {\n Diag(Tok, diag::err_asm_operand_wide_string_literal) << SL->isWide() << SL->getSourceRange();"},{lc,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 if (!AsmString.isInvalid()) {\n if (ForAsmLabel && SL->getString().empty()) {\n Diag(Tok, diag::err_asm_operand_wide_string_literal) << 2 /* an empty */ << SL->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 3,030: | Line 3,050: | ||
}, | }, | ||
["err_asm_pmf_through_constraint_not_permitted"]={ | ["err_asm_pmf_through_constraint_not_permitted"]={ | ||
[e]="cannot pass a pointer-to-member through register-constrained inline assembly parameter", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot pass a pointer-to-member through register-constrained inline assembly parameter", | [h]="cannot pass a pointer-to-member through register-constrained inline assembly parameter", | ||
[ | [b]=n, | ||
[ | [j]="cannot pass a pointer\\-to\\-member through register\\-constrained inline assembly parameter", | ||
[c]=a, | |||
[i]=G, | |||
[g]={R,1625925174,B,B}, | |||
[ | [k]={{J,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 for (unsigned i = NumOutputs, e = NumOutputs + NumInputs; i != e; i++) {\n if (InputExpr->getType()->isMemberPointerType())\n return StmtError(Diag(InputExpr->getBeginLoc(), diag::err_asm_pmf_through_constraint_not_permitted) << InputExpr->getSourceRange());"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,045: | Line 3,065: | ||
}, | }, | ||
["err_asm_qualifier_ignored"]={ | ["err_asm_qualifier_ignored"]={ | ||
[e]="expected \'volatile\', \'inline\', \'goto\', or \'(\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="expected \'volatile\', \'inline\', \'goto\', or \'(\'", | [h]="expected \'volatile\', \'inline\', \'goto\', or \'(\'", | ||
[ | [b]=n, | ||
[ | [j]="expected \'volatile\', \'inline\', \'goto\', or \'\\(\'", | ||
[c]=a, | |||
[i]=G, | |||
[g]={"f08df464ae89",1582039343,"[OPENMP50]Add initial support for OpenMP 5.0 iterator.","[OPENMP50]Add initial support for OpenMP 5.0 iterator."}, | |||
[ | |||
[ | |||
[ | |||
[k]={{"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 if (A == GNUAsmQualifiers::AQ_unspecified) {\n if (Tok.isNot(tok::l_paren)) {\n Diag(Tok.getLocation(), diag::err_asm_qualifier_ignored);"}}, | [k]={{"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 if (A == GNUAsmQualifiers::AQ_unspecified) {\n if (Tok.isNot(tok::l_paren)) {\n Diag(Tok.getLocation(), diag::err_asm_qualifier_ignored);"}}, | ||
[o]={ | [o]={ | ||
Line 3,060: | Line 3,080: | ||
}, | }, | ||
["err_asm_register_size_mismatch"]={ | ["err_asm_register_size_mismatch"]={ | ||
[ | [e]="size of register \'A\' does not match variable size", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="size of register \'%0\' does not match variable size", | ||
[ | [b]=n, | ||
[ | [j]="size of register \'(.*?)\' does not match variable size", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"8c26ea663d43",1447805728,"Produce a better diagnostic for global register variables.","Produce a better diagnostic for global register variables."}, | ||
[k]={{ | [k]={{s,7965,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n if (S->getFnParent() != nullptr) {\n } else if (SC == SC_Register) {\n // Global Named register\n if (DeclAttrsMatchCUDAMode(getLangOpts(), NewVD)) {\n if (!TI.isValidGCCRegisterName(Label))\n else if (!TI.validateGlobalRegisterVariable(Label, Context.getTypeSize(R), HasSizeMismatch))\n else if (HasSizeMismatch)\n Diag(E->getExprLoc(), diag::err_asm_register_size_mismatch) << Label;"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"clang/test/Sema/asm.c:204:28: error: size of register \'esp\' does not match variable size"} | ||
} | } | ||
}, | }, | ||
["err_asm_tying_incompatible_types"]={ | ["err_asm_tying_incompatible_types"]={ | ||
[ | [e]="unsupported inline asm: input with type A matching output with type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="unsupported inline asm: input with type %diff{$ matching output with type $|}0,1", | ||
[ | [b]=n, | ||
[ | [j]="unsupported inline asm\\: input with type (?:(.*?) matching output with type (.*?)|)", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"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"}, | ||
[k]={{ | [k]={{J,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 for (unsigned i = 0, e = InputConstraintInfos.size(); i != e; ++i) {\n targetDiag(InputExpr->getBeginLoc(), diag::err_asm_tying_incompatible_types) << InTy << OutTy << OutputExpr->getSourceRange() << InputExpr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"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"]={ | ["err_asm_unexpected_constraint_alternatives"]={ | ||
[ | [e]="asm constraint has an unexpected number of alternatives: A vs B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="asm constraint has an unexpected number of alternatives: %0 vs %1", | ||
[ | [b]=n, | ||
[ | [j]="asm constraint has an unexpected number of alternatives\\: (.*?) vs (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={"c63fa612e46e",1419826199,"Sema: Forbid inconsistent constraint alternatives","Sema: Forbid inconsistent constraint alternatives"}, | ||
[k]={{ | [k]={{J,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 for (unsigned i = 0, e = OutputConstraintInfos.size(); i != e; ++i) {\n if (NumAlternatives == ~0U) {\n } else if (NumAlternatives != AltCount) {\n targetDiag(NS->getOutputExpr(i)->getBeginLoc(), diag::err_asm_unexpected_constraint_alternatives) << NumAlternatives << AltCount;"},{J,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 for (unsigned i = 0, e = InputConstraintInfos.size(); i != e; ++i) {\n if (NumAlternatives == ~0U) {\n } else if (NumAlternatives != AltCount) {\n targetDiag(NS->getInputExpr(i)->getBeginLoc(), diag::err_asm_unexpected_constraint_alternatives) << NumAlternatives << AltCount;"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"clang/test/Sema/asm.c:217:21: error: asm constraint has an unexpected number of alternatives: 1 vs 2"} | ||
} | } | ||
}, | }, | ||
["err_asm_unknown_register_name"]={ | ["err_asm_unknown_register_name"]={ | ||
[ | [e]="unknown register name \'A\' in asm", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="unknown register name \'%0\' in asm", | ||
[ | [b]=n, | ||
[ | [j]="unknown register name \'(.*?)\' in asm", | ||
[ | [c]=a, | ||
[ | [i]=G, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,7945,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n if (S->getFnParent() != nullptr) {\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;"},{s,7959,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n // Handle GNU asm-label extension (encoded as an attribute).\n if (Expr *E = (Expr *)D.getAsmLabel()) {\n if (S->getFnParent() != nullptr) {\n } else if (SC == SC_Register) {\n // Global Named register\n if (DeclAttrsMatchCUDAMode(getLangOpts(), NewVD)) {\n if (!TI.isValidGCCRegisterName(Label))\n Diag(E->getExprLoc(), diag::err_asm_unknown_register_name) << Label;"},{J,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 // Check that the clobbers are valid.\n for (unsigned i = 0; i != NumClobbers; i++) {\n if (!Context.getTargetInfo().isValidClobber(Clobber)) {\n targetDiag(Literal->getBeginLoc(), diag::err_asm_unknown_register_name) << Clobber;"}}, | ||
[o]={ | [o]={ | ||
[ | [W]={"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"]={ | ["err_asm_unknown_symbolic_operand_name"]={ | ||
[e]="unknown symbolic operand name in inline assembly string", | |||
[d]=l, | |||
[f]=m, | |||
[h]="unknown symbolic operand name in inline assembly string", | [h]="unknown symbolic operand name in inline assembly string", | ||
[ | [b]=n, | ||
[ | [j]="unknown symbolic operand name in inline assembly string", | ||
[c]=a, | |||
[ | [i]=G, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{Eb,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 while (true) {\n // Handle operands that have asmSymbolicName (e.g., %x[foo]).\n if (EscapedChar == \'[\') {\n if (N == -1) {\n return diag::err_asm_unknown_symbolic_operand_name;"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [W]={"clang/test/Sema/asm.c:79:11: error: unknown symbolic operand name in inline assembly string"} | ||
} | } | ||
}, | }, | ||
["err_asm_unterminated_symbolic_operand_name"]={ | ["err_asm_unterminated_symbolic_operand_name"]={ | ||
[e]="unterminated symbolic operand name in inline assembly string", | |||
[d]=l, | |||
[f]=m, | |||
[h]="unterminated symbolic operand name in inline assembly string", | [h]="unterminated symbolic operand name in inline assembly string", | ||
[ | [b]=n, | ||
[ | [j]="unterminated symbolic operand name in inline assembly string", | ||
[c]=a, | |||
[ | [i]=G, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{Eb,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 while (true) {\n // Handle operands that have asmSymbolicName (e.g., %x[foo]).\n if (EscapedChar == \'[\') {\n if (NameEnd == nullptr)\n return diag::err_asm_unterminated_symbolic_operand_name;"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [W]={"clang/test/Sema/asm.c:80:10: error: unterminated symbolic operand name in inline assembly string"} | ||
} | } | ||
}, | }, | ||
["err_asm_unwind_and_goto"]={ | ["err_asm_unwind_and_goto"]={ | ||
[e]="unwind clobber can\'t be used with asm goto", | |||
[d]=l, | |||
[f]=m, | |||
[h]="unwind clobber can\'t be used with asm goto", | [h]="unwind clobber can\'t be used with asm goto", | ||
[ | [b]=n, | ||
[ | [j]="unwind clobber can\'t be used with asm goto", | ||
[c]=a, | |||
[ | [i]=G, | ||
[g]={hc,1615397021,lb,lb}, | |||
[k]={{J,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 // 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);"}} | |||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_assoc_compatible_types"]={ | ["err_assoc_compatible_types"]={ | ||
[ | [e]="type A in generic association compatible with previously specified type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="type %0 in generic association compatible with previously specified type %1", | ||
[ | [b]=n, | ||
[ | [j]="type (.*?) in generic association compatible with previously specified type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"91147596414d",1302827748,pb,pb}, | ||
[k]={{ | [k]={{A,1778,"ExprResult Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc, SourceLocation DefaultLoc, SourceLocation RParenLoc, bool PredicateIsExpr, void *ControllingExprOrType, ArrayRef<TypeSourceInfo *> Types, ArrayRef<Expr *> Exprs) {\n for (unsigned i = 0; i < NumAssocs; ++i) {\n if (Types[i]) {\n if (Types[i]->getType()->isDependentType()) {\n } else {\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();"}}, | ||
[o]={ | [o]={ | ||
["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 *\')"} | ["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 *\')"} | ||
Line 3,177: | Line 3,197: | ||
}, | }, | ||
["err_assoc_type_incomplete"]={ | ["err_assoc_type_incomplete"]={ | ||
[ | [e]="type A in generic association incomplete", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="type %0 in generic association incomplete", | ||
[ | [b]=n, | ||
[ | [j]="type (.*?) in generic association incomplete", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"91147596414d",1302827748,pb,pb}, | ||
[k]={{ | [k]={{A,1726,"ExprResult Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc, SourceLocation DefaultLoc, SourceLocation RParenLoc, bool PredicateIsExpr, void *ControllingExprOrType, ArrayRef<TypeSourceInfo *> Types, ArrayRef<Expr *> Exprs) {\n for (unsigned i = 0; i < NumAssocs; ++i) {\n if (Types[i]) {\n if (Types[i]->getType()->isDependentType()) {\n } else {\n if (ControllingExpr && Types[i]->getType()->isIncompleteType())\n D = diag::err_assoc_type_incomplete;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/generic-selection.cpp"]={"clang/test/SemaCXX/generic-selection.cpp:87:21: error: type \'struct T\' in generic association incomplete"} | ["clang/test/SemaCXX/generic-selection.cpp"]={"clang/test/SemaCXX/generic-selection.cpp:87:21: error: type \'struct T\' in generic association incomplete"} | ||
Line 3,192: | Line 3,212: | ||
}, | }, | ||
["err_assoc_type_nonobject"]={ | ["err_assoc_type_nonobject"]={ | ||
[ | [e]="type A in generic association not an object type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="type %0 in generic association not an object type", | ||
[ | [b]=n, | ||
[ | [j]="type (.*?) in generic association not an object type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"91147596414d",1302827748,pb,pb}, | ||
[k]={{ | [k]={{A,1728,"ExprResult Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc, SourceLocation DefaultLoc, SourceLocation RParenLoc, bool PredicateIsExpr, void *ControllingExprOrType, ArrayRef<TypeSourceInfo *> Types, ArrayRef<Expr *> Exprs) {\n for (unsigned i = 0; i < NumAssocs; ++i) {\n if (Types[i]) {\n if (Types[i]->getType()->isDependentType()) {\n } else {\n if (ControllingExpr && Types[i]->getType()->isIncompleteType())\n else if (ControllingExpr && !Types[i]->getType()->isObjectType())\n D = diag::err_assoc_type_nonobject;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/generic-selection.c"]={"clang/test/Sema/generic-selection.c:9:7: error: type \'void ()\' in generic association not an object type"} | ["clang/test/Sema/generic-selection.c"]={"clang/test/Sema/generic-selection.c:9:7: error: type \'void ()\' in generic association not an object type"} | ||
Line 3,207: | Line 3,227: | ||
}, | }, | ||
["err_assoc_type_variably_modified"]={ | ["err_assoc_type_variably_modified"]={ | ||
[ | [e]="type A in generic association is a variably modified type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="type %0 in generic association is a variably modified type", | ||
[ | [b]=n, | ||
[ | [j]="type (.*?) in generic association is a variably modified type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"91147596414d",1302827748,pb,pb}, | ||
[k]={{ | [k]={{A,1730,"ExprResult Sema::CreateGenericSelectionExpr(SourceLocation KeyLoc, SourceLocation DefaultLoc, SourceLocation RParenLoc, bool PredicateIsExpr, void *ControllingExprOrType, ArrayRef<TypeSourceInfo *> Types, ArrayRef<Expr *> Exprs) {\n for (unsigned i = 0; i < NumAssocs; ++i) {\n if (Types[i]) {\n if (Types[i]->getType()->isDependentType()) {\n } else {\n if (ControllingExpr && Types[i]->getType()->isIncompleteType())\n else if (ControllingExpr && !Types[i]->getType()->isObjectType())\n else if (Types[i]->getType()->isVariablyModifiedType())\n D = diag::err_assoc_type_variably_modified;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,222: | Line 3,242: | ||
}, | }, | ||
["err_ast_file_invalid"]={ | ["err_ast_file_invalid"]={ | ||
[ | [e]="file \'A\' is not a valid precompiled ... file", | ||
[ | [d]=kc, | ||
[ | [f]=mc, | ||
[ | [h]="file \'%1\' is not a valid precompiled %select{PCH|module|AST}0 file", | ||
[ | [b]=jc, | ||
[ | [j]="file \'(.*?)\' is not a valid precompiled (?:PCH|module|AST) file", | ||
[ | [c]=a, | ||
[ | [i]="AST Deserialization Issue", | ||
[ | [g]={"a2f2c2f3a463",1605203629,cc,cc}, | ||
[k]={{"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 // Sniff for the signature.\n if (llvm::Error Err = doesntStartWithASTFileMagic(Stream)) {\n Diag(diag::err_ast_file_invalid) << moduleKindForDiagnostic(Type) << FileName << std::move(Err);"}}, | [k]={{"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 // Sniff for the signature.\n if (llvm::Error Err = doesntStartWithASTFileMagic(Stream)) {\n Diag(diag::err_ast_file_invalid) << moduleKindForDiagnostic(Type) << FileName << std::move(Err);"}}, | ||
[o]={ | [o]={ | ||
Line 3,237: | Line 3,257: | ||
}, | }, | ||
["err_ast_file_not_found"]={ | ["err_ast_file_not_found"]={ | ||
[ | [e]="... file \'A\' not found...", | ||
[ | [d]=kc, | ||
[ | [f]=mc, | ||
[ | [h]="%select{PCH|module|AST}0 file \'%1\' not found%select{|: %3}2", | ||
[ | [b]=jc, | ||
[ | [j]="(?:PCH|module|AST) file \'(.*?)\' not found(?:|\\: (.*?))", | ||
[ | [c]=a, | ||
[ | [i]="AST Deserialization Issue", | ||
[ | [g]={"a2f2c2f3a463",1605203629,cc,cc}, | ||
[k]={{"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 case ModuleManager::Missing:\n Diag(diag::err_ast_file_not_found) << moduleKindForDiagnostic(Type) << FileName << !ErrorStr.empty() << ErrorStr;"}}, | [k]={{"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 case ModuleManager::Missing:\n Diag(diag::err_ast_file_not_found) << moduleKindForDiagnostic(Type) << FileName << !ErrorStr.empty() << ErrorStr;"}}, | ||
[o]={ | [o]={ | ||
Line 3,252: | Line 3,272: | ||
}, | }, | ||
["err_ast_file_out_of_date"]={ | ["err_ast_file_out_of_date"]={ | ||
[ | [e]="... file \'A\' is out of date and needs to be rebuilt...", | ||
[ | [d]=kc, | ||
[ | [f]=mc, | ||
[ | [h]="%select{PCH|module|AST}0 file \'%1\' is out of date and needs to be rebuilt%select{|: %3}2", | ||
[ | [b]=jc, | ||
[ | [j]="(?:PCH|module|AST) file \'(.*?)\' is out of date and needs to be rebuilt(?:|\\: (.*?))", | ||
[ | [c]=a, | ||
[ | [i]="AST Deserialization Issue", | ||
[ | [g]={"a2f2c2f3a463",1605203629,cc,cc}, | ||
[k]={{"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 case ModuleManager::OutOfDate:\n Diag(diag::err_ast_file_out_of_date) << moduleKindForDiagnostic(Type) << FileName << !ErrorStr.empty() << ErrorStr;"}}, | [k]={{"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 case ModuleManager::OutOfDate:\n Diag(diag::err_ast_file_out_of_date) << moduleKindForDiagnostic(Type) << FileName << !ErrorStr.empty() << ErrorStr;"}}, | ||
[o]={ | [o]={ | ||
Line 3,267: | Line 3,287: | ||
}, | }, | ||
["err_at_defs_cxx"]={ | ["err_at_defs_cxx"]={ | ||
[e]="@defs is not supported in Objective-C++", | |||
[d]=l, | |||
[f]=m, | |||
[h]="@defs is not supported in Objective-C++", | [h]="@defs is not supported in Objective-C++", | ||
[ | [b]=n, | ||
[ | [j]="@defs is not supported in Objective\\-C\\+\\+", | ||
[c]=a, | |||
[i]=D, | |||
[g]={"23c84767484c",1302801679,"Parse an \'@\' in an Objective-C++ class member specification,","Parse an \'@\' in an Objective-C++ class member specification,"}, | |||
[ | [k]={{P,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);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/objcxx-at.mm"]={"clang/test/Parser/objcxx-at.mm:9:3: error: @defs is not supported in Objective-C++"} | ["clang/test/Parser/objcxx-at.mm"]={"clang/test/Parser/objcxx-at.mm:9:3: error: @defs is not supported in Objective-C++"} | ||
Line 3,282: | Line 3,302: | ||
}, | }, | ||
["err_at_in_class"]={ | ["err_at_in_class"]={ | ||
[e]="unexpected \'@\' in member specification", | |||
[d]=l, | |||
[f]=m, | |||
[h]="unexpected \'@\' in member specification", | [h]="unexpected \'@\' in member specification", | ||
[ | [b]=n, | ||
[ | [j]="unexpected \'@\' in member specification", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={"23c84767484c",1302801679,"Parse an \'@\' in an Objective-C++ class member specification,","Parse an \'@\' in an Objective-C++ class member specification,"}, | |||
[k]={{P,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 else\n Diag(Tok, diag::err_at_in_class);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/objcxx-at.mm"]={"clang/test/Parser/objcxx-at.mm:14:5: error: unexpected \'@\' in member specification"} | ["clang/test/Parser/objcxx-at.mm"]={"clang/test/Parser/objcxx-at.mm:14:5: error: unexpected \'@\' in member specification"} | ||
Line 3,297: | Line 3,317: | ||
}, | }, | ||
["err_atdef_nonfragile_interface"]={ | ["err_atdef_nonfragile_interface"]={ | ||
[e]="use of @defs is not supported on this architecture and platform", | |||
[d]=l, | |||
[f]=m, | |||
[h]="use of @defs is not supported on this architecture and platform", | [h]="use of @defs is not supported on this architecture and platform", | ||
[ | [b]=n, | ||
[ | [j]="use of @defs is not supported on this architecture and platform", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"ece1b2b0e156",1240345721,"Patch to diagnose use of objc\'s @defs in nonfragile abi.","Patch to diagnose use of objc\'s @defs in nonfragile abi."}, | |||
[k]={{O,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 if (LangOpts.ObjCRuntime.isNonFragile()) {\n Diag(DeclStart, diag::err_atdef_nonfragile_interface);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,312: | Line 3,332: | ||
}, | }, | ||
["err_atimport"]={ | ["err_atimport"]={ | ||
[e]="use of \'@import\' when modules are disabled", | |||
[d]=l, | |||
[f]=m, | |||
[h]="use of \'@import\' when modules are disabled", | [h]="use of \'@import\' when modules are disabled", | ||
[ | [b]=n, | ||
[ | [j]="use of \'@import\' when modules are disabled", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={"a773d0861800",1395871363,"Objective-C. Improve diagnostic error for \'@import\' ","Objective-C. Improve diagnostic error for \'@import\' "}, | |||
[ | |||
[ | |||
[k]={{"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 case tok::objc_import:\n Diag(AtLoc, diag::err_atimport);"}}, | [k]={{"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 case tok::objc_import:\n Diag(AtLoc, diag::err_atimport);"}}, | ||
[o]={ | [o]={ | ||
Line 3,327: | Line 3,347: | ||
}, | }, | ||
["err_atomic_builtin_bit_int_prohibit"]={ | ["err_atomic_builtin_bit_int_prohibit"]={ | ||
[e]="argument to atomic builtin of type \'_BitInt\' is not supported", | |||
[d]=l, | |||
[f]=m, | |||
[h]="argument to atomic builtin of type \'_BitInt\' is not supported", | [h]="argument to atomic builtin of type \'_BitInt\' is not supported", | ||
[ | [b]=n, | ||
[ | [j]="argument to atomic builtin of type \'_BitInt\' is not supported", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={yb,1616787805,S,S}, | |||
[k]={{u,7460,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n if (ValType->isBitIntType()) {\n Diag(Ptr->getExprLoc(), diag::err_atomic_builtin_bit_int_prohibit);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Hb]={"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"]={ | ["err_atomic_builtin_cannot_be_const"]={ | ||
[ | [e]="address argument to atomic builtin cannot be const-qualified (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic builtin cannot be const-qualified (%0 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic builtin cannot be const\\-qualified \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"a383c94ccd63",1525541922,"Disallow pointers to const in __sync_fetch_and_xxx.","Disallow pointers to const in __sync_fetch_and_xxx."}, | ||
[k]={{ | [k]={{u,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 if (ValType.isConstQualified()) {\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_cannot_be_const) << FirstArg->getType() << FirstArg->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Hb]={"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"]={ | ["err_atomic_builtin_ext_int_size"]={ | ||
[e]="Atomic memory operand must have a power-of-two size", | |||
[d]=l, | |||
[f]=m, | |||
[h]="Atomic memory operand must have a power-of-two size", | [h]="Atomic memory operand must have a power-of-two size", | ||
[ | [b]=n, | ||
[ | [j]="Atomic memory operand must have a power\\-of\\-two size", | ||
[c]=a, | |||
[i]=p, | |||
[g]={cb,1582847864,I,I}, | |||
[ | [k]={{u,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 if (BitIntValType && !llvm::isPowerOf2_64(BitIntValType->getNumBits())) {\n Diag(FirstArg->getExprLoc(), diag::err_atomic_builtin_ext_int_size);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Hb]={"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"]={ | ["err_atomic_builtin_must_be_pointer"]={ | ||
[ | [e]="address argument to atomic builtin must be a pointer (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic builtin must be a pointer (%0 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic builtin must be a pointer \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"dc04654697fb",1241765902,Ob,Ob}, | ||
[k]={{ | [k]={{u,3182,"bool Sema::CheckARMBuiltinExclusiveCall(unsigned BuiltinID, CallExpr *TheCall, unsigned MaxWidth) {\n if (!pointerType) {\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_must_be_pointer) << PointerArg->getType() << PointerArg->getSourceRange();"},{u,7153,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n if (!pointerType) {\n Diag(ExprRange.getBegin(), diag::err_atomic_builtin_must_be_pointer) << Ptr->getType() << Ptr->getSourceRange();"},{u,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 if (!pointerType) {\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_must_be_pointer) << FirstArg->getType() << FirstArg->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,387: | Line 3,407: | ||
}, | }, | ||
["err_atomic_builtin_must_be_pointer_intfltptr"]={ | ["err_atomic_builtin_must_be_pointer_intfltptr"]={ | ||
[ | [e]="address argument to atomic builtin must be a pointer to integer, floating-point or pointer (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic builtin must be a pointer to integer, floating-point or pointer (%0 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic builtin must be a pointer to integer, floating\\-point or pointer \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"6aacd49094bc",1373968073,"ARM: implement low-level intrinsics for the atomic exclusive operations.","ARM: implement low-level intrinsics for the atomic exclusive operations."}, | ||
[k]={{ | [k]={{u,3216,"bool Sema::CheckARMBuiltinExclusiveCall(unsigned BuiltinID, CallExpr *TheCall, unsigned MaxWidth) {\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();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,402: | Line 3,422: | ||
}, | }, | ||
["err_atomic_builtin_must_be_pointer_intptr"]={ | ["err_atomic_builtin_must_be_pointer_intptr"]={ | ||
[ | [e]="address argument to atomic builtin must be a pointer to integer or pointer (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic builtin must be a pointer to integer or pointer (%0 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic builtin must be a pointer to integer or pointer \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"dc04654697fb",1241765902,Ob,Ob}, | ||
[k]={{ | [k]={{u,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 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"]={ | ["err_atomic_builtin_pointer_size"]={ | ||
[ | [e]="address argument to atomic builtin must be a pointer to 1,2,4,8 or 16 byte type (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic builtin must be a pointer to 1,2,4,8 or 16 byte type (%0 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic builtin must be a pointer to 1,2,4,8 or 16 byte type \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"dc04654697fb",1241765902,Ob,Ob}, | ||
[k]={{ | [k]={{u,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 default:\n Diag(DRE->getBeginLoc(), diag::err_atomic_builtin_pointer_size) << FirstArg->getType() << FirstArg->getSourceRange();"}} | ||
}, | }, | ||
["err_atomic_exclusive_builtin_pointer_size"]={ | ["err_atomic_exclusive_builtin_pointer_size"]={ | ||
[ | [e]="address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type (%0 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to load or store exclusive builtin must be a pointer to 1,2,4 or 8 byte type \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"6aacd49094bc",1373968073,"ARM: implement low-level intrinsics for the atomic exclusive operations.","ARM: implement low-level intrinsics for the atomic exclusive operations."}, | ||
[k]={{ | [k]={{u,3224,"bool Sema::CheckARMBuiltinExclusiveCall(unsigned BuiltinID, CallExpr *TheCall, unsigned MaxWidth) {\n // But ARM doesn\'t have instructions to deal with 128-bit versions.\n if (Context.getTypeSize(ValType) > MaxWidth) {\n Diag(DRE->getBeginLoc(), diag::err_atomic_exclusive_builtin_pointer_size) << PointerArg->getType() << PointerArg->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,441: | Line 3,461: | ||
}, | }, | ||
["err_atomic_load_store_uses_lib"]={ | ["err_atomic_load_store_uses_lib"]={ | ||
[ | [e]="atomic ... requires runtime support that is not available for this target", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="atomic %select{load|store}0 requires runtime support that is not available for this target", | ||
[ | [b]=n, | ||
[ | [j]="atomic (?:load|store) requires runtime support that is not available for this target", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"615de765abde",1369762659,"Patch to issue error when target of MacOS and iOS ","Patch to issue error when target of MacOS and iOS "}, | ||
[k]={{ | [k]={{u,7452,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\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);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,456: | Line 3,476: | ||
}, | }, | ||
["err_atomic_op_has_invalid_synch_scope"]={ | ["err_atomic_op_has_invalid_synch_scope"]={ | ||
[e]="synchronization scope argument to atomic operation is invalid", | |||
[d]=l, | |||
[f]=m, | |||
[h]="synchronization scope argument to atomic operation is invalid", | [h]="synchronization scope argument to atomic operation is invalid", | ||
[ | [b]=n, | ||
[ | [j]="synchronization scope argument to atomic operation is invalid", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"39195062c20c",1501870591,"Add OpenCL 2.0 atomic builtin functions as Clang builtin","Add OpenCL 2.0 atomic builtin functions as Clang builtin"}, | |||
[k]={{u,7436,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n if (auto ScopeModel = AtomicExpr::getScopeModel(Op)) {\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();"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,471: | Line 3,491: | ||
}, | }, | ||
["err_atomic_op_needs_atomic"]={ | ["err_atomic_op_needs_atomic"]={ | ||
[ | [e]="address argument to atomic operation must be a pointer to _Atomic type (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic operation must be a pointer to _Atomic type (%0 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic operation must be a pointer to _Atomic type \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"df14b3a8377f",1318299601,"Initial implementation of __atomic_* (everything except __atomic_is_lock_free).","Initial implementation of __atomic_* (everything except __atomic_is_lock_free)."}, | ||
[k]={{ | [k]={{u,7163,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n if (IsC11) {\n if (!AtomTy->isAtomicType()) {\n Diag(ExprRange.getBegin(), diag::err_atomic_op_needs_atomic) << Ptr->getType() << Ptr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,486: | Line 3,506: | ||
}, | }, | ||
["err_atomic_op_needs_atomic_int"]={ | ["err_atomic_op_needs_atomic_int"]={ | ||
[ | [e]="address argument to atomic operation must be a pointer to ...integer (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic operation must be a pointer to %select{|atomic }0integer (%1 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic operation must be a pointer to (?:|atomic )integer \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"c094e7dc4b3f",1573050950,"[SYCL] Add sycl_kernel attribute for accelerated code outlining","[SYCL] Add sycl_kernel attribute for accelerated code outlining"}, | ||
[k]={{ | [k]={{u,7207,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // For an arithmetic operation, the implied arithmetic must be well-formed.\n if (Form == Arithmetic) {\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;"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,501: | Line 3,521: | ||
}, | }, | ||
["err_atomic_op_needs_atomic_int_or_fp"]={ | ["err_atomic_op_needs_atomic_int_or_fp"]={ | ||
[ | [e]="address argument to atomic operation must be a pointer to ...integer or supported floating point type (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic operation must be a pointer to %select{|atomic }0integer or supported floating point type (%1 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic operation must be a pointer to (?:|atomic )integer or supported floating point type \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{ | [k]={{u,7206,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // For an arithmetic operation, the implied arithmetic must be well-formed.\n if (Form == Arithmetic) {\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;"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,516: | Line 3,536: | ||
}, | }, | ||
["err_atomic_op_needs_atomic_int_or_ptr"]={ | ["err_atomic_op_needs_atomic_int_or_ptr"]={ | ||
[ | [e]="address argument to atomic operation must be a pointer to ...integer or pointer (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic operation must be a pointer to %select{|atomic }0integer or pointer (%1 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic operation must be a pointer to (?:|atomic )integer or pointer \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"df14b3a8377f",1318299601,"Initial implementation of __atomic_* (everything except __atomic_is_lock_free).","Initial implementation of __atomic_* (everything except __atomic_is_lock_free)."}, | ||
[k]={{ | [k]={{u,7220,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // For an arithmetic operation, the implied arithmetic must be well-formed.\n if (Form == Arithmetic) {\n } else if (IsN && !ValType->isIntegerType() && !ValType->isPointerType()) {\n Diag(ExprRange.getBegin(), diag::err_atomic_op_needs_atomic_int_or_ptr) << IsC11 << Ptr->getType() << Ptr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,531: | Line 3,551: | ||
}, | }, | ||
["err_atomic_op_needs_atomic_int_ptr_or_fp"]={ | ["err_atomic_op_needs_atomic_int_ptr_or_fp"]={ | ||
[ | [e]="address argument to atomic operation must be a pointer to ...integer, pointer or supported floating point type (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic operation must be a pointer to %select{|atomic }0integer, pointer or supported floating point type (%1 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic operation must be a pointer to (?:|atomic )integer, pointer or supported floating point type \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={sb,1590001902,T,T}, | ||
[k]={{ | [k]={{u,7205,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n // For an arithmetic operation, the implied arithmetic must be well-formed.\n if (Form == Arithmetic) {\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;"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,546: | Line 3,566: | ||
}, | }, | ||
["err_atomic_op_needs_non_const_atomic"]={ | ["err_atomic_op_needs_non_const_atomic"]={ | ||
[ | [e]="address argument to atomic operation must be a pointer to non-... _Atomic type (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic operation must be a pointer to non-%select{const|constant}0 _Atomic type (%1 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic operation must be a pointer to non\\-(?:const|constant) _Atomic type \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{ | [k]={{u,7169,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n if (IsC11) {\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();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,561: | Line 3,581: | ||
}, | }, | ||
["err_atomic_op_needs_non_const_pointer"]={ | ["err_atomic_op_needs_non_const_pointer"]={ | ||
[ | [e]="address argument to atomic operation must be a pointer to non-const type (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic operation must be a pointer to non-const type (%0 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic operation must be a pointer to non\\-const type \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"a3a7c56143f4",1443917462,"Diagnose const atomics in __atomic builtins.","Diagnose const atomics in __atomic builtins."}, | ||
[k]={{ | [k]={{u,7177,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n if (IsC11) {\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();"}}, | ||
[o]={ | [o]={ | ||
[ | [Hb]={"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"]={ | ["err_atomic_op_needs_trivial_copy"]={ | ||
[ | [e]="address argument to atomic operation must be a pointer to a trivially-copyable type (A invalid)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address argument to atomic operation must be a pointer to a trivially-copyable type (%0 invalid)", | ||
[ | [b]=n, | ||
[ | [j]="address argument to atomic operation must be a pointer to a trivially\\-copyable type \\((.*?) invalid\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"feea883de4e5",1334207297,"Implement support for 18 of the GNU-compatible __atomic builtins.","Implement support for 18 of the GNU-compatible __atomic builtins."}, | ||
[k]={{ | [k]={{u,7231,"ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, SourceLocation RParenLoc, MultiExprArg Args, AtomicExpr::AtomicOp Op, AtomicArgumentOrder ArgOrder) {\n if (!IsC11 && !AtomTy.isTriviallyCopyableType(Context) && !AtomTy->isScalarType()) {\n Diag(ExprRange.getBegin(), diag::err_atomic_op_needs_trivial_copy) << Ptr->getType() << Ptr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,591: | Line 3,611: | ||
}, | }, | ||
["err_atomic_property_nontrivial_assign_op"]={ | ["err_atomic_property_nontrivial_assign_op"]={ | ||
[ | [e]="atomic property of reference type A cannot have non-trivial assignment operator", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="atomic property of reference type %0 cannot have non-trivial assignment operator", | ||
[ | [b]=n, | ||
[ | [j]="atomic property of reference type (.*?) cannot have non\\-trivial assignment operator", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"a08a74705bb0",1326155821,"objc++: patch for IRgen for atomic properties of","objc++: patch for IRgen for atomic properties of"}, | ||
[k]={{ | [k]={{Y,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 if (ObjCMethodDecl *setterMethod = property->getSetterMethodDecl()) {\n if (getLangOpts().CPlusPlus && Synthesize && !CompleteTypeErr && Ivar->getType()->isRecordType()) {\n if (property->getPropertyAttributes() & ObjCPropertyAttribute::kind_atomic) {\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();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,606: | Line 3,626: | ||
}, | }, | ||
["err_atomic_specifier_bad_type"]={ | ["err_atomic_specifier_bad_type"]={ | ||
[ | [e]="_Atomic cannot be applied to ...type A ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="_Atomic cannot be applied to %select{incomplete |array |function |reference |atomic |qualified |sizeless ||integer }0type %1 %select{|||||||which is not trivially copyable|}0", | ||
[ | [b]=n, | ||
[ | [j]="_Atomic cannot be applied to (?:incomplete |array |function |reference |atomic |qualified |sizeless ||integer )type (.*?) (?:|||||||which is not trivially copyable|)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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."}, | ||
[k]={{ | [k]={{t,9762,"QualType Sema::BuildAtomicType(QualType T, SourceLocation Loc) {\n if (!isDependentOrGNUAutoType(T)) {\n if (RequireCompleteType(Loc, T, diag::err_atomic_specifier_bad_type, 0))"},{t,9785,"QualType Sema::BuildAtomicType(QualType T, SourceLocation Loc) {\n if (!isDependentOrGNUAutoType(T)) {\n if (DisallowedKind != -1) {\n Diag(Loc, diag::err_atomic_specifier_bad_type) << DisallowedKind << T;"}}, | ||
[o]={ | [o]={ | ||
["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)\' "} | ["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)\' "} | ||
Line 3,621: | Line 3,641: | ||
}, | }, | ||
["err_atprotocol_protocol"]={ | ["err_atprotocol_protocol"]={ | ||
[ | [e]="@protocol is using a forward protocol declaration of A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="@protocol is using a forward protocol declaration of %0", | ||
[ | [b]=n, | ||
[ | [j]="@protocol is using a forward protocol declaration of (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"b111da14ada1",1534544288,"[ObjC] Error out when using forward-declared protocol in a @protocol","[ObjC] Error out when using forward-declared protocol in a @protocol"}, | ||
[k]={{ | [k]={{M,1400,"ExprResult Sema::ParseObjCProtocolExpression(IdentifierInfo *ProtocolId, SourceLocation AtLoc, SourceLocation ProtoLoc, SourceLocation LParenLoc, SourceLocation ProtoIdLoc, SourceLocation RParenLoc) {\n if (!PDecl->hasDefinition()) {\n Diag(ProtoLoc, diag::err_atprotocol_protocol) << PDecl;"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 3,636: | Line 3,656: | ||
}, | }, | ||
["err_attr_cond_never_constant_expr"]={ | ["err_attr_cond_never_constant_expr"]={ | ||
[ | [e]="A attribute expression never produces a constant expression", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute expression never produces a constant expression", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute expression never produces a constant expression", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"177399e2277c",1483935134,"Add the diagnose_if attribute to clang.","Add the diagnose_if attribute to clang."}, | ||
[k]={{q,948,"static bool checkFunctionConditionAttr(Sema &S, Decl *D, const ParsedAttr &AL, Expr *&Cond, StringRef &Msg) {\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 if (OldCond->isValueDependent() && !Cond->isValueDependent() && !Expr::isPotentialConstantExprUnevaluated(Cond, New, Diags)) {\n S.Diag(A->getLocation(), diag::err_attr_cond_never_constant_expr) << A;"}}, | [k]={{q,948,"static bool checkFunctionConditionAttr(Sema &S, Decl *D, const ParsedAttr &AL, Expr *&Cond, StringRef &Msg) {\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 if (OldCond->isValueDependent() && !Cond->isValueDependent() && !Expr::isPotentialConstantExprUnevaluated(Cond, New, Diags)) {\n S.Diag(A->getLocation(), diag::err_attr_cond_never_constant_expr) << A;"}}, | ||
[o]={ | [o]={ | ||
Line 3,651: | Line 3,671: | ||
}, | }, | ||
["err_attr_objc_ownership_redundant"]={ | ["err_attr_objc_ownership_redundant"]={ | ||
[ | [e]="the type A is already explicitly ownership-qualified", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="the type %0 is already explicitly ownership-qualified", | ||
[ | [b]=n, | ||
[ | [j]="the type (.*?) is already explicitly ownership\\-qualified", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={ob,1308874139,mb,nb}, | ||
[k]={{ | [k]={{t,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 // 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;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,666: | Line 3,686: | ||
}, | }, | ||
["err_attr_swift_error_no_error_parameter"]={ | ["err_attr_swift_error_no_error_parameter"]={ | ||
[ | [e]="A attribute can only be applied to a ... with an error parameter", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute can only be applied to a %select{function|method}1 with an error parameter", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute can only be applied to a (?:function|method) with an error parameter", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={cb,1582847864,I,I}, | ||
[k]={{q,6390,"static void handleSwiftError(Sema &S, Decl *D, const ParsedAttr &AL) {\n auto hasErrorParameter = [](Sema &S, Decl *D, const ParsedAttr &AL) -> bool {\n S.Diag(AL.getLoc(), diag::err_attr_swift_error_no_error_parameter) << AL << isa<ObjCMethodDecl>(D);"}}, | [k]={{q,6390,"static void handleSwiftError(Sema &S, Decl *D, const ParsedAttr &AL) {\n auto hasErrorParameter = [](Sema &S, Decl *D, const ParsedAttr &AL) -> bool {\n S.Diag(AL.getLoc(), diag::err_attr_swift_error_no_error_parameter) << AL << isa<ObjCMethodDecl>(D);"}}, | ||
[o]={ | [o]={ | ||
Line 3,681: | Line 3,701: | ||
}, | }, | ||
["err_attr_swift_error_return_type"]={ | ["err_attr_swift_error_return_type"]={ | ||
[ | [e]="A attribute with \'B\' convention can only be applied to a ... returning ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute with \'%1\' convention can only be applied to a %select{function|method}2 returning %select{an integral type|a pointer}3", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute with \'(.*?)\' convention can only be applied to a (?:function|method) returning (?:an integral type|a pointer)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={cb,1582847864,I,I}, | ||
[k]={{q,6403,"static void handleSwiftError(Sema &S, Decl *D, const ParsedAttr &AL) {\n auto hasPointerResult = [](Sema &S, Decl *D, const ParsedAttr &AL) -> bool {\n S.Diag(AL.getLoc(), diag::err_attr_swift_error_return_type) << AL << AL.getArgAsIdent(0)->Ident->getName() << isa<ObjCMethodDecl>(D) << /*pointer*/ 1;"},{q,6414,"static void handleSwiftError(Sema &S, Decl *D, const ParsedAttr &AL) {\n auto hasIntegerResult = [](Sema &S, Decl *D, const ParsedAttr &AL) -> bool {\n S.Diag(AL.getLoc(), diag::err_attr_swift_error_return_type) << AL << AL.getArgAsIdent(0)->Ident->getName() << isa<ObjCMethodDecl>(D) << /*integral*/ 0;"}}, | [k]={{q,6403,"static void handleSwiftError(Sema &S, Decl *D, const ParsedAttr &AL) {\n auto hasPointerResult = [](Sema &S, Decl *D, const ParsedAttr &AL) -> bool {\n S.Diag(AL.getLoc(), diag::err_attr_swift_error_return_type) << AL << AL.getArgAsIdent(0)->Ident->getName() << isa<ObjCMethodDecl>(D) << /*pointer*/ 1;"},{q,6414,"static void handleSwiftError(Sema &S, Decl *D, const ParsedAttr &AL) {\n auto hasIntegerResult = [](Sema &S, Decl *D, const ParsedAttr &AL) -> bool {\n S.Diag(AL.getLoc(), diag::err_attr_swift_error_return_type) << AL << AL.getArgAsIdent(0)->Ident->getName() << isa<ObjCMethodDecl>(D) << /*integral*/ 0;"}}, | ||
[o]={ | [o]={ | ||
Line 3,696: | Line 3,716: | ||
}, | }, | ||
["err_attr_tlsmodel_arg"]={ | ["err_attr_tlsmodel_arg"]={ | ||
[e]="tls_model must be \"global-dynamic\", \"local-dynamic\", \"initial-exec\" or \"local-exec\"", | |||
[d]=l, | |||
[f]=m, | |||
[h]="tls_model must be \"global-dynamic\", \"local-dynamic\", \"initial-exec\" or \"local-exec\"", | [h]="tls_model must be \"global-dynamic\", \"local-dynamic\", \"initial-exec\" or \"local-exec\"", | ||
[ | [b]=n, | ||
[ | [j]="tls_model must be \"global\\-dynamic\", \"local\\-dynamic\", \"initial\\-exec\" or \"local\\-exec\"", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"d3b01bc7c673",1340452306,"Support the tls_model attribute (PR9788)","Support the tls_model attribute (PR9788)"}, | |||
[ | |||
[ | |||
[ | |||
[k]={{q,2038,"static void handleTLSModelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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);"}}, | [k]={{q,2038,"static void handleTLSModelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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);"}}, | ||
[o]={ | [o]={ | ||
Line 3,711: | Line 3,731: | ||
}, | }, | ||
["err_attribute_address_function_type"]={ | ["err_attribute_address_function_type"]={ | ||
[e]="function type may not be qualified with an address space", | |||
[d]=l, | |||
[f]=m, | |||
[h]="function type may not be qualified with an address space", | [h]="function type may not be qualified with an address space", | ||
[ | [b]=n, | ||
[ | [j]="function type may not be qualified with an address space", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"8f5f520653f5",1311798605,"Forbid address-space-qualified function types, per TR 18037","Forbid address-space-qualified function types, per TR 18037"}, | |||
[k]={{t,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 // 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);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,726: | Line 3,746: | ||
}, | }, | ||
["err_attribute_address_multiple_qualifiers"]={ | ["err_attribute_address_multiple_qualifiers"]={ | ||
[e]="multiple address spaces specified for type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="multiple address spaces specified for type", | [h]="multiple address spaces specified for type", | ||
[ | [b]=n, | ||
[ | [j]="multiple address spaces specified for type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={E,1236199783,F,C}, | |||
[k]={{t,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);"},{t,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 // 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);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,741: | Line 3,761: | ||
}, | }, | ||
["err_attribute_address_space_negative"]={ | ["err_attribute_address_space_negative"]={ | ||
[e]="address space is negative", | |||
[d]=l, | |||
[f]=m, | |||
[h]="address space is negative", | [h]="address space is negative", | ||
[ | [b]=n, | ||
[ | [j]="address space is negative", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"8945266f3d02",1248763938,"Bounds checking for address spaces.","Bounds checking for address spaces."}, | |||
[k]={{t,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 // Bounds checking.\n if (addrSpace.isSigned()) {\n if (addrSpace.isNegative()) {\n S.Diag(AttrLoc, diag::err_attribute_address_space_negative) << AddrSpace->getSourceRange();"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/address_spaces.c"]={"clang/test/Sema/address_spaces.c:23:18: error: address space is negative"} | ["clang/test/Sema/address_spaces.c"]={"clang/test/Sema/address_spaces.c:23:18: error: address space is negative"} | ||
Line 3,756: | Line 3,776: | ||
}, | }, | ||
["err_attribute_address_space_too_high"]={ | ["err_attribute_address_space_too_high"]={ | ||
[ | [e]="address space is larger than the maximum supported (A)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address space is larger than the maximum supported (%0)", | ||
[ | [b]=n, | ||
[ | [j]="address space is larger than the maximum supported \\((.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"8945266f3d02",1248763938,"Bounds checking for address spaces.","Bounds checking for address spaces."}, | ||
[k]={{ | [k]={{t,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 if (addrSpace > max) {\n S.Diag(AttrLoc, diag::err_attribute_address_space_too_high) << (unsigned)max.getZExtValue() << AddrSpace->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 3,771: | Line 3,791: | ||
}, | }, | ||
["err_attribute_aligned_too_great"]={ | ["err_attribute_aligned_too_great"]={ | ||
[ | [e]="requested alignment must be A bytes or smaller", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="requested alignment must be %0 bytes or smaller", | ||
[ | [b]=n, | ||
[ | [j]="requested alignment must be (.*?) bytes or smaller", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"abecae741cb7",1392237370,"Sema: Restrict alignment to 2**28.","Sema: Restrict alignment to 2**28."}, | ||
[k]={{q,4481,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\n if (Alignment > MaximumAlignment) {\n Diag(AttrLoc, diag::err_attribute_aligned_too_great) << MaximumAlignment << E->getSourceRange();"}}, | [k]={{q,4481,"void Sema::AddAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, bool IsPackExpansion) {\n if (Alignment > MaximumAlignment) {\n Diag(AttrLoc, diag::err_attribute_aligned_too_great) << MaximumAlignment << E->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 3,786: | Line 3,806: | ||
}, | }, | ||
["err_attribute_argument_invalid"]={ | ["err_attribute_argument_invalid"]={ | ||
[ | [e]="A attribute argument is invalid: ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute argument is invalid: %select{max must be 0 since min is 0|min must not be greater than max}1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute argument is invalid\\: (?:max must be 0 since min is 0|min must not be greater than max)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"5b48d725a0bc",1474851777,"[AMDGPU] Expose flat work group size, register and wave control attributes","[AMDGPU] Expose flat work group size, register and wave control attributes"}, | ||
[k]={{q,7853,"static bool checkAMDGPUFlatWorkGroupSizeArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUFlatWorkGroupSizeAttr &Attr) {\n if (Min == 0 && Max != 0) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 0;"},{q,7858,"static bool checkAMDGPUFlatWorkGroupSizeArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUFlatWorkGroupSizeAttr &Attr) {\n if (Min > Max) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 1;"},{q,7907,"static bool checkAMDGPUWavesPerEUArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUWavesPerEUAttr &Attr) {\n if (Min == 0 && Max != 0) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 0;"},{q,7912,"static bool checkAMDGPUWavesPerEUArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUWavesPerEUAttr &Attr) {\n if (Max != 0 && Min > Max) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 1;"}}, | [k]={{q,7853,"static bool checkAMDGPUFlatWorkGroupSizeArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUFlatWorkGroupSizeAttr &Attr) {\n if (Min == 0 && Max != 0) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 0;"},{q,7858,"static bool checkAMDGPUFlatWorkGroupSizeArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUFlatWorkGroupSizeAttr &Attr) {\n if (Min > Max) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 1;"},{q,7907,"static bool checkAMDGPUWavesPerEUArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUWavesPerEUAttr &Attr) {\n if (Min == 0 && Max != 0) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 0;"},{q,7912,"static bool checkAMDGPUWavesPerEUArguments(Sema &S, Expr *MinExpr, Expr *MaxExpr, const AMDGPUWavesPerEUAttr &Attr) {\n if (Max != 0 && Min > Max) {\n S.Diag(Attr.getLocation(), diag::err_attribute_argument_invalid) << &Attr << 1;"}}, | ||
[o]={ | [o]={ | ||
Line 3,801: | Line 3,821: | ||
}, | }, | ||
["err_attribute_argument_is_zero"]={ | ["err_attribute_argument_is_zero"]={ | ||
[ | [e]="A attribute must be greater than 0", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute must be greater than 0", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute must be greater than 0", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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."}, | ||
[k]={{q,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 for (unsigned i = 0; i < 3; ++i) {\n if (WGSize[i] == 0) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_is_zero) << AL << E->getSourceRange();"},{q,3244,"// Handles intel_reqd_sub_group_size.\nstatic void handleSubGroupSize(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (SGSize == 0) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_is_zero) << AL << E->getSourceRange();"}}, | [k]={{q,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 for (unsigned i = 0; i < 3; ++i) {\n if (WGSize[i] == 0) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_is_zero) << AL << E->getSourceRange();"},{q,3244,"// Handles intel_reqd_sub_group_size.\nstatic void handleSubGroupSize(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (SGSize == 0) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_is_zero) << AL << E->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 3,816: | Line 3,836: | ||
}, | }, | ||
["err_attribute_argument_n_type"]={ | ["err_attribute_argument_n_type"]={ | ||
[ | [e]="A attribute requires parameter B to be ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%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", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute requires parameter (.*?) to be (?:int or bool|an integer constant|a string|an identifier|a constant expression|a builtin function)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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."}, | ||
[k]={{"clang/lib/Sema/SemaAttr.cpp",424,"bool Sema::ConstantFoldAttrArgs(const AttributeCommonInfo &CI, MutableArrayRef<Expr *> Args) {\n for (unsigned Idx = 0; Idx < Args.size(); Idx++) {\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;"},{q,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 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();"},{q,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 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();"},{q,870,"static bool checkTryLockFunAttrCommon(Sema &S, Decl *D, const ParsedAttr &AL, SmallVectorImpl<Expr *> &Args) {\n if (!isIntOrBool(AL.getArgAsExpr(0))) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIntOrBool;"},{q,1037,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n auto DiagnoseType = [&](unsigned Index, AttributeArgumentNType T) {\n S.Diag(Loc, diag::err_attribute_argument_n_type) << AL << Index << T;"},{q,1700,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n if (!E->isValueDependent()) {\n if (!(I = E->getIntegerConstantExpr(Context))) {\n if (OE)\n Diag(AttrLoc, diag::err_attribute_argument_n_type) << &TmpAttr << 1 << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{q,1722,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n if (OE && !OE->isValueDependent() && !OE->isIntegerConstantExpr(Context)) {\n Diag(AttrLoc, diag::err_attribute_argument_n_type) << &TmpAttr << 2 << AANT_ArgumentIntegerConstant << OE->getSourceRange();"},{q,1820,"static void handleOwnershipAttr(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;"},{q,2967,"static void handleObjCMethodFamilyAttr(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;"},{q,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;"},{q,3054,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() > 0) {\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();"},{q,3073,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() > 1) {\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();"},{q,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;"},{q,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;"},{q,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 if (!(I = E->getIntegerConstantExpr(S.Context))) {\n S.Diag(E->getExprLoc(), diag::err_attribute_argument_n_type) << &AL << Idx << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{q,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;"},{q,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;"},{q,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;"},{q,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;"},{q,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;"}}, | [k]={{"clang/lib/Sema/SemaAttr.cpp",424,"bool Sema::ConstantFoldAttrArgs(const AttributeCommonInfo &CI, MutableArrayRef<Expr *> Args) {\n for (unsigned Idx = 0; Idx < Args.size(); Idx++) {\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;"},{q,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 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();"},{q,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 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();"},{q,870,"static bool checkTryLockFunAttrCommon(Sema &S, Decl *D, const ParsedAttr &AL, SmallVectorImpl<Expr *> &Args) {\n if (!isIntOrBool(AL.getArgAsExpr(0))) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_n_type) << AL << 1 << AANT_ArgumentIntOrBool;"},{q,1037,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n auto DiagnoseType = [&](unsigned Index, AttributeArgumentNType T) {\n S.Diag(Loc, diag::err_attribute_argument_n_type) << AL << Index << T;"},{q,1700,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n if (!E->isValueDependent()) {\n if (!(I = E->getIntegerConstantExpr(Context))) {\n if (OE)\n Diag(AttrLoc, diag::err_attribute_argument_n_type) << &TmpAttr << 1 << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{q,1722,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n if (OE && !OE->isValueDependent() && !OE->isIntegerConstantExpr(Context)) {\n Diag(AttrLoc, diag::err_attribute_argument_n_type) << &TmpAttr << 2 << AANT_ArgumentIntegerConstant << OE->getSourceRange();"},{q,1820,"static void handleOwnershipAttr(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;"},{q,2967,"static void handleObjCMethodFamilyAttr(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;"},{q,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;"},{q,3054,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() > 0) {\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();"},{q,3073,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() > 1) {\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();"},{q,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;"},{q,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;"},{q,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 if (!(I = E->getIntegerConstantExpr(S.Context))) {\n S.Diag(E->getExprLoc(), diag::err_attribute_argument_n_type) << &AL << Idx << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{q,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;"},{q,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;"},{q,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;"},{q,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;"},{q,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;"}}, | ||
[o]={ | [o]={ | ||
Line 3,831: | Line 3,851: | ||
}, | }, | ||
["err_attribute_argument_out_of_bounds"]={ | ["err_attribute_argument_out_of_bounds"]={ | ||
[ | [e]="A attribute parameter B is out of bounds", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute parameter %1 is out of bounds", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute parameter (.*?) is out of bounds", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{q,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 if (IdxSource < 1 || (!IV && IdxSource > NumParams)) {\n S.Diag(getAttrLoc(AI), diag::err_attribute_argument_out_of_bounds) << &AI << AttrArgNum << IdxExpr->getSourceRange();"},{q,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 if (Idx < 1 || Idx > NumArgs) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << 2 << IdxExpr->getSourceRange();"},{q,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 // FirstArg == 0 is is always valid.\n if (FirstArg != 0) {\n if (Kind == StrftimeFormat) {\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));"},{q,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 // FirstArg == 0 is is always valid.\n if (FirstArg != 0) {\n if (Kind == StrftimeFormat) {\n } else if (isFunctionOrMethodVariadic(D)) {\n } else {\n if (FirstArg <= Idx) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << 3 << FirstArgExpr->getSourceRange();"},{q,4097,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n if (AL.isArgIdent(I)) {\n } else if (AL.isArgExpr(I)) {\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();"},{q,4104,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n if (AL.isArgIdent(I)) {\n } else if (AL.isArgExpr(I)) {\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();"},{q,6487,"static void checkSwiftAsyncErrorBlock(Sema &S, Decl *D, const SwiftAsyncErrorAttr *ErrorAttr, const SwiftAsyncAttr *AsyncAttr) {\n case SwiftAsyncErrorAttr::NonZeroArgument: {\n if (ParamIdx == 0 || ParamIdx > BlockParams.size()) {\n S.Diag(ErrorAttr->getLocation(), diag::err_attribute_argument_out_of_bounds) << ErrorAttr << 2;"},{q,7418,"static void handleMSP430InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (Num > 63) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << (int)NumParams->getSExtValue() << NumParamsExpr->getSourceRange();"},{q,7508,"static void handleM68kInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if ((Num & 1) || Num > 30) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << (int)MaybeNumParams->getSExtValue() << NumParamsExpr->getSourceRange();"},{q,7990,"static void handleLayoutVersion(Sema &S, Decl *D, const ParsedAttr &AL) {\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();"}}, | [k]={{q,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 if (IdxSource < 1 || (!IV && IdxSource > NumParams)) {\n S.Diag(getAttrLoc(AI), diag::err_attribute_argument_out_of_bounds) << &AI << AttrArgNum << IdxExpr->getSourceRange();"},{q,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 if (Idx < 1 || Idx > NumArgs) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << 2 << IdxExpr->getSourceRange();"},{q,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 // FirstArg == 0 is is always valid.\n if (FirstArg != 0) {\n if (Kind == StrftimeFormat) {\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));"},{q,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 // FirstArg == 0 is is always valid.\n if (FirstArg != 0) {\n if (Kind == StrftimeFormat) {\n } else if (isFunctionOrMethodVariadic(D)) {\n } else {\n if (FirstArg <= Idx) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << 3 << FirstArgExpr->getSourceRange();"},{q,4097,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n if (AL.isArgIdent(I)) {\n } else if (AL.isArgExpr(I)) {\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();"},{q,4104,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n if (AL.isArgIdent(I)) {\n } else if (AL.isArgExpr(I)) {\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();"},{q,6487,"static void checkSwiftAsyncErrorBlock(Sema &S, Decl *D, const SwiftAsyncErrorAttr *ErrorAttr, const SwiftAsyncAttr *AsyncAttr) {\n case SwiftAsyncErrorAttr::NonZeroArgument: {\n if (ParamIdx == 0 || ParamIdx > BlockParams.size()) {\n S.Diag(ErrorAttr->getLocation(), diag::err_attribute_argument_out_of_bounds) << ErrorAttr << 2;"},{q,7418,"static void handleMSP430InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (Num > 63) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << (int)NumParams->getSExtValue() << NumParamsExpr->getSourceRange();"},{q,7508,"static void handleM68kInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if ((Num & 1) || Num > 30) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds) << AL << (int)MaybeNumParams->getSExtValue() << NumParamsExpr->getSourceRange();"},{q,7990,"static void handleLayoutVersion(Sema &S, Decl *D, const ParsedAttr &AL) {\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();"}}, | ||
[o]={ | [o]={ | ||
Line 3,846: | Line 3,866: | ||
}, | }, | ||
["err_attribute_argument_out_of_bounds_extra_info"]={ | ["err_attribute_argument_out_of_bounds_extra_info"]={ | ||
[ | [e]="A attribute parameter B is out of bounds: no parameters to index into", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%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", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) 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 (.*?))", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"ce667f6df971",1549977542,"Renaming yet another diagnostic to not conflict; NFC.","Renaming yet another diagnostic to not conflict; NFC."}, | ||
[k]={{q,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 for (unsigned Idx = Sidx; Idx < AL.getNumArgs(); ++Idx) {\n // Now check if we index into a record type function param.\n if (!RT && ParamIdxOk) {\n if (FD && IL) {\n if (!ArgValue.isStrictlyPositive() || ParamIdxFromOne > NumParams) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds_extra_info) << AL << Idx + 1 << NumParams;"}}, | [k]={{q,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 for (unsigned Idx = Sidx; Idx < AL.getNumArgs(); ++Idx) {\n // Now check if we index into a record type function param.\n if (!RT && ParamIdxOk) {\n if (FD && IL) {\n if (!ArgValue.isStrictlyPositive() || ParamIdxFromOne > NumParams) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_out_of_bounds_extra_info) << AL << Idx + 1 << NumParams;"}}, | ||
[o]={ | [o]={ | ||
Line 3,861: | Line 3,881: | ||
}, | }, | ||
["err_attribute_argument_out_of_range"]={ | ["err_attribute_argument_out_of_range"]={ | ||
[ | [e]="A attribute requires integer constant between B and C inclusive", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute requires integer constant between %1 and %2 inclusive", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute requires integer constant between (.*?) and (.*?) inclusive", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"4b1e8399c22e",1312912771,"Thread Safety: Added basic argument parsing for all new attributes.","Thread Safety: Added basic argument parsing for all new attributes."}, | ||
[k]={{q,1188,"static void handlePassObjectSizeAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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();"},{q,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 // 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;"},{q,5744,"static void handlePatchableFunctionEntryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() == 2) {\n if (Count < Offset) {\n S.Diag(getAttrLoc(AL), diag::err_attribute_argument_out_of_range) << &AL << 0 << Count << Arg->getBeginLoc();"}}, | [k]={{q,1188,"static void handlePassObjectSizeAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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();"},{q,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 // 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;"},{q,5744,"static void handlePatchableFunctionEntryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() == 2) {\n if (Count < Offset) {\n S.Diag(getAttrLoc(AL), diag::err_attribute_argument_out_of_range) << &AL << 0 << Count << Arg->getBeginLoc();"}}, | ||
[o]={ | [o]={ | ||
Line 3,876: | Line 3,896: | ||
}, | }, | ||
["err_attribute_argument_parm_pack_not_supported"]={ | ["err_attribute_argument_parm_pack_not_supported"]={ | ||
[ | [e]="attribute A does not support argument pack expansion", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="attribute %0 does not support argument pack expansion", | ||
[ | [b]=n, | ||
[ | [j]="attribute (.*?) does not support argument pack expansion", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"69350e569dc4",1612659633,"[C++20][Modules][3/8] Initial handling for module partitions.","[C++20][Modules][3/8] Initial handling for module partitions."}, | ||
[k]={{ | [k]={{H,481,"unsigned Parser::ParseAttributeArgsCommon(IdentifierInfo *AttrName, SourceLocation AttrNameLoc, ParsedAttributes &Attrs, SourceLocation *EndLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n if (!ArgExprs.empty() ? Tok.is(tok::comma) : Tok.isNot(tok::r_paren)) {\n if (AttributeIsTypeArgAttr) {\n } else if (AttributeHasVariadicIdentifierArg) {\n } else {\n // Pack expansion must currently be explicitly supported by an attribute.\n for (size_t I = 0; I < ParsedExprs.size(); ++I) {\n if (!attributeAcceptsExprPack(*AttrName)) {\n Diag(Tok.getLocation(), diag::err_attribute_argument_parm_pack_not_supported) << AttrName;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Parser/cxx0x-attributes.cpp"]={"clang/test/Parser/cxx0x-attributes.cpp:269:38: error: attribute \'no_sanitize\' does not support argument pack expansion"} | ["clang/test/Parser/cxx0x-attributes.cpp"]={"clang/test/Parser/cxx0x-attributes.cpp:269:38: error: attribute \'no_sanitize\' does not support argument pack expansion"} | ||
Line 3,891: | Line 3,911: | ||
}, | }, | ||
["err_attribute_argument_type"]={ | ["err_attribute_argument_type"]={ | ||
[ | [e]="A attribute requires ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute requires %select{int or bool|an integer constant|a string|an identifier}1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute requires (?:int or bool|an integer constant|a string|an identifier)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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."}, | ||
[k]={{q,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 if (Expr->isTypeDependent() || !(I = Expr->getIntegerConstantExpr(S.Context))) {\n if (Idx != UINT_MAX)\n else\n S.Diag(getAttrLoc(AI), diag::err_attribute_argument_type) << &AI << AANT_ArgumentIntegerConstant << Expr->getSourceRange();"},{q,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 if (!Literal || !Literal->isOrdinary()) {\n Diag(E->getBeginLoc(), diag::err_attribute_argument_type) << CI << AANT_ArgumentString;"},{q,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 Diag(Loc->Loc, diag::err_attribute_argument_type) << AL << AANT_ArgumentString << FixItHint::CreateInsertion(Loc->Loc, \"\\\"\") << FixItHint::CreateInsertion(getLocForEndOfToken(Loc->Loc), \"\\\"\");"},{q,1217,"static void handleConsumableAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1289,"static void handleParamTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1321,"static void handleReturnTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1368,"static void handleSetTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1390,"static void handleTestTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1704,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n if (!E->isValueDependent()) {\n if (!(I = E->getIntegerConstantExpr(Context))) {\n if (OE)\n else\n Diag(AttrLoc, diag::err_attribute_argument_type) << &TmpAttr << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{q,2100,"static void handleCPUSpecificAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,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;"},{q,6892,"static void handleSwiftNewType(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,7223,"static void handleHLSLResourceBindingAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,7236,"static void handleHLSLResourceBindingAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() == 2) {\n if (!AL.isArgIdent(1)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,7402,"static void handleMSP430InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgExpr(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant;"},{q,7410,"static void handleMSP430InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!(NumParams = NumParamsExpr->getIntegerConstantExpr(S.Context))) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant << NumParamsExpr->getSourceRange();"},{q,7490,"static void handleM68kInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgExpr(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant;"},{q,7500,"static void handleM68kInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!MaybeNumParams) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant << NumParamsExpr->getSourceRange();"},{q,8592,"static void handleCFGuardAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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 if (A.getNumArgs() == 1) {\n if (!(ArgVal = E->getIntegerConstantExpr(S.Context))) {\n S.Diag(A.getLoc(), diag::err_attribute_argument_type) << A << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{ | [k]={{q,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 if (Expr->isTypeDependent() || !(I = Expr->getIntegerConstantExpr(S.Context))) {\n if (Idx != UINT_MAX)\n else\n S.Diag(getAttrLoc(AI), diag::err_attribute_argument_type) << &AI << AANT_ArgumentIntegerConstant << Expr->getSourceRange();"},{q,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 if (!Literal || !Literal->isOrdinary()) {\n Diag(E->getBeginLoc(), diag::err_attribute_argument_type) << CI << AANT_ArgumentString;"},{q,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 Diag(Loc->Loc, diag::err_attribute_argument_type) << AL << AANT_ArgumentString << FixItHint::CreateInsertion(Loc->Loc, \"\\\"\") << FixItHint::CreateInsertion(getLocForEndOfToken(Loc->Loc), \"\\\"\");"},{q,1217,"static void handleConsumableAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1289,"static void handleParamTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1321,"static void handleReturnTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1368,"static void handleSetTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1390,"static void handleTestTypestateAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isArgIdent(0)) {\n } else {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,1704,"void Sema::AddAssumeAlignedAttr(Decl *D, const AttributeCommonInfo &CI, Expr *E, Expr *OE) {\n if (!E->isValueDependent()) {\n if (!(I = E->getIntegerConstantExpr(Context))) {\n if (OE)\n else\n Diag(AttrLoc, diag::err_attribute_argument_type) << &TmpAttr << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{q,2100,"static void handleCPUSpecificAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,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;"},{q,6892,"static void handleSwiftNewType(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,7223,"static void handleHLSLResourceBindingAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgIdent(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,7236,"static void handleHLSLResourceBindingAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() == 2) {\n if (!AL.isArgIdent(1)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIdentifier;"},{q,7402,"static void handleMSP430InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgExpr(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant;"},{q,7410,"static void handleMSP430InterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!(NumParams = NumParamsExpr->getIntegerConstantExpr(S.Context))) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant << NumParamsExpr->getSourceRange();"},{q,7490,"static void handleM68kInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.isArgExpr(0)) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant;"},{q,7500,"static void handleM68kInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!MaybeNumParams) {\n S.Diag(AL.getLoc(), diag::err_attribute_argument_type) << AL << AANT_ArgumentIntegerConstant << NumParamsExpr->getSourceRange();"},{q,8592,"static void handleCFGuardAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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 if (A.getNumArgs() == 1) {\n if (!(ArgVal = E->getIntegerConstantExpr(S.Context))) {\n S.Diag(A.getLoc(), diag::err_attribute_argument_type) << A << AANT_ArgumentIntegerConstant << E->getSourceRange();"},{t,2729,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n if (!VecSize) {\n Diag(AttrLoc, diag::err_attribute_argument_type) << \"vector_size\" << AANT_ArgumentIntegerConstant << SizeExpr->getSourceRange();"},{t,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 if (!ArraySize->isTypeDependent() && !ArraySize->isValueDependent()) {\n if (!vecSize) {\n Diag(AttrLoc, diag::err_attribute_argument_type) << \"ext_vector_type\" << AANT_ArgumentIntegerConstant << ArraySize->getSourceRange();"},{t,2861,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\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;"},{t,2869,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n // Only the row expression is invalid.\n if (!ValueRows) {\n Diag(AttrLoc, diag::err_attribute_argument_type) << \"matrix_type\" << AANT_ArgumentIntegerConstant << RowRange;"},{t,2876,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n // Only the column expression is invalid.\n if (!ValueColumns) {\n Diag(AttrLoc, diag::err_attribute_argument_type) << \"matrix_type\" << AANT_ArgumentIntegerConstant << ColRange;"},{t,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 if (!OptAddrSpace) {\n S.Diag(AttrLoc, diag::err_attribute_argument_type) << \"\'address_space\'\" << AANT_ArgumentIntegerConstant << AddrSpace->getSourceRange();"},{t,6804,"static void HandleBTFTypeTagAttribute(QualType &Type, const ParsedAttr &Attr, TypeProcessingState &State) {\n if (!StrLiteral) {\n S.Diag(Attr.getLoc(), diag::err_attribute_argument_type) << Attr << AANT_ArgumentString;"},{t,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 if (!attr.isArgIdent(0)) {\n S.Diag(AttrLoc, diag::err_attribute_argument_type) << attr << AANT_ArgumentString;"},{t,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 // Check the attribute arguments.\n if (!attr.isArgIdent(0)) {\n S.Diag(attr.getLoc(), diag::err_attribute_argument_type) << attr << AANT_ArgumentString;"},{t,8184,"static bool verifyValidIntegerConstantExpr(Sema &S, const ParsedAttr &Attr, llvm::APSInt &Result) {\n S.Diag(Attr.getLoc(), diag::err_attribute_argument_type) << Attr << AANT_ArgumentIntegerConstant << AttrExpr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,906: | Line 3,926: | ||
}, | }, | ||
["err_attribute_arm_builtin_alias"]={ | ["err_attribute_arm_builtin_alias"]={ | ||
[e]="\'__clang_arm_builtin_alias\' attribute can only be applied to an ARM builtin", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'__clang_arm_builtin_alias\' attribute can only be applied to an ARM builtin", | [h]="\'__clang_arm_builtin_alias\' attribute can only be applied to an ARM builtin", | ||
[ | [b]=n, | ||
[ | [j]="\'__clang_arm_builtin_alias\' attribute can only be applied to an ARM builtin", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={ib,1576908663,K,K}, | |||
[ | |||
[ | |||
[k]={{q,5826,"static void handleArmBuiltinAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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);"}}, | [k]={{q,5826,"static void handleArmBuiltinAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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);"}}, | ||
[o]={ | [o]={ | ||
Line 3,921: | Line 3,941: | ||
}, | }, | ||
["err_attribute_arm_feature_sve_bits_unsupported"]={ | ["err_attribute_arm_feature_sve_bits_unsupported"]={ | ||
[ | [e]="A is only supported when \'-msve-vector-bits=<bits>\' is specified with a value of 128, 256, 512, 1024 or 2048.", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 is only supported when \'-msve-vector-bits=<bits>\' is specified with a value of 128, 256, 512, 1024 or 2048.", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) is only supported when \'\\-msve\\-vector\\-bits\\=\\<bits\\>\' is specified with a value of 128, 256, 512, 1024 or 2048\\.", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={cb,1582847864,I,I}, | ||
[k]={{ | [k]={{t,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 // 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"]={ | ["err_attribute_arm_mve_polymorphism"]={ | ||
[e]="\'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE/NEON vector type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE/NEON vector type", | [h]="\'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE/NEON vector type", | ||
[ | [b]=n, | ||
[ | [j]="\'__clang_arm_mve_strict_polymorphism\' attribute can only be applied to an MVE\\/NEON vector type", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"6d485ff455ea",1576172311,"Improve static checks for sprintf and __builtin___sprintf_chk","Improve static checks for sprintf and __builtin___sprintf_chk"}, | |||
[ | [k]={{t,8322,"static void HandleArmMveStrictPolymorphismAttr(TypeProcessingState &State, QualType &CurType, ParsedAttr &Attr) {\n if (!VT || VT->getVectorKind() != VectorType::NeonVector) {\n State.getSema().Diag(Attr.getLoc(), diag::err_attribute_arm_mve_polymorphism);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,948: | Line 3,968: | ||
}, | }, | ||
["err_attribute_bad_neon_vector_size"]={ | ["err_attribute_bad_neon_vector_size"]={ | ||
[e]="Neon vector size must be 64 or 128 bits", | |||
[d]=l, | |||
[f]=m, | |||
[h]="Neon vector size must be 64 or 128 bits", | [h]="Neon vector size must be 64 or 128 bits", | ||
[ | [b]=n, | ||
[ | [j]="Neon vector size must be 64 or 128 bits", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"118baf76115b",1289867544,"Add support for \"neon_vector_type\" and \"neon_polyvector_type\" attributes","Add support for \"neon_vector_type\" and \"neon_polyvector_type\" attributes"}, | |||
[k]={{t,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 if (vecSize != 64 && vecSize != 128) {\n S.Diag(Attr.getLoc(), diag::err_attribute_bad_neon_vector_size) << CurType;"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 3,963: | Line 3,983: | ||
}, | }, | ||
["err_attribute_bad_rvv_vector_size"]={ | ["err_attribute_bad_rvv_vector_size"]={ | ||
[ | [e]="invalid RVV vector size \'A\', expected size is \'B\' based on LMUL of type and \'-mrvv-vector-bits\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid RVV vector size \'%0\', expected size is \'%1\' based on LMUL of type and \'-mrvv-vector-bits\'", | ||
[ | [b]=n, | ||
[ | [j]="invalid RVV vector size \'(.*?)\', expected size is \'(.*?)\' based on LMUL of type and \'\\-mrvv\\-vector\\-bits\'", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{ | [k]={{t,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 if (VecSize != ExpectedSize) {\n S.Diag(Attr.getLoc(), diag::err_attribute_bad_rvv_vector_size) << VecSize << ExpectedSize;"}} | ||
}, | }, | ||
["err_attribute_bad_sve_vector_size"]={ | ["err_attribute_bad_sve_vector_size"]={ | ||
[ | [e]="invalid SVE vector size \'A\', must match value set by \'-msve-vector-bits\' (\'B\')", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid SVE vector size \'%0\', must match value set by \'-msve-vector-bits\' (\'%1\')", | ||
[ | [b]=n, | ||
[ | [j]="invalid SVE vector size \'(.*?)\', must match value set by \'\\-msve\\-vector\\-bits\' \\(\'(.*?)\'\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={cb,1582847864,I,I}, | ||
[k]={{ | [k]={{t,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 // 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"]={ | ["err_attribute_bounds_for_function"]={ | ||
[ | [e]="A attribute references parameter B, but the function C has only D parameters", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute references parameter %1, but the function %2 has only %3 parameters", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute references parameter (.*?), but the function (.*?) has only (.*?) parameters", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={yb,1616787805,S,S}, | ||
[k]={{q,1075,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 1; I < AL.getNumArgs(); ++I) {\n if (Index > DeclFD->getNumParams()) {\n S.Diag(AL.getLoc(), diag::err_attribute_bounds_for_function) << AL << Index << DeclFD << DeclFD->getNumParams();"}}, | [k]={{q,1075,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 1; I < AL.getNumArgs(); ++I) {\n if (Index > DeclFD->getNumParams()) {\n S.Diag(AL.getLoc(), diag::err_attribute_bounds_for_function) << AL << Index << DeclFD << DeclFD->getNumParams();"}}, | ||
[o]={ | [o]={ | ||
Line 4,002: | Line 4,022: | ||
}, | }, | ||
["err_attribute_builtin_alias"]={ | ["err_attribute_builtin_alias"]={ | ||
[ | [e]="A attribute can only be applied to a ARM, HLSL or RISC-V builtin", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute can only be applied to a ARM, HLSL or RISC-V builtin", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute can only be applied to a ARM, HLSL or RISC\\-V builtin", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"b83b23275b74",1607502387,"Introduce -Wreserved-identifier","Introduce -Wreserved-identifier"}, | ||
[k]={{q,5859,"static void handleBuiltinAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"}} | [k]={{q,5859,"static void handleBuiltinAliasAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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"]={ | ["err_attribute_cleanup_arg_not_function"]={ | ||
[ | [e]="\'cleanup\' argument ...is not a ...function", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'cleanup\' argument %select{|%1 |%1 }0is not a %select{||single }0function", | ||
[ | [b]=n, | ||
[ | [j]="\'cleanup\' argument (?:|(.*?) |(.*?) )is not a (?:||single )function", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{q,3710,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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 if (!FD) {\n S.Diag(Loc, diag::err_attribute_cleanup_arg_not_function) << 1 << NI.getName();"},{q,3720,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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 } else if (auto *ULE = dyn_cast<UnresolvedLookupExpr>(E)) {\n if (!FD) {\n S.Diag(Loc, diag::err_attribute_cleanup_arg_not_function) << 2 << NI.getName();"},{q,3727,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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 } else if (auto *ULE = dyn_cast<UnresolvedLookupExpr>(E)) {\n } else {\n S.Diag(Loc, diag::err_attribute_cleanup_arg_not_function) << 0;"}}, | [k]={{q,3710,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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 if (!FD) {\n S.Diag(Loc, diag::err_attribute_cleanup_arg_not_function) << 1 << NI.getName();"},{q,3720,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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 } else if (auto *ULE = dyn_cast<UnresolvedLookupExpr>(E)) {\n if (!FD) {\n S.Diag(Loc, diag::err_attribute_cleanup_arg_not_function) << 2 << NI.getName();"},{q,3727,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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 } else if (auto *ULE = dyn_cast<UnresolvedLookupExpr>(E)) {\n } else {\n S.Diag(Loc, diag::err_attribute_cleanup_arg_not_function) << 0;"}}, | ||
[o]={ | [o]={ | ||
Line 4,029: | Line 4,049: | ||
}, | }, | ||
["err_attribute_cleanup_func_arg_incompatible_type"]={ | ["err_attribute_cleanup_func_arg_incompatible_type"]={ | ||
[ | [e]="\'cleanup\' function A parameter has type B which is incompatible with type C", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'cleanup\' function %0 parameter has %diff{type $ which is incompatible with type $|incompatible type}1,2", | ||
[ | [b]=n, | ||
[ | [j]="\'cleanup\' function (.*?) parameter has (?:type (.*?) which is incompatible with type (.*?)|incompatible type)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{q,3743,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"}}, | [k]={{q,3743,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"}}, | ||
[o]={ | [o]={ | ||
Line 4,044: | Line 4,064: | ||
}, | }, | ||
["err_attribute_cleanup_func_must_take_one_arg"]={ | ["err_attribute_cleanup_func_must_take_one_arg"]={ | ||
[ | [e]="\'cleanup\' function A must take 1 parameter", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'cleanup\' function %0 must take 1 parameter", | ||
[ | [b]=n, | ||
[ | [j]="\'cleanup\' function (.*?) must take 1 parameter", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{q,3732,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (FD->getNumParams() != 1) {\n S.Diag(Loc, diag::err_attribute_cleanup_func_must_take_one_arg) << NI.getName();"}}, | [k]={{q,3732,"static void handleCleanupAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (FD->getNumParams() != 1) {\n S.Diag(Loc, diag::err_attribute_cleanup_func_must_take_one_arg) << NI.getName();"}}, | ||
[o]={ | [o]={ | ||
Line 4,059: | Line 4,079: | ||
}, | }, | ||
["err_attribute_dll_ambiguous_default_ctor"]={ | ["err_attribute_dll_ambiguous_default_ctor"]={ | ||
[ | [e]="\'__declspec(dllexport)\' cannot be applied to more than one default constructor in A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'__declspec(dllexport)\' cannot be applied to more than one default constructor in %0", | ||
[ | [b]=n, | ||
[ | [j]="\'__declspec\\(dllexport\\)\' cannot be applied to more than one default constructor in (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"474b323a0387",1451540206,"[MSVC Compat] Diagnose multiple default ctors for dllexport\'d classes","[MSVC Compat] Diagnose multiple default ctors for dllexport\'d classes"}, | ||
[k]={{w,6298,"static void checkForMultipleExportedDefaultConstructors(Sema &S, CXXRecordDecl *Class) {\n for (Decl *Member : Class->decls()) {\n if (LastExportedDefaultCtor) {\n S.Diag(LastExportedDefaultCtor->getLocation(), diag::err_attribute_dll_ambiguous_default_ctor) << Class;"}}, | [k]={{w,6298,"static void checkForMultipleExportedDefaultConstructors(Sema &S, CXXRecordDecl *Class) {\n for (Decl *Member : Class->decls()) {\n if (LastExportedDefaultCtor) {\n S.Diag(LastExportedDefaultCtor->getLocation(), diag::err_attribute_dll_ambiguous_default_ctor) << Class;"}}, | ||
[o]={ | [o]={ | ||
Line 4,074: | Line 4,094: | ||
}, | }, | ||
["err_attribute_dll_deleted"]={ | ["err_attribute_dll_deleted"]={ | ||
[ | [e]="attribute A cannot be applied to a deleted function", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="attribute %q0 cannot be applied to a deleted function", | ||
[ | [b]=n, | ||
[ | [j]="attribute (.*?) cannot be applied to a deleted function", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"9de0a57687b9",1401382279,"Sema: Functions with dll attributes cannot be deleted","Sema: Functions with dll attributes cannot be deleted"}, | ||
[k]={{w,17831,"void Sema::SetDeclDeleted(Decl *Dcl, SourceLocation DelLoc) {\n // dllimport/dllexport cannot be deleted.\n if (const InheritableAttr *DLLAttr = getDLLAttr(Fn)) {\n Diag(Fn->getLocation(), diag::err_attribute_dll_deleted) << DLLAttr;"}}, | [k]={{w,17831,"void Sema::SetDeclDeleted(Decl *Dcl, SourceLocation DelLoc) {\n // dllimport/dllexport cannot be deleted.\n if (const InheritableAttr *DLLAttr = getDLLAttr(Fn)) {\n Diag(Fn->getLocation(), diag::err_attribute_dll_deleted) << DLLAttr;"}}, | ||
[o]={ | [o]={ | ||
Line 4,089: | Line 4,109: | ||
}, | }, | ||
["err_attribute_dll_lambda"]={ | ["err_attribute_dll_lambda"]={ | ||
[ | [e]="lambda cannot be declared A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="lambda cannot be declared %0", | ||
[ | [b]=n, | ||
[ | [j]="lambda cannot be declared (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"5869ec4c6c62",1442351130,"MS ABI: Don\'t allow dllexport/import on lambdas","MS ABI: Don\'t allow dllexport/import on lambdas"}, | ||
[k]={{q,2089,"static void handleCPUSpecificAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,8049,"static void handleDLLAttr(Sema &S, Decl *D, const ParsedAttr &A) {\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;"}}, | [k]={{q,2089,"static void handleCPUSpecificAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"},{q,8049,"static void handleDLLAttr(Sema &S, Decl *D, const ParsedAttr &A) {\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;"}}, | ||
[o]={ | [o]={ | ||
Line 4,104: | Line 4,124: | ||
}, | }, | ||
["err_attribute_dll_member_of_dll_class"]={ | ["err_attribute_dll_member_of_dll_class"]={ | ||
[ | [e]="attribute A cannot be applied to member of B class", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="attribute %q0 cannot be applied to member of %q1 class", | ||
[ | [b]=n, | ||
[ | [j]="attribute (.*?) cannot be applied to member of (.*?) class", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{w,6483,"/// Check class-level dllimport/dllexport attribute.\nvoid Sema::checkClassLevelDLLAttribute(CXXRecordDecl *Class) {\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 Diag(MemberAttr->getLocation(), diag::err_attribute_dll_member_of_dll_class) << MemberAttr << ClassAttr;"}}, | [k]={{w,6483,"/// Check class-level dllimport/dllexport attribute.\nvoid Sema::checkClassLevelDLLAttribute(CXXRecordDecl *Class) {\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 Diag(MemberAttr->getLocation(), diag::err_attribute_dll_member_of_dll_class) << MemberAttr << ClassAttr;"}}, | ||
[o]={ | [o]={ | ||
Line 4,119: | Line 4,139: | ||
}, | }, | ||
["err_attribute_dll_not_extern"]={ | ["err_attribute_dll_not_extern"]={ | ||
[ | [e]="A must have external linkage when declared B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%q0 must have external linkage when declared %q1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) must have external linkage when declared (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"8ca0bfc57ff5",1396277818,"Sema: Require external linkage for dll attributes","Sema: Require external linkage for dll attributes"}, | ||
[k]={{ | [k]={{s,7003,"static void checkAttributesAfterMerging(Sema &S, NamedDecl &ND) {\n if (const InheritableAttr *Attr = getDLLAttr(&ND)) {\n if ((ND.isExternallyVisible() && AnonNSInMicrosoftMode) || (!AnonNSInMicrosoftMode && (!ND.isExternallyVisible() || (VD && VD->isStaticLocal())))) {\n S.Diag(ND.getLocation(), diag::err_attribute_dll_not_extern) << &ND << Attr;"},{w,6467,"/// Check class-level dllimport/dllexport attribute.\nvoid Sema::checkClassLevelDLLAttribute(CXXRecordDecl *Class) {\n if (!Class->isExternallyVisible()) {\n Diag(Class->getLocation(), diag::err_attribute_dll_not_extern) << Class << ClassAttr;"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 4,134: | Line 4,154: | ||
}, | }, | ||
["err_attribute_dll_redeclaration"]={ | ["err_attribute_dll_redeclaration"]={ | ||
[ | [e]="redeclaration of A cannot add B attribute", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="redeclaration of %q0 cannot add %q1 attribute", | ||
[ | [b]=n, | ||
[ | [j]="redeclaration of (.*?) cannot add (.*?) attribute", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"82f0b06749e5",1396277775,"Sema: Check dll attributes on redeclarations","Sema: Check dll attributes on redeclarations"}, | ||
[k]={{ | [k]={{s,7093,"static void checkDLLAttributeRedeclaration(Sema &S, NamedDecl *OldDecl, NamedDecl *NewDecl, bool IsSpecialization, bool IsDefinition) {\n if (AddsAttr && !IsSpecialization && !OldDecl->isImplicit()) {\n unsigned DiagID = JustWarn ? diag::warn_attribute_dll_redeclaration : diag::err_attribute_dll_redeclaration;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,149: | Line 4,169: | ||
}, | }, | ||
["err_attribute_dll_thread_local"]={ | ["err_attribute_dll_thread_local"]={ | ||
[ | [e]="A cannot be thread local when declared B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%q0 cannot be thread local when declared %q1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) cannot be thread local when declared (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"5da21da4f6d7",1412405514,"MS ABI: Disallow dllimported/exported variables from having TLS","MS ABI: Disallow dllimported/exported variables from having TLS"}, | ||
[k]={{ | [k]={{s,14463,"/// FinalizeDeclaration - called by ParseDeclarationAfterDeclarator to perform\n/// any semantic actions necessary after any initializer has been attached.\nvoid Sema::FinalizeDeclaration(Decl *ThisDecl) {\n // dllimport/dllexport variables cannot be thread local, their TLS index\n // isn\'t exported with the variable.\n if (DLLAttr && VD->getTLSKind()) {\n if (F && getDLLAttr(F)) {\n } else {\n Diag(VD->getLocation(), diag::err_attribute_dll_thread_local) << VD << DLLAttr;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/dllexport.c"]={"clang/test/Sema/dllexport.c:59:36: error: \'ThreadLocalGlobal\' cannot be thread local when declared \'dllexport\'"} | ["clang/test/Sema/dllexport.c"]={"clang/test/Sema/dllexport.c:59:36: error: \'ThreadLocalGlobal\' cannot be thread local when declared \'dllexport\'"} | ||
Line 4,164: | Line 4,184: | ||
}, | }, | ||
["err_attribute_dllimport_data_definition"]={ | ["err_attribute_dllimport_data_definition"]={ | ||
[e]="definition of dllimport data", | |||
[d]=l, | |||
[f]=m, | |||
[h]="definition of dllimport data", | [h]="definition of dllimport data", | ||
[ | [b]=n, | ||
[ | [j]="definition of dllimport data", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"8e9791f62c45",1393450033,"Sema: Definition of dllimport globals is not allowed","Sema: Definition of dllimport globals is not allowed"}, | |||
[k]={{s,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 // dllimport cannot be used on variable definitions.\n if (VDecl->hasAttr<DLLImportAttr>() && !VDecl->isStaticDataMember()) {\n Diag(VDecl->getLocation(), diag::err_attribute_dllimport_data_definition);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,179: | Line 4,199: | ||
}, | }, | ||
["err_attribute_dllimport_function_definition"]={ | ["err_attribute_dllimport_function_definition"]={ | ||
[e]="dllimport cannot be applied to non-inline function definition", | |||
[d]=l, | |||
[f]=m, | |||
[h]="dllimport cannot be applied to non-inline function definition", | [h]="dllimport cannot be applied to non-inline function definition", | ||
[ | [b]=n, | ||
[ | [j]="dllimport cannot be applied to non\\-inline function definition", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"b0f2f146bb65",1400191669,"Allow dllimport/dllexport on inline functions and adjust the linkage.","Allow dllimport/dllexport on inline functions and adjust the linkage."}, | |||
[ | [k]={{s,15420,"Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D, SkipBodyInfo *SkipBody, FnBodyKind BodyKind) {\n // dllimport cannot be applied to non-inline function definitions.\n if (FD->hasAttr<DLLImportAttr>() && !FD->isInlined() && !FD->isTemplateInstantiation()) {\n Diag(FD->getLocation(), diag::err_attribute_dllimport_function_definition);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/MicrosoftExtensions.cpp"]={"clang/test/SemaCXX/MicrosoftExtensions.cpp:188:33: error: dllimport cannot be applied to non-inline function definition"} | ["clang/test/SemaCXX/MicrosoftExtensions.cpp"]={"clang/test/SemaCXX/MicrosoftExtensions.cpp:188:33: error: dllimport cannot be applied to non-inline function definition"} | ||
Line 4,194: | Line 4,214: | ||
}, | }, | ||
["err_attribute_dllimport_function_specialization_definition"]={ | ["err_attribute_dllimport_function_specialization_definition"]={ | ||
[e]="cannot define non-inline dllimport template specialization", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot define non-inline dllimport template specialization", | [h]="cannot define non-inline dllimport template specialization", | ||
[ | [b]=n, | ||
[ | [j]="cannot define non\\-inline dllimport template specialization", | ||
[c]=a, | |||
[i]=p, | |||
[g]={R,1625925174,B,B}, | |||
[ | [k]={{s,7130,"static void checkDLLAttributeRedeclaration(Sema &S, NamedDecl *OldDecl, NamedDecl *NewDecl, bool IsSpecialization, bool IsDefinition) {\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);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,209: | Line 4,229: | ||
}, | }, | ||
["err_attribute_dllimport_static_field_definition"]={ | ["err_attribute_dllimport_static_field_definition"]={ | ||
[e]="definition of dllimport static field not allowed", | |||
[d]=l, | |||
[f]=m, | |||
[h]="definition of dllimport static field not allowed", | [h]="definition of dllimport static field not allowed", | ||
[ | [b]=n, | ||
[ | [j]="definition of dllimport static field not allowed", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"078d2f89cd6a",1401382220,"Sema: Check dll attributes on static data members","Sema: Check dll attributes on static data members"}, | |||
[k]={{s,14446,"/// FinalizeDeclaration - called by ParseDeclarationAfterDeclarator to perform\n/// any semantic actions necessary after any initializer has been attached.\nvoid Sema::FinalizeDeclaration(Decl *ThisDecl) {\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 Diag(VD->getLocation(), IsClassTemplateMember ? diag::warn_attribute_dllimport_static_field_definition : diag::err_attribute_dllimport_static_field_definition);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,224: | Line 4,244: | ||
}, | }, | ||
["err_attribute_integers_only"]={ | ["err_attribute_integers_only"]={ | ||
[ | [e]="A attribute argument may only refer to a function parameter of integer type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute argument may only refer to a function parameter of integer type", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute argument may only refer to a function parameter of integer type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"a747027bc645",1482195942,"Add the alloc_size attribute to clang.","Add the alloc_size attribute to clang."}, | ||
[k]={{q,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 if (!ParamTy->isIntegerType() && !ParamTy->isCharType()) {\n S.Diag(SrcLoc, diag::err_attribute_integers_only) << AI << getFunctionOrMethodParamRange(D, Idx.getASTIndex());"},{q,1754,"void Sema::AddAllocAlignAttr(Decl *D, const AttributeCommonInfo &CI, Expr *ParamExpr) {\n if (!Ty->isDependentType() && !Ty->isIntegralType(Context) && !Ty->isAlignValT()) {\n Diag(ParamExpr->getBeginLoc(), diag::err_attribute_integers_only) << &TmpAttr << FuncDecl->getParamDecl(Idx.getASTIndex())->getSourceRange();"}}, | [k]={{q,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 if (!ParamTy->isIntegerType() && !ParamTy->isCharType()) {\n S.Diag(SrcLoc, diag::err_attribute_integers_only) << AI << getFunctionOrMethodParamRange(D, Idx.getASTIndex());"},{q,1754,"void Sema::AddAllocAlignAttr(Decl *D, const AttributeCommonInfo &CI, Expr *ParamExpr) {\n if (!Ty->isDependentType() && !Ty->isIntegralType(Context) && !Ty->isAlignValT()) {\n Diag(ParamExpr->getBeginLoc(), diag::err_attribute_integers_only) << &TmpAttr << FuncDecl->getParamDecl(Idx.getASTIndex())->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 4,239: | Line 4,259: | ||
}, | }, | ||
["err_attribute_invalid_argument"]={ | ["err_attribute_invalid_argument"]={ | ||
[ | [e]="... is an invalid argument to attribute A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{a reference type|an array type|a non-vector or non-vectorizable scalar type}0 is an invalid argument to attribute %1", | ||
[ | [b]=n, | ||
[ | [j]="(?:a reference type|an array type|a non\\-vector or non\\-vectorizable scalar type) is an invalid argument to attribute (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"d293cbd5fd44",1564077051,"Add lifetime categories attributes","Add lifetime categories attributes"}, | ||
[k]={{q,3271,"static void handleVecTypeHint(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!ParmType->isExtVectorType() && !ParmType->isFloatingType() && (ParmType->isBooleanType() || !ParmType->isIntegralType(S.getASTContext()))) {\n S.Diag(AL.getLoc(), diag::err_attribute_invalid_argument) << 2 << AL;"},{q,5236,"static void handleLifetimeCategoryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.hasParsedType()) {\n if (SelectIdx != ~0U) {\n S.Diag(AL.getLoc(), diag::err_attribute_invalid_argument) << SelectIdx << AL;"}}, | [k]={{q,3271,"static void handleVecTypeHint(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!ParmType->isExtVectorType() && !ParmType->isFloatingType() && (ParmType->isBooleanType() || !ParmType->isIntegralType(S.getASTContext()))) {\n S.Diag(AL.getLoc(), diag::err_attribute_invalid_argument) << 2 << AL;"},{q,5236,"static void handleLifetimeCategoryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.hasParsedType()) {\n if (SelectIdx != ~0U) {\n S.Diag(AL.getLoc(), diag::err_attribute_invalid_argument) << SelectIdx << AL;"}}, | ||
[o]={ | [o]={ | ||
Line 4,254: | Line 4,274: | ||
}, | }, | ||
["err_attribute_invalid_bitint_vector_type"]={ | ["err_attribute_invalid_bitint_vector_type"]={ | ||
[ | [e]="\'_BitInt\' vector element width must be ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'_BitInt\' vector element width must be %select{a power of 2|at least as wide as \'CHAR_BIT\'}0", | ||
[ | [b]=n, | ||
[ | [j]="\'_BitInt\' vector element width must be (?:a power of 2|at least as wide as \'CHAR_BIT\')", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{ | [k]={{t,2716,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n // Only support _BitInt elements with byte-sized power of 2 NumBits.\n if (const auto *BIT = CurType->getAs<BitIntType>()) {\n if (!llvm::isPowerOf2_32(NumBits) || NumBits < 8) {\n Diag(AttrLoc, diag::err_attribute_invalid_bitint_vector_type) << (NumBits < 8);"},{t,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 // Only support _BitInt elements with byte-sized power of 2 NumBits.\n if (T->isBitIntType()) {\n if (!llvm::isPowerOf2_32(NumBits) || NumBits < 8) {\n Diag(AttrLoc, diag::err_attribute_invalid_bitint_vector_type) << (NumBits < 8);"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,269: | Line 4,289: | ||
}, | }, | ||
["err_attribute_invalid_implicit_this_argument"]={ | ["err_attribute_invalid_implicit_this_argument"]={ | ||
[ | [e]="A attribute is invalid for the implicit this argument", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute is invalid for the implicit this argument", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute is invalid for the implicit this argument", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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"}, | ||
[k]={{q,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 if (HasImplicitThisParam && !CanIndexImplicitThis) {\n if (IdxSource == 1) {\n S.Diag(getAttrLoc(AI), diag::err_attribute_invalid_implicit_this_argument) << &AI << IdxExpr->getSourceRange();"}}, | [k]={{q,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 if (HasImplicitThisParam && !CanIndexImplicitThis) {\n if (IdxSource == 1) {\n S.Diag(getAttrLoc(AI), diag::err_attribute_invalid_implicit_this_argument) << &AI << IdxExpr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 4,284: | Line 4,304: | ||
}, | }, | ||
["err_attribute_invalid_matrix_type"]={ | ["err_attribute_invalid_matrix_type"]={ | ||
[ | [e]="invalid matrix element type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid matrix element type %0", | ||
[ | [b]=n, | ||
[ | [j]="invalid matrix element type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={ib,1576908663,K,K}, | ||
[k]={{ | [k]={{t,2842,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\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;"}}, | ||
[o]={ | [o]={ | ||
["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 *\')"} | ["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 *\')"} | ||
Line 4,299: | Line 4,319: | ||
}, | }, | ||
["err_attribute_invalid_on_decl"]={ | ["err_attribute_invalid_on_decl"]={ | ||
[ | [e]="A... cannot be applied to a declaration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0%select{ attribute|}1 cannot be applied to a declaration", | ||
[ | [b]=n, | ||
[ | [j]="(.*?)(?: attribute|) cannot be applied to a declaration", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{q,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 default:\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 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 OS << \" S.Diag(AL.getLoc(), diag::err_attribute_invalid_on_decl)\\n\";"}}, | [k]={{q,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 default:\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 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 OS << \" S.Diag(AL.getLoc(), diag::err_attribute_invalid_on_decl)\\n\";"}}, | ||
[o]={ | [o]={ | ||
Line 4,314: | Line 4,334: | ||
}, | }, | ||
["err_attribute_invalid_rvv_type"]={ | ["err_attribute_invalid_rvv_type"]={ | ||
[ | [e]="A attribute applied to non-RVV type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute applied to non-RVV type %1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute applied to non\\-RVV type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{ | [k]={{t,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 // 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;"}}, | ||
[o]={ | [o]={ | ||
["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\'"} | ["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\'"} | ||
Line 4,329: | Line 4,349: | ||
}, | }, | ||
["err_attribute_invalid_size"]={ | ["err_attribute_invalid_size"]={ | ||
[e]="vector size not an integral multiple of component size", | |||
[d]=l, | |||
[f]=m, | |||
[h]="vector size not an integral multiple of component size", | [h]="vector size not an integral multiple of component size", | ||
[ | [b]=n, | ||
[ | [j]="vector size not an integral multiple of component size", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={E,1236199783,F,C}, | |||
[k]={{t,2756,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n if (!TypeSize || VectorSizeBits % TypeSize) {\n Diag(AttrLoc, diag::err_attribute_invalid_size) << SizeExpr->getSourceRange();"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCUDA/amdgpu-bf16.cu"]={"clang/test/SemaCUDA/amdgpu-bf16.cu:57:35: error: vector size not an integral multiple of component size"} | ["clang/test/SemaCUDA/amdgpu-bf16.cu"]={"clang/test/SemaCUDA/amdgpu-bf16.cu:57:35: error: vector size not an integral multiple of component size"} | ||
Line 4,344: | Line 4,364: | ||
}, | }, | ||
["err_attribute_invalid_sve_type"]={ | ["err_attribute_invalid_sve_type"]={ | ||
[ | [e]="A attribute applied to non-SVE type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute applied to non-SVE type %1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute applied to non\\-SVE type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={cb,1582847864,I,I}, | ||
[k]={{ | [k]={{t,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 // 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;"}}, | ||
[o]={ | [o]={ | ||
["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\')"} | ["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\')"} | ||
Line 4,359: | Line 4,379: | ||
}, | }, | ||
["err_attribute_invalid_vector_type"]={ | ["err_attribute_invalid_vector_type"]={ | ||
[ | [e]="invalid vector element type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid vector element type %0", | ||
[ | [b]=n, | ||
[ | [j]="invalid vector element type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{t,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;"},{t,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 if ((!T->isDependentType() && !T->isIntegerType() && !T->isRealFloatingType()) || (IsNoBoolVecLang && T->isBooleanType())) {\n Diag(AttrLoc, diag::err_attribute_invalid_vector_type) << T;"},{t,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 // 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;"}}, | ||
[o]={ | [o]={ | ||
["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)"} | ["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)"} | ||
Line 4,374: | Line 4,394: | ||
}, | }, | ||
["err_attribute_missing_on_first_decl"]={ | ["err_attribute_missing_on_first_decl"]={ | ||
[ | [e]="A attribute does not appear on the first declaration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute does not appear on the first declaration", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute does not appear on the first declaration", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={hc,1615397021,lb,lb}, | ||
[k]={{ | [k]={{s,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 if (const auto *ILA = New->getAttr<InternalLinkageAttr>())\n if (!Old->hasAttr<InternalLinkageAttr>()) {\n Diag(New->getLocation(), diag::err_attribute_missing_on_first_decl) << ILA;"},{s,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 if (auto *EA = New->getAttr<ErrorAttr>()) {\n if (!Old->hasAttr<ErrorAttr>()) {\n Diag(EA->getLocation(), diag::err_attribute_missing_on_first_decl) << EA;"},{s,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 if (getLangOpts().CPlusPlus) {\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;"},{s,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 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]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,389: | Line 4,409: | ||
}, | }, | ||
["err_attribute_multiple_objc_gc"]={ | ["err_attribute_multiple_objc_gc"]={ | ||
[e]="multiple garbage collection attributes specified for type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="multiple garbage collection attributes specified for type", | [h]="multiple garbage collection attributes specified for type", | ||
[ | [b]=n, | ||
[ | [j]="multiple garbage collection attributes specified for type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{t,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 if (type.getObjCGCAttr() != Qualifiers::GCNone) {\n S.Diag(attr.getLoc(), diag::err_attribute_multiple_objc_gc);"}} | |||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_attribute_no_builtin_on_defaulted_deleted_function"]={ | ["err_attribute_no_builtin_on_defaulted_deleted_function"]={ | ||
[ | [e]="A attribute has no effect on defaulted or deleted functions", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute has no effect on defaulted or deleted functions", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute has no effect on defaulted or deleted functions", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"bd8791610948",1569403888,Rb,Rb}, | ||
[k]={{ | [k]={{s,10801,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\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 case FunctionDefinitionKind::Deleted:\n Diag(NBA->getLocation(), diag::err_attribute_no_builtin_on_defaulted_deleted_function) << NBA->getSpelling();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,416: | Line 4,436: | ||
}, | }, | ||
["err_attribute_no_builtin_on_non_definition"]={ | ["err_attribute_no_builtin_on_non_definition"]={ | ||
[ | [e]="A attribute is permitted on definitions only", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute is permitted on definitions only", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute is permitted on definitions only", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"bd8791610948",1569403888,Rb,Rb}, | ||
[k]={{ | [k]={{s,10805,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\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 case FunctionDefinitionKind::Declaration:\n Diag(NBA->getLocation(), diag::err_attribute_no_builtin_on_non_definition) << NBA->getSpelling();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,431: | Line 4,451: | ||
}, | }, | ||
["err_attribute_no_builtin_wildcard_or_builtin_name"]={ | ["err_attribute_no_builtin_wildcard_or_builtin_name"]={ | ||
[ | [e]="empty A cannot be composed with named ones", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="empty %0 cannot be composed with named ones", | ||
[ | [b]=n, | ||
[ | [j]="empty (.*?) cannot be composed with named ones", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"bd8791610948",1569403888,Rb,Rb}, | ||
[k]={{q,1164,"static void handleNoBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"}}, | [k]={{q,1164,"static void handleNoBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"}}, | ||
[o]={ | [o]={ | ||
Line 4,446: | Line 4,466: | ||
}, | }, | ||
["err_attribute_no_member_function"]={ | ["err_attribute_no_member_function"]={ | ||
[ | [e]="A attribute cannot be applied to non-static member functions", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute cannot be applied to non-static member functions", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute cannot be applied to non\\-static member functions", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={yb,1616787805,S,S}, | ||
[k]={{q,1025,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"}}, | [k]={{q,1025,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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;"}}, | ||
[o]={ | [o]={ | ||
Line 4,461: | Line 4,481: | ||
}, | }, | ||
["err_attribute_no_member_pointers"]={ | ["err_attribute_no_member_pointers"]={ | ||
[ | [e]="A attribute cannot be used with pointers to members", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute cannot be used with pointers to members", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute cannot be used with pointers to members", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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."}, | ||
[k]={{ | [k]={{t,7380,"static bool handleMSPointerTypeQualifierAttr(TypeProcessingState &State, ParsedAttr &PAttr, QualType &Type) {\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;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/MicrosoftCompatibility.cpp"]={"clang/test/Sema/MicrosoftCompatibility.cpp:10:15: error: \'__uptr\' attribute cannot be used with pointers to members"} | ["clang/test/Sema/MicrosoftCompatibility.cpp"]={"clang/test/Sema/MicrosoftCompatibility.cpp:10:15: error: \'__uptr\' attribute cannot be used with pointers to members"} | ||
Line 4,476: | Line 4,496: | ||
}, | }, | ||
["err_attribute_not_clinkage"]={ | ["err_attribute_not_clinkage"]={ | ||
[ | [e]="function type with A attribute must have C linkage", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="function type with %0 attribute must have C linkage", | ||
[ | [b]=n, | ||
[ | [j]="function type with (.*?) attribute must have C linkage", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={ib,1576908663,K,K}, | ||
[k]={{q,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;"}}, | [k]={{q,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;"}}, | ||
[o]={ | [o]={ | ||
Line 4,491: | Line 4,511: | ||
}, | }, | ||
["err_attribute_not_import_attr"]={ | ["err_attribute_not_import_attr"]={ | ||
[ | [e]="A attribute cannot be applied to a module import", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute cannot be applied to a module import", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute cannot be applied to a module import", | ||
[ | [c]=a, | ||
[ | [i]="Modules Issue", | ||
[ | [g]={"49cc1ccb00df",1471557582,"C++ Modules TS: Add parsing support for module import declaration.","C++ Modules TS: Add parsing support for module import declaration."}, | ||
[k]={{ | [k]={{lc,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 ProhibitCXX11Attributes(Attrs, diag::err_attribute_not_import_attr, diag::err_keyword_not_import_attr,"}} | ||
}, | }, | ||
["err_attribute_not_module_attr"]={ | ["err_attribute_not_module_attr"]={ | ||
[ | [e]="A attribute cannot be applied to a module", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute cannot be applied to a module", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute cannot be applied to a module", | ||
[ | [c]=a, | ||
[ | [i]="Modules Issue", | ||
[ | [g]={"964cc53d9a74",1471570986,"C++ Modules TS: support parsing the \'module\' declaration (including extensions","C++ Modules TS: support parsing the \'module\' declaration (including extensions"}, | ||
[k]={{ | [k]={{lc,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 ProhibitCXX11Attributes(Attrs, diag::err_attribute_not_module_attr, diag::err_keyword_not_module_attr,"}} | ||
}, | }, | ||
["err_attribute_not_supported_in_lang"]={ | ["err_attribute_not_supported_in_lang"]={ | ||
[ | [e]="A attribute is not supported in ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute is not supported in %select{C|C++|Objective-C}1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute is not supported in (?:C|C\\+\\+|Objective\\-C)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"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."}, | ||
[k]={{q,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;"},{q,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;"},{q,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;"}}, | [k]={{q,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;"},{q,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;"},{q,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;"}}, | ||
[o]={ | [o]={ | ||
Line 4,530: | Line 4,550: | ||
}, | }, | ||
["err_attribute_not_supported_on_arch"]={ | ["err_attribute_not_supported_on_arch"]={ | ||
[ | [e]="A attribute is not supported on \'B\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute is not supported on \'%1\'", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute is not supported on \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"b51bcaf2f027",1491578027,"Sema: prevent __declspec(naked) use on x64","Sema: prevent __declspec(naked) use on x64"}, | ||
[k]={{q,2165,"static void handleNakedAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isDeclspecAttribute()) {\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();"}}, | [k]={{q,2165,"static void handleNakedAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isDeclspecAttribute()) {\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();"}}, | ||
[o]={ | [o]={ | ||
Line 4,545: | Line 4,565: | ||
}, | }, | ||
["err_attribute_not_type_attr"]={ | ["err_attribute_not_type_attr"]={ | ||
[ | [e]="A... cannot be applied to types", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0%select{ attribute|}1 cannot be applied to types", | ||
[ | [b]=n, | ||
[ | [j]="(.*?)(?: attribute|) cannot be applied to types", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"10876ef5714f",1358386242,"Implement C++11 semantics for [[noreturn]] attribute. This required splitting","Implement C++11 semantics for [[noreturn]] attribute. This required splitting"}, | ||
[k]={{ | [k]={{H,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 while (true) {\n DoneWithDeclSpec:\n if (!AttrsLastTime)\n else {\n // Reject C++11 / C2x attributes that aren\'t type attributes.\n for (const ParsedAttr &PA : attrs) {\n Diag(PA.getLoc(), diag::err_attribute_not_type_attr) << PA << PA.isRegularKeywordAttribute();"},{t,8571,"static void processTypeAttrs(TypeProcessingState &state, QualType &type, TypeAttrLocation TAL, const ParsedAttributesView &attrs) {\n for (ParsedAttr &attr : AttrsCopy) {\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();"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,560: | Line 4,580: | ||
}, | }, | ||
["err_attribute_only_once_per_parameter"]={ | ["err_attribute_only_once_per_parameter"]={ | ||
[ | [e]="A attribute can only be applied once per parameter", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute can only be applied once per parameter", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute can only be applied once per parameter", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3e3bb95b6951",1449093488,Sb,Sb}, | ||
[k]={{q,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;"}}, | [k]={{q,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;"}}, | ||
[o]={ | [o]={ | ||
Line 4,575: | Line 4,595: | ||
}, | }, | ||
["err_attribute_output_parameter"]={ | ["err_attribute_output_parameter"]={ | ||
[e]="attribute only applies to output parameters", | |||
[d]=l, | |||
[f]=m, | |||
[h]="attribute only applies to output parameters", | [h]="attribute only applies to output parameters", | ||
[ | [b]=n, | ||
[ | [j]="attribute only applies to output parameters", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"fe17b30a7957",1575504770,"[attributes][analyzer] Add annotations for handles.","[attributes][analyzer] Add annotations for handles."}, | |||
[ | |||
[ | |||
[k]={{q,8564,"static void handleAcquireHandleAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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();"}}, | [k]={{q,8564,"static void handleAcquireHandleAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\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();"}}, | ||
[o]={ | [o]={ | ||
Line 4,590: | Line 4,610: | ||
}, | }, | ||
["err_attribute_overloadable_mismatch"]={ | ["err_attribute_overloadable_mismatch"]={ | ||
[ | [e]="redeclaration of A must ...have the \'overloadable\' attribute", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="redeclaration of %0 must %select{not |}1have the \'overloadable\' attribute", | ||
[ | [b]=n, | ||
[ | [j]="redeclaration of (.*?) must (?:not |)have the \'overloadable\' attribute", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"d3cf025ae221",1498599091,"[Sema] Allow unmarked overloadable functions.","[Sema] Allow unmarked overloadable functions."}, | ||
[k]={{ | [k]={{s,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 if (!getLangOpts().CPlusPlus) {\n if (OldOvl != New->hasAttr<OverloadableAttr>() && !Old->isImplicit()) {\n Diag(New->getLocation(), diag::err_attribute_overloadable_mismatch) << New << OldOvl;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,605: | Line 4,625: | ||
}, | }, | ||
["err_attribute_overloadable_multiple_unmarked_overloads"]={ | ["err_attribute_overloadable_multiple_unmarked_overloads"]={ | ||
[e]="at most one overload for a given name may lack the \'overloadable\' attribute", | |||
[d]=l, | |||
[f]=m, | |||
[h]="at most one overload for a given name may lack the \'overloadable\' attribute", | [h]="at most one overload for a given name may lack the \'overloadable\' attribute", | ||
[ | [b]=n, | ||
[ | [j]="at most one overload for a given name may lack the \'overloadable\' attribute", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"d3cf025ae221",1498599091,"[Sema] Allow unmarked overloadable functions.","[Sema] Allow unmarked overloadable functions."}, | |||
[k]={{s,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 if (Redeclaration) {\n } else if (!getLangOpts().CPlusPlus && MayNeedOverloadableChecks && !NewFD->getAttr<OverloadableAttr>()) {\n if (OtherUnmarkedIter != Previous.end()) {\n Diag(NewFD->getLocation(), diag::err_attribute_overloadable_multiple_unmarked_overloads);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,620: | Line 4,640: | ||
}, | }, | ||
["err_attribute_overloadable_no_prototype"]={ | ["err_attribute_overloadable_no_prototype"]={ | ||
[ | [e]="\'overloadable\' function A must have a prototype", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'overloadable\' function %0 must have a prototype", | ||
[ | [b]=n, | ||
[ | [j]="\'overloadable\' function (.*?) must have a prototype", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{s,10621,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\n if (NewFD->hasAttr<OverloadableAttr>() && !NewFD->getType()->getAs<FunctionProtoType>()) {\n Diag(NewFD->getLocation(), diag::err_attribute_overloadable_no_prototype) << NewFD;"}}, | ||
[o]={ | [o]={ | ||
["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"} | ["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"} | ||
Line 4,635: | Line 4,655: | ||
}, | }, | ||
["err_attribute_parameter_types"]={ | ["err_attribute_parameter_types"]={ | ||
[ | [e]="A attribute parameter types do not match: parameter B of function C has type D, but parameter E of function F has type G", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute parameter types do not match: parameter %1 of function %2 has type %3, but parameter %4 of function %5 has type %6", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute parameter types do not match\\: parameter (.*?) of function (.*?) has type (.*?), but parameter (.*?) of function (.*?) has type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={yb,1616787805,S,S}, | ||
[k]={{q,1085,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 1; I < AL.getNumArgs(); ++I) {\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;"}}, | [k]={{q,1085,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 1; I < AL.getNumArgs(); ++I) {\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;"}}, | ||
[o]={ | [o]={ | ||
Line 4,650: | Line 4,670: | ||
}, | }, | ||
["err_attribute_pointers_only"]={ | ["err_attribute_pointers_only"]={ | ||
[ | [e]="A attribute only applies to... pointer arguments", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute only applies to%select{| constant}1 pointer arguments", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute only applies to(?:| constant) pointer arguments", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e4a5a90e8d6b",1345162118,"Add support for \"type safety\" attributes that allow checking that \'void *\'","Add support for \"type safety\" attributes that allow checking that \'void *\'"}, | ||
[k]={{ | [k]={{u,16689,"/// 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 for (ParmVarDecl *Param : Parameters) {\n // Parameters with the pass_object_size attribute only need to be marked\n // constant at function definitions. Because we lack information about\n // whether we\'re on a declaration or definition when we\'re instantiating the\n // attribute, we need to check for constness here.\n if (const auto *Attr = Param->getAttr<PassObjectSizeAttr>())\n if (!Param->getType().isConstQualified())\n Diag(Param->getLocation(), diag::err_attribute_pointers_only) << Attr->getSpelling() << 1;"},{q,1198,"static void handlePassObjectSizeAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // pass_object_size is only supported on constant pointer parameters; as a\n // kindness to users, we allow the parameter to be non-const for declarations.\n // At this point, we have no clue if `D` belongs to a function declaration or\n // definition, so we defer the constness check until later.\n if (!cast<ParmVarDecl>(D)->getType()->isPointerType()) {\n S.Diag(D->getBeginLoc(), diag::err_attribute_pointers_only) << AL << 1;"},{q,5686,"static void handleArgumentWithTypeTagAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (IsPointer) {\n if (ArgumentIdxAST >= getFunctionOrMethodNumParams(D) || !getFunctionOrMethodParamType(D, ArgumentIdxAST)->isPointerType())\n S.Diag(AL.getLoc(), diag::err_attribute_pointers_only) << AL << 0;"},{t,7382,"static bool handleMSPointerTypeQualifierAttr(TypeProcessingState &State, ParsedAttr &PAttr, QualType &Type) {\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 else\n S.Diag(PAttr.getLoc(), diag::err_attribute_pointers_only) << PAttr << 0;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/attr-ownership.c"]={"clang/test/Sema/attr-ownership.c:14:32: error: \'ownership_holds\' attribute only applies to pointer arguments"} | ["clang/test/Sema/attr-ownership.c"]={"clang/test/Sema/attr-ownership.c:14:32: error: \'ownership_holds\' attribute only applies to pointer arguments"} | ||
Line 4,665: | Line 4,685: | ||
}, | }, | ||
["err_attribute_preferred_name_arg_invalid"]={ | ["err_attribute_preferred_name_arg_invalid"]={ | ||
[ | [e]="argument A to \'preferred_name\' attribute is not a typedef for a specialization of B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="argument %0 to \'preferred_name\' attribute is not a typedef for a specialization of %1", | ||
[ | [b]=n, | ||
[ | [j]="argument (.*?) to \'preferred_name\' attribute is not a typedef for a specialization of (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={sb,1590001902,T,T}, | ||
[k]={{q,1461,"static void handlePreferredName(Sema &S, Decl *D, const ParsedAttr &AL) {\n S.Diag(AL.getLoc(), diag::err_attribute_preferred_name_arg_invalid) << T << CTD;"}}, | [k]={{q,1461,"static void handlePreferredName(Sema &S, Decl *D, const ParsedAttr &AL) {\n S.Diag(AL.getLoc(), diag::err_attribute_preferred_name_arg_invalid) << T << CTD;"}}, | ||
[o]={ | [o]={ | ||
Line 4,680: | Line 4,700: | ||
}, | }, | ||
["err_attribute_regparm_invalid_number"]={ | ["err_attribute_regparm_invalid_number"]={ | ||
[ | [e]="\'regparm\' parameter must be between 0 and A inclusive", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'regparm\' parameter must be between 0 and %0 inclusive", | ||
[ | [b]=n, | ||
[ | [j]="\'regparm\' parameter must be between 0 and (.*?) inclusive", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"7044b7670747",1238188007,"Finish off semantic analysis for regparm, and remove the warning. Also ","Finish off semantic analysis for regparm, and remove the warning. Also "}, | ||
[k]={{q,5587,"/// Checks a regparm attribute, returning true if it is ill-formed and\n/// otherwise setting numParams to the appropriate value.\nbool Sema::CheckRegparmAttr(const ParsedAttr &AL, unsigned &numParams) {\n if (numParams > Context.getTargetInfo().getRegParmMax()) {\n Diag(AL.getLoc(), diag::err_attribute_regparm_invalid_number) << Context.getTargetInfo().getRegParmMax() << NumParamsExpr->getSourceRange();"}}, | [k]={{q,5587,"/// Checks a regparm attribute, returning true if it is ill-formed and\n/// otherwise setting numParams to the appropriate value.\nbool Sema::CheckRegparmAttr(const ParsedAttr &AL, unsigned &numParams) {\n if (numParams > Context.getTargetInfo().getRegParmMax()) {\n Diag(AL.getLoc(), diag::err_attribute_regparm_invalid_number) << Context.getTargetInfo().getRegParmMax() << NumParamsExpr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 4,695: | Line 4,715: | ||
}, | }, | ||
["err_attribute_regparm_wrong_platform"]={ | ["err_attribute_regparm_wrong_platform"]={ | ||
[e]="\'regparm\' is not valid on this platform", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'regparm\' is not valid on this platform", | [h]="\'regparm\' is not valid on this platform", | ||
[ | [b]=n, | ||
[ | [j]="\'regparm\' is not valid on this platform", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"7044b7670747",1238188007,"Finish off semantic analysis for regparm, and remove the warning. Also ","Finish off semantic analysis for regparm, and remove the warning. Also "}, | |||
[ | |||
[ | |||
[k]={{q,5579,"/// Checks a regparm attribute, returning true if it is ill-formed and\n/// otherwise setting numParams to the appropriate value.\nbool Sema::CheckRegparmAttr(const ParsedAttr &AL, unsigned &numParams) {\n if (Context.getTargetInfo().getRegParmMax() == 0) {\n Diag(AL.getLoc(), diag::err_attribute_regparm_wrong_platform) << NumParamsExpr->getSourceRange();"}}, | [k]={{q,5579,"/// Checks a regparm attribute, returning true if it is ill-formed and\n/// otherwise setting numParams to the appropriate value.\nbool Sema::CheckRegparmAttr(const ParsedAttr &AL, unsigned &numParams) {\n if (Context.getTargetInfo().getRegParmMax() == 0) {\n Diag(AL.getLoc(), diag::err_attribute_regparm_wrong_platform) << NumParamsExpr->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 4,710: | Line 4,730: | ||
}, | }, | ||
["err_attribute_requires_arguments"]={ | ["err_attribute_requires_arguments"]={ | ||
[ | [e]="parentheses must be omitted if A attribute\'s argument list is empty", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="parentheses must be omitted if %0 attribute\'s argument list is empty", | ||
[ | [b]=n, | ||
[ | [j]="parentheses must be omitted if (.*?) attribute\'s argument list is empty", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"ef5d94caf067",1397522199,"Fixing a typo, updating the diagnostic wording and logic based on post-commit review feedback. Amend...","Fixing a typo, updating the diagnostic wording and logic based on post-commit review feedback. Amends r206186."}, | ||
[k]={{ | [k]={{H,743,"bool Parser::ParseMicrosoftDeclSpecArgs(IdentifierInfo *AttrName, SourceLocation AttrNameLoc, ParsedAttributes &Attrs) {\n // If this attribute\'s args were parsed, and it was expected to have\n // arguments but none were provided, emit a diagnostic.\n if (ExistingAttrs < Attrs.size() && Attrs.back().getMaxArgs() && !NumArgs) {\n Diag(OpenParenLoc, diag::err_attribute_requires_arguments) << AttrName;"},{P,4460,"/// ParseCXX11AttributeArgs -- Parse a C++11 attribute-argument-clause.\n///\n/// [C++11] attribute-argument-clause:\n/// \'(\' balanced-token-seq \')\'\n///\n/// [C++11] balanced-token-seq:\n/// balanced-token\n/// balanced-token-seq balanced-token\n///\n/// [C++11] balanced-token:\n/// \'(\' balanced-token-seq \')\'\n/// \'[\' balanced-token-seq \']\'\n/// \'{\' balanced-token-seq \'}\'\n/// any token but \'(\', \')\', \'[\', \']\', \'{\', or \'}\'\nbool Parser::ParseCXX11AttributeArgs(IdentifierInfo *AttrName, SourceLocation AttrNameLoc, ParsedAttributes &Attrs, SourceLocation *EndLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, CachedTokens &OpenMPTokens) {\n if (!Attrs.empty() && IsBuiltInOrStandardCXX11Attribute(AttrName, ScopeName)) {\n // If the attribute is a standard or built-in attribute and we are\n // parsing an argument list, we need to determine whether this attribute\n // was allowed to have an argument list (such as [[deprecated]]), and how\n // many arguments were parsed (so we can diagnose on [[deprecated()]]).\n if (Attr.getMaxArgs() && !NumArgs) {\n Diag(LParenLoc, diag::err_attribute_requires_arguments) << AttrName;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Parser/MicrosoftExtensions.c"]={"clang/test/Parser/MicrosoftExtensions.c:73:22: error: parentheses must be omitted if \'deprecated\' attribute\'s argument list is empty"} | ["clang/test/Parser/MicrosoftExtensions.c"]={"clang/test/Parser/MicrosoftExtensions.c:73:22: error: parentheses must be omitted if \'deprecated\' attribute\'s argument list is empty"} | ||
Line 4,725: | Line 4,745: | ||
}, | }, | ||
["err_attribute_requires_opencl_version"]={ | ["err_attribute_requires_opencl_version"]={ | ||
[ | [e]="attribute A is supported in the OpenCL version B...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="attribute %0 is supported in the OpenCL version %1%select{| onwards}2", | ||
[ | [b]=n, | ||
[ | [j]="attribute (.*?) is supported in the OpenCL version (.*?)(?:| onwards)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"6bdbcbb3d91b",1455906611,"[OpenCL] Generate metadata for opencl_unroll_hint attribute","[OpenCL] Generate metadata for opencl_unroll_hint attribute"}, | ||
[k]={{q,8281,"static void handleOpenCLNoSVMAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (S.LangOpts.getOpenCLCompatibleVersion() < 200)\n S.Diag(AL.getLoc(), diag::err_attribute_requires_opencl_version) << AL << \"2.0\" << 1;"}}, | [k]={{q,8281,"static void handleOpenCLNoSVMAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (S.LangOpts.getOpenCLCompatibleVersion() < 200)\n S.Diag(AL.getLoc(), diag::err_attribute_requires_opencl_version) << AL << \"2.0\" << 1;"}}, | ||
[o]={ | [o]={ | ||
Line 4,740: | Line 4,760: | ||
}, | }, | ||
["err_attribute_requires_positive_integer"]={ | ["err_attribute_requires_positive_integer"]={ | ||
[ | [e]="A attribute requires a ... integral compile time constant expression", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute requires a %select{positive|non-negative}1 integral compile time constant expression", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute requires a (?:positive|non\\-negative) integral compile time constant expression", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"6bdbcbb3d91b",1455906611,"[OpenCL] Generate metadata for opencl_unroll_hint attribute","[OpenCL] Generate metadata for opencl_unroll_hint attribute"}, | ||
[k]={{q,241,"/// 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 if (StrictlyUnsigned && I->isSigned() && I->isNegative()) {\n S.Diag(getAttrLoc(AI), diag::err_attribute_requires_positive_integer) << &AI << /*non-negative*/ 1;"},{"clang/lib/Sema/SemaStmtAttr.cpp",471,"static Attr *handleOpenCLUnrollHint(Sema &S, Stmt *St, const ParsedAttr &A, SourceRange Range) {\n if (A.getNumArgs() == 1) {\n if (Val <= 0) {\n S.Diag(A.getRange().getBegin(), diag::err_attribute_requires_positive_integer) << A << /* positive */ 0;"}}, | [k]={{q,241,"/// 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 if (StrictlyUnsigned && I->isSigned() && I->isNegative()) {\n S.Diag(getAttrLoc(AI), diag::err_attribute_requires_positive_integer) << &AI << /*non-negative*/ 1;"},{"clang/lib/Sema/SemaStmtAttr.cpp",471,"static Attr *handleOpenCLUnrollHint(Sema &S, Stmt *St, const ParsedAttr &A, SourceRange Range) {\n if (A.getNumArgs() == 1) {\n if (Val <= 0) {\n S.Diag(A.getRange().getBegin(), diag::err_attribute_requires_positive_integer) << A << /* positive */ 0;"}}, | ||
[o]={ | [o]={ | ||
Line 4,755: | Line 4,775: | ||
}, | }, | ||
["err_attribute_riscv_rvv_bits_unsupported"]={ | ["err_attribute_riscv_rvv_bits_unsupported"]={ | ||
[ | [e]="A is only supported when \'-mrvv-vector-bits=<bits>\' is specified with a value of \"zvl\" or a power 2 in the range [64,65536]", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 is only supported when \'-mrvv-vector-bits=<bits>\' is specified with a value of \"zvl\" or a power 2 in the range [64,65536]", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) is only supported when \'\\-mrvv\\-vector\\-bits\\=\\<bits\\>\' is specified with a value of \"zvl\" or a power 2 in the range \\[64,65536\\]", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{ | [k]={{t,8348,"/// 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 if (!VScale || !VScale->first || VScale->first != VScale->second) {\n S.Diag(Attr.getLoc(), diag::err_attribute_riscv_rvv_bits_unsupported) << Attr;"}} | ||
}, | }, | ||
["err_attribute_section_invalid_for_target"]={ | ["err_attribute_section_invalid_for_target"]={ | ||
[ | [e]="argument to ... attribute is not valid for this target: A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="argument to %select{\'code_seg\'|\'section\'}1 attribute is not valid for this target: %0", | ||
[ | [b]=n, | ||
[ | [j]="argument to (?:\'code_seg\'|\'section\') attribute is not valid for this target\\: (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"30ba674391ae",1249930984,"fix a couple of problems with section attributes:","fix a couple of problems with section attributes:"}, | ||
[k]={{q,3328,"bool Sema::checkSectionName(SourceLocation LiteralLoc, StringRef SecName) {\n if (llvm::Error E = isValidSectionSpecifier(SecName)) {\n Diag(LiteralLoc, diag::err_attribute_section_invalid_for_target) << toString(std::move(E)) << 1 /*\'section\'*/;"},{q,3362,"// This is used for `__declspec(code_seg(\"segname\"))` on a decl.\n// `#pragma code_seg(\"segname\")` uses checkSectionName() instead.\nstatic bool checkCodeSegName(Sema &S, SourceLocation LiteralLoc, StringRef CodeSegName) {\n if (llvm::Error E = S.isValidSectionSpecifier(CodeSegName)) {\n S.Diag(LiteralLoc, diag::err_attribute_section_invalid_for_target) << toString(std::move(E)) << 0 /*\'code-seg\'*/;"}}, | [k]={{q,3328,"bool Sema::checkSectionName(SourceLocation LiteralLoc, StringRef SecName) {\n if (llvm::Error E = isValidSectionSpecifier(SecName)) {\n Diag(LiteralLoc, diag::err_attribute_section_invalid_for_target) << toString(std::move(E)) << 1 /*\'section\'*/;"},{q,3362,"// This is used for `__declspec(code_seg(\"segname\"))` on a decl.\n// `#pragma code_seg(\"segname\")` uses checkSectionName() instead.\nstatic bool checkCodeSegName(Sema &S, SourceLocation LiteralLoc, StringRef CodeSegName) {\n if (llvm::Error E = S.isValidSectionSpecifier(CodeSegName)) {\n S.Diag(LiteralLoc, diag::err_attribute_section_invalid_for_target) << toString(std::move(E)) << 0 /*\'code-seg\'*/;"}}, | ||
[o]={ | [o]={ | ||
Line 4,782: | Line 4,802: | ||
}, | }, | ||
["err_attribute_selectany_non_extern_data"]={ | ["err_attribute_selectany_non_extern_data"]={ | ||
[e]="\'selectany\' can only be applied to data items with external linkage", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'selectany\' can only be applied to data items with external linkage", | [h]="\'selectany\' can only be applied to data items with external linkage", | ||
[ | [b]=n, | ||
[ | [j]="\'selectany\' can only be applied to data items with external linkage", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"b144d366934f",1369058557,"Implement __declspec(selectany) under -fms-extensions","Implement __declspec(selectany) under -fms-extensions"}, | |||
[k]={{s,6979,"static void checkAttributesAfterMerging(Sema &S, NamedDecl &ND) {\n // \'selectany\' only applies to externally visible variable declarations.\n // It does not apply to functions.\n if (SelectAnyAttr *Attr = ND.getAttr<SelectAnyAttr>()) {\n if (isa<FunctionDecl>(ND) || !ND.isExternallyVisible()) {\n S.Diag(Attr->getLocation(), diag::err_attribute_selectany_non_extern_data);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/declspec-selectany.cpp"]={"clang/test/SemaCXX/declspec-selectany.cpp:6:22: error: \'selectany\' can only be applied to data items with external linkage"} | ["clang/test/SemaCXX/declspec-selectany.cpp"]={"clang/test/SemaCXX/declspec-selectany.cpp:6:22: error: \'selectany\' can only be applied to data items with external linkage"} | ||
Line 4,797: | Line 4,817: | ||
}, | }, | ||
["err_attribute_sentinel_less_than_zero"]={ | ["err_attribute_sentinel_less_than_zero"]={ | ||
[e]="\'sentinel\' parameter 1 less than zero", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'sentinel\' parameter 1 less than zero", | [h]="\'sentinel\' parameter 1 less than zero", | ||
[ | [b]=n, | ||
[ | [j]="\'sentinel\' parameter 1 less than zero", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={E,1236199783,F,C}, | |||
[ | |||
[ | |||
[k]={{q,3060,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() > 0) {\n if (Idx->isSigned() && Idx->isNegative()) {\n S.Diag(AL.getLoc(), diag::err_attribute_sentinel_less_than_zero) << E->getSourceRange();"}}, | [k]={{q,3060,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() > 0) {\n if (Idx->isSigned() && Idx->isNegative()) {\n S.Diag(AL.getLoc(), diag::err_attribute_sentinel_less_than_zero) << E->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 4,812: | Line 4,832: | ||
}, | }, | ||
["err_attribute_sentinel_not_zero_or_one"]={ | ["err_attribute_sentinel_not_zero_or_one"]={ | ||
[e]="\'sentinel\' parameter 2 not 0 or 1", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'sentinel\' parameter 2 not 0 or 1", | [h]="\'sentinel\' parameter 2 not 0 or 1", | ||
[ | [b]=n, | ||
[ | [j]="\'sentinel\' parameter 2 not 0 or 1", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={E,1236199783,F,C}, | |||
[ | |||
[ | |||
[k]={{q,3082,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() > 1) {\n if ((Idx->isSigned() && Idx->isNegative()) || nullPos > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_sentinel_not_zero_or_one) << E->getSourceRange();"}}, | [k]={{q,3082,"static void handleSentinelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getNumArgs() > 1) {\n if ((Idx->isSigned() && Idx->isNegative()) || nullPos > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_sentinel_not_zero_or_one) << E->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 4,827: | Line 4,847: | ||
}, | }, | ||
["err_attribute_size_too_large"]={ | ["err_attribute_size_too_large"]={ | ||
[ | [e]="A size too large", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 size too large", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) size too large", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"efe9fa62f5b4",1374800027,"Tighten type-checking for vector attributes.","Tighten type-checking for vector attributes."}, | ||
[k]={{ | [k]={{t,2742,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n // vecSize is specified in bytes - convert to bits.\n if (!VecSize->isIntN(61)) {\n Diag(AttrLoc, diag::err_attribute_size_too_large) << SizeExpr->getSourceRange() << \"vector\";"},{t,2762,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n if (VectorSizeBits / TypeSize > std::numeric_limits<uint32_t>::max()) {\n Diag(AttrLoc, diag::err_attribute_size_too_large) << SizeExpr->getSourceRange() << \"vector\";"},{t,2814,"/// 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 if (!ArraySize->isTypeDependent() && !ArraySize->isValueDependent()) {\n if (!vecSize->isIntN(32)) {\n Diag(AttrLoc, diag::err_attribute_size_too_large) << ArraySize->getSourceRange() << \"vector\";"},{t,2898,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n if (!ConstantMatrixType::isDimensionValid(MatrixRows)) {\n Diag(AttrLoc, diag::err_attribute_size_too_large) << RowRange << \"matrix row\";"},{t,2903,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n if (!ConstantMatrixType::isDimensionValid(MatrixColumns)) {\n Diag(AttrLoc, diag::err_attribute_size_too_large) << ColRange << \"matrix column\";"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaTemplate/matrix-type.cpp"]={"clang/test/SemaTemplate/matrix-type.cpp:25:42: error: matrix row size too large"} | ["clang/test/SemaTemplate/matrix-type.cpp"]={"clang/test/SemaTemplate/matrix-type.cpp:25:42: error: matrix row size too large"} | ||
Line 4,842: | Line 4,862: | ||
}, | }, | ||
["err_attribute_sizeless_type"]={ | ["err_attribute_sizeless_type"]={ | ||
[ | [e]="A attribute cannot be applied to sizeless type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute cannot be applied to sizeless type %1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute cannot be applied to sizeless type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={ib,1576908663,K,K}, | ||
[k]={{q,4610,"void Sema::CheckAlignasUnderalignment(Decl *D) {\n if (Align && DiagTy->isSizelessType()) {\n Diag(LastAlignedAttr->getLocation(), diag::err_attribute_sizeless_type) << LastAlignedAttr << DiagTy;"}}, | [k]={{q,4610,"void Sema::CheckAlignasUnderalignment(Decl *D) {\n if (Align && DiagTy->isSizelessType()) {\n Diag(LastAlignedAttr->getLocation(), diag::err_attribute_sizeless_type) << LastAlignedAttr << DiagTy;"}}, | ||
[o]={ | [o]={ | ||
Line 4,857: | Line 4,877: | ||
}, | }, | ||
["err_attribute_too_few_arguments"]={ | ["err_attribute_too_few_arguments"]={ | ||
[ | [e]="A attribute takes at least B argumentC", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute takes at least %1 argument%s1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute takes at least (.*?) argument(.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"63fa667c6874",1311883955,"Added basic parsing for all remaining attributes, thread safety","Added basic parsing for all remaining attributes, thread safety"}, | ||
[k]={{"clang/lib/Sema/ParsedAttr.cpp",289,"bool ParsedAttr::checkAtLeastNumArgs(Sema &S, unsigned Num) const { return checkAttributeNumArgsImpl(S, *this, Num, diag::err_attribute_too_few_arguments, std::less<unsigned>()); }"},{q,1834,"static void handleOwnershipAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n case OwnershipAttr::Holds:\n if (AL.getNumArgs() < 2) {\n S.Diag(AL.getLoc(), diag::err_attribute_too_few_arguments) << AL << 2;"},{"clang/lib/Sema/SemaTemplateInstantiateDecl.cpp",215,"static void instantiateDependentAnnotationAttr(Sema &S, const MultiLevelTemplateArgumentList &TemplateArgs, const AnnotateAttr *Attr, Decl *New) {\n if (HasDelayedArgs) {\n if (Args.size() < 1) {\n S.Diag(Attr->getLoc(), diag::err_attribute_too_few_arguments) << Attr << 1;"},{ | [k]={{"clang/lib/Sema/ParsedAttr.cpp",289,"bool ParsedAttr::checkAtLeastNumArgs(Sema &S, unsigned Num) const { return checkAttributeNumArgsImpl(S, *this, Num, diag::err_attribute_too_few_arguments, std::less<unsigned>()); }"},{q,1834,"static void handleOwnershipAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n case OwnershipAttr::Holds:\n if (AL.getNumArgs() < 2) {\n S.Diag(AL.getLoc(), diag::err_attribute_too_few_arguments) << AL << 2;"},{"clang/lib/Sema/SemaTemplateInstantiateDecl.cpp",215,"static void instantiateDependentAnnotationAttr(Sema &S, const MultiLevelTemplateArgumentList &TemplateArgs, const AnnotateAttr *Attr, Decl *New) {\n if (HasDelayedArgs) {\n if (Args.size() < 1) {\n S.Diag(Attr->getLoc(), diag::err_attribute_too_few_arguments) << Attr << 1;"},{t,8478,"static void HandleAnnotateTypeAttr(TypeProcessingState &State, QualType &CurType, const ParsedAttr &PA) {\n if (PA.getNumArgs() < 1) {\n S.Diag(PA.getLoc(), diag::err_attribute_too_few_arguments) << PA << 1;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/warn-consumed-parsing.cpp"]={"clang/test/SemaCXX/warn-consumed-parsing.cpp:22:41: error: \'callable_when\' attribute takes at least 1 argument"} | ["clang/test/SemaCXX/warn-consumed-parsing.cpp"]={"clang/test/SemaCXX/warn-consumed-parsing.cpp:22:41: error: \'callable_when\' attribute takes at least 1 argument"} | ||
Line 4,872: | Line 4,892: | ||
}, | }, | ||
["err_attribute_too_many_arguments"]={ | ["err_attribute_too_many_arguments"]={ | ||
[ | [e]="A attribute takes no more than B argumentC", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute takes no more than %1 argument%s1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute takes no more than (.*?) argument(.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"80ee5963fde8",1299068105,"Pretty up the wrong-number-of-arguments-for-attribute diagnostic by","Pretty up the wrong-number-of-arguments-for-attribute diagnostic by"}, | ||
[k]={{"clang/lib/Sema/ParsedAttr.cpp",294,"bool ParsedAttr::checkAtMostNumArgs(Sema &S, unsigned Num) const { return checkAttributeNumArgsImpl(S, *this, Num, diag::err_attribute_too_many_arguments, std::greater<unsigned>()); }"},{q,1840,"static void handleOwnershipAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n case OwnershipAttr::Returns:\n if (AL.getNumArgs() > 2) {\n S.Diag(AL.getLoc(), diag::err_attribute_too_many_arguments) << AL << 1;"},{q,7354,"static void handleARMInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Check the attribute arguments.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_too_many_arguments) << AL << 1;"},{q,7431,"static void handleMipsInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Only one optional argument permitted.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_too_many_arguments) << AL << 1;"}}, | [k]={{"clang/lib/Sema/ParsedAttr.cpp",294,"bool ParsedAttr::checkAtMostNumArgs(Sema &S, unsigned Num) const { return checkAttributeNumArgsImpl(S, *this, Num, diag::err_attribute_too_many_arguments, std::greater<unsigned>()); }"},{q,1840,"static void handleOwnershipAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n case OwnershipAttr::Returns:\n if (AL.getNumArgs() > 2) {\n S.Diag(AL.getLoc(), diag::err_attribute_too_many_arguments) << AL << 1;"},{q,7354,"static void handleARMInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Check the attribute arguments.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_too_many_arguments) << AL << 1;"},{q,7431,"static void handleMipsInterruptAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Only one optional argument permitted.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_too_many_arguments) << AL << 1;"}}, | ||
[o]={ | [o]={ | ||
Line 4,887: | Line 4,907: | ||
}, | }, | ||
["err_attribute_unsupported"]={ | ["err_attribute_unsupported"]={ | ||
[ | [e]="A attribute is not supported on targets missing B; specify an appropriate -march= or -mcpu=", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute is not supported on targets missing %1; specify an appropriate -march= or -mcpu=", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute is not supported on targets missing (.*?); specify an appropriate \\-march\\= or \\-mcpu\\=", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"8c3de546d62e",1379354855,"Add error checking to reject neon_vector_type attribute on targets without NEON.","Add error checking to reject neon_vector_type attribute on targets without NEON."}, | ||
[k]={{ | [k]={{t,8211,"/// 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 // Target must have NEON (or MVE, whose vectors are similar enough\n // not to need a separate attribute)\n if (!(S.Context.getTargetInfo().hasFeature(\"neon\") || S.Context.getTargetInfo().hasFeature(\"mve\") || IsTargetCUDAAndHostARM)) {\n S.Diag(Attr.getLoc(), diag::err_attribute_unsupported) << Attr << \"\'neon\' or \'mve\'\";"},{t,8256,"/// 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 // Target must have SVE.\n if (!S.Context.getTargetInfo().hasFeature(\"sve\")) {\n S.Diag(Attr.getLoc(), diag::err_attribute_unsupported) << Attr << \"\'sve\'\";"},{t,8340,"/// 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 // Target must have vector extension.\n if (!S.Context.getTargetInfo().hasFeature(\"zve32x\")) {\n S.Diag(Attr.getLoc(), diag::err_attribute_unsupported) << Attr << \"\'zve32x\'\";"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/riscv-vector-types-support.c"]={"clang/test/Sema/riscv-vector-types-support.c:3:24: error: \'riscv_rvv_vector_bits\' attribute is not supported on targets missing \'zve32x\'; specify an appropriate -march= or -mcpu="} | ["clang/test/Sema/riscv-vector-types-support.c"]={"clang/test/Sema/riscv-vector-types-support.c:3:24: error: \'riscv_rvv_vector_bits\' attribute is not supported on targets missing \'zve32x\'; specify an appropriate -march= or -mcpu="} | ||
Line 4,902: | Line 4,922: | ||
}, | }, | ||
["err_attribute_uuid_malformed_guid"]={ | ["err_attribute_uuid_malformed_guid"]={ | ||
[e]="uuid attribute contains a malformed GUID", | |||
[d]=l, | |||
[f]=m, | |||
[h]="uuid attribute contains a malformed GUID", | [h]="uuid attribute contains a malformed GUID", | ||
[ | [b]=n, | ||
[ | [j]="uuid attribute contains a malformed GUID", | ||
[c]=a, | |||
[ | [i]=a, | ||
[g]={"7da1166da010",1292809309,"Validate Microsoft\'s uuid attribute string.","Validate Microsoft\'s uuid attribute string."}, | |||
[k]={{P,4738,"/// Parse uuid() attribute when it appears in a [] Microsoft attribute.\nvoid Parser::ParseMicrosoftUuidAttributeArgs(ParsedAttributes &Attrs) {\n if (Tok.is(tok::string_literal)) {\n } else {\n while (Tok.isNot(tok::r_paren)) {\n if (Tok.hasLeadingSpace() || Tok.isAtStartOfLine()) {\n Diag(Tok, diag::err_attribute_uuid_malformed_guid);"},{P,4756,"/// Parse uuid() attribute when it appears in a [] Microsoft attribute.\nvoid Parser::ParseMicrosoftUuidAttributeArgs(ParsedAttributes &Attrs) {\n if (Tok.is(tok::string_literal)) {\n } else {\n if (Tok.hasLeadingSpace() || Tok.isAtStartOfLine()) {\n Diag(Tok, diag::err_attribute_uuid_malformed_guid);"},{q,7007,"static void handleUuidAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Validate GUID length.\n if (StrRef.size() != 36) {\n S.Diag(LiteralLoc, diag::err_attribute_uuid_malformed_guid);"},{q,7014,"static void handleUuidAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned i = 0; i < 36; ++i) {\n if (i == 8 || i == 13 || i == 18 || i == 23) {\n if (StrRef[i] != \'-\') {\n S.Diag(LiteralLoc, diag::err_attribute_uuid_malformed_guid);"},{q,7018,"static void handleUuidAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned i = 0; i < 36; ++i) {\n if (i == 8 || i == 13 || i == 18 || i == 23) {\n } else if (!isHexDigit(StrRef[i])) {\n S.Diag(LiteralLoc, diag::err_attribute_uuid_malformed_guid);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/ms-square-bracket-attributes.mm"]={"clang/test/Parser/ms-square-bracket-attributes.mm:21:7: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:23:7: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:58:8: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:60:21: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:63:1: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:65:24: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:67:44: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:70:1: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:73:7: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:95:7: error: uuid attribute contains a malformed GUID"} | ["clang/test/Parser/ms-square-bracket-attributes.mm"]={"clang/test/Parser/ms-square-bracket-attributes.mm:21:7: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:23:7: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:58:8: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:60:21: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:63:1: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:65:24: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:67:44: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:70:1: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:73:7: error: uuid attribute contains a malformed GUID","clang/test/Parser/ms-square-bracket-attributes.mm:95:7: error: uuid attribute contains a malformed GUID"} | ||
Line 4,917: | Line 4,937: | ||
}, | }, | ||
["err_attribute_vecreturn_only_pod_record"]={ | ["err_attribute_vecreturn_only_pod_record"]={ | ||
[e]="the vecreturn attribute can only be used on a POD (plain old data) class or structure (i.e. no virtual functions)", | |||
[d]=l, | |||
[f]=m, | |||
[h]="the vecreturn attribute can only be used on a POD (plain old data) class or structure (i.e. no virtual functions)", | [h]="the vecreturn attribute can only be used on a POD (plain old data) class or structure (i.e. no virtual functions)", | ||
[ | [b]=n, | ||
[ | [j]="the vecreturn attribute can only be used on a POD \\(plain old data\\) class or structure \\(i\\.e\\. no virtual functions\\)", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"9a587aaaa9e7",1284772327,"Add more error checking to attribute vecreturn","Add more error checking to attribute vecreturn"}, | |||
[ | |||
[ | |||
[ | |||
[k]={{q,2300,"// PS3 PPU-specific.\nstatic void handleVecReturnAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!cast<CXXRecordDecl>(R)->isPOD()) {\n S.Diag(AL.getLoc(), diag::err_attribute_vecreturn_only_pod_record);"}}, | [k]={{q,2300,"// PS3 PPU-specific.\nstatic void handleVecReturnAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!cast<CXXRecordDecl>(R)->isPOD()) {\n S.Diag(AL.getLoc(), diag::err_attribute_vecreturn_only_pod_record);"}}, | ||
[o]={ | [o]={ | ||
Line 4,932: | Line 4,952: | ||
}, | }, | ||
["err_attribute_vecreturn_only_vector_member"]={ | ["err_attribute_vecreturn_only_vector_member"]={ | ||
[e]="the vecreturn attribute can only be used on a class or structure with one member, which must be a vector", | |||
[d]=l, | |||
[f]=m, | |||
[h]="the vecreturn attribute can only be used on a class or structure with one member, which must be a vector", | [h]="the vecreturn attribute can only be used on a class or structure with one member, which must be a vector", | ||
[ | [b]=n, | ||
[ | [j]="the vecreturn attribute can only be used on a class or structure with one member, which must be a vector", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"9a587aaaa9e7",1284772327,"Add more error checking to attribute vecreturn","Add more error checking to attribute vecreturn"}, | |||
[ | |||
[ | |||
[k]={{q,2295,"// PS3 PPU-specific.\nstatic void handleVecReturnAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!isa<CXXRecordDecl>(R)) {\n S.Diag(AL.getLoc(), diag::err_attribute_vecreturn_only_vector_member);"},{q,2306,"// PS3 PPU-specific.\nstatic void handleVecReturnAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (const auto *I : R->fields()) {\n if ((count == 1) || !I->getType()->isVectorType()) {\n S.Diag(AL.getLoc(), diag::err_attribute_vecreturn_only_vector_member);"}}, | [k]={{q,2295,"// PS3 PPU-specific.\nstatic void handleVecReturnAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!isa<CXXRecordDecl>(R)) {\n S.Diag(AL.getLoc(), diag::err_attribute_vecreturn_only_vector_member);"},{q,2306,"// PS3 PPU-specific.\nstatic void handleVecReturnAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (const auto *I : R->fields()) {\n if ((count == 1) || !I->getType()->isVectorType()) {\n S.Diag(AL.getLoc(), diag::err_attribute_vecreturn_only_vector_member);"}}, | ||
[o]={ | [o]={ | ||
Line 4,947: | Line 4,967: | ||
}, | }, | ||
["err_attribute_weak_static"]={ | ["err_attribute_weak_static"]={ | ||
[e]="weak declaration cannot have internal linkage", | |||
[d]=l, | |||
[f]=m, | |||
[h]="weak declaration cannot have internal linkage", | [h]="weak declaration cannot have internal linkage", | ||
[ | [b]=n, | ||
[ | [j]="weak declaration cannot have internal linkage", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"41136eec6bdb",1247706744,"Generate error on declaration containing \'static\' and \'__attribute__((weak))\'","Generate error on declaration containing \'static\' and \'__attribute__((weak))\'"}, | |||
[k]={{s,6951,"static void checkAttributesAfterMerging(Sema &S, NamedDecl &ND) {\n // \'weak\' only applies to declarations with external linkage.\n if (WeakAttr *Attr = ND.getAttr<WeakAttr>()) {\n if (!ND.isExternallyVisible()) {\n S.Diag(Attr->getLocation(), diag::err_attribute_weak_static);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/attr-weak.cpp"]={"clang/test/SemaCXX/attr-weak.cpp:3:33: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:4:36: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:10:28: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:11:31: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:20:40: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:40:16: error: weak declaration cannot have internal linkage"} | ["clang/test/SemaCXX/attr-weak.cpp"]={"clang/test/SemaCXX/attr-weak.cpp:3:33: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:4:36: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:10:28: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:11:31: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:20:40: error: weak declaration cannot have internal linkage","clang/test/SemaCXX/attr-weak.cpp:40:16: error: weak declaration cannot have internal linkage"} | ||
Line 4,962: | Line 4,982: | ||
}, | }, | ||
["err_attribute_weakref_not_global_context"]={ | ["err_attribute_weakref_not_global_context"]={ | ||
[ | [e]="weakref declaration of A must be in a global context", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="weakref declaration of %0 must be in a global context", | ||
[ | [b]=n, | ||
[ | [j]="weakref declaration of (.*?) must be in a global context", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"c18086ae1755",1266962430,"Add support for the weakref attribute. We still produce \"alias weak\" as llvm-gcc does, but are more ...","Add support for the weakref attribute. We still produce \"alias weak\" as llvm-gcc does, but are more strict on what uses of weakref we accept."}, | ||
[k]={{q,1933,"static void handleWeakRefAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!Ctx->isFileContext()) {\n S.Diag(AL.getLoc(), diag::err_attribute_weakref_not_global_context) << cast<NamedDecl>(D);"}}, | [k]={{q,1933,"static void handleWeakRefAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!Ctx->isFileContext()) {\n S.Diag(AL.getLoc(), diag::err_attribute_weakref_not_global_context) << cast<NamedDecl>(D);"}}, | ||
[o]={ | [o]={ | ||
Line 4,977: | Line 4,997: | ||
}, | }, | ||
["err_attribute_weakref_not_static"]={ | ["err_attribute_weakref_not_static"]={ | ||
[e]="weakref declaration must have internal linkage", | |||
[d]=l, | |||
[f]=m, | |||
[h]="weakref declaration must have internal linkage", | [h]="weakref declaration must have internal linkage", | ||
[ | [b]=n, | ||
[ | [j]="weakref declaration must have internal linkage", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"c18086ae1755",1266962430,"Add support for the weakref attribute. We still produce \"alias weak\" as llvm-gcc does, but are more ...","Add support for the weakref attribute. We still produce \"alias weak\" as llvm-gcc does, but are more strict on what uses of weakref we accept."}, | |||
[k]={{s,6957,"static void checkAttributesAfterMerging(Sema &S, NamedDecl &ND) {\n if (WeakRefAttr *Attr = ND.getAttr<WeakRefAttr>()) {\n if (ND.isExternallyVisible()) {\n S.Diag(Attr->getLocation(), diag::err_attribute_weakref_not_static);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/attr-weakref.cpp"]={"clang/test/SemaCXX/attr-weakref.cpp:27:25: error: weakref declaration must have internal linkage","clang/test/SemaCXX/attr-weakref.cpp:28:23: error: weakref declaration must have internal linkage","clang/test/SemaCXX/attr-weakref.cpp:38:16: error: weakref declaration must have internal linkage"} | ["clang/test/SemaCXX/attr-weakref.cpp"]={"clang/test/SemaCXX/attr-weakref.cpp:27:25: error: weakref declaration must have internal linkage","clang/test/SemaCXX/attr-weakref.cpp:28:23: error: weakref declaration must have internal linkage","clang/test/SemaCXX/attr-weakref.cpp:38:16: error: weakref declaration must have internal linkage"} | ||
Line 4,992: | Line 5,012: | ||
}, | }, | ||
["err_attribute_weakref_without_alias"]={ | ["err_attribute_weakref_without_alias"]={ | ||
[ | [e]="weakref declaration of A must also have an alias attribute", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="weakref declaration of %0 must also have an alias attribute", | ||
[ | [b]=n, | ||
[ | [j]="weakref declaration of (.*?) must also have an alias attribute", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"c18086ae1755",1266962430,"Add support for the weakref attribute. We still produce \"alias weak\" as llvm-gcc does, but are more ...","Add support for the weakref attribute. We still produce \"alias weak\" as llvm-gcc does, but are more strict on what uses of weakref we accept."}, | ||
[k]={{q,9516,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle these cases in TableGen.\n // GCC accepts\n // static int a9 __attribute__((weakref));\n // but that looks really pointless. We reject it.\n if (D->hasAttr<WeakRefAttr>() && !D->hasAttr<AliasAttr>()) {\n Diag(AttrList.begin()->getLoc(), diag::err_attribute_weakref_without_alias) << cast<NamedDecl>(D);"}}, | [k]={{q,9516,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle these cases in TableGen.\n // GCC accepts\n // static int a9 __attribute__((weakref));\n // but that looks really pointless. We reject it.\n if (D->hasAttr<WeakRefAttr>() && !D->hasAttr<AliasAttr>()) {\n Diag(AttrList.begin()->getLoc(), diag::err_attribute_weakref_without_alias) << cast<NamedDecl>(D);"}}, | ||
[o]={ | [o]={ | ||
Line 5,007: | Line 5,027: | ||
}, | }, | ||
["err_attribute_webassembly_funcref"]={ | ["err_attribute_webassembly_funcref"]={ | ||
[e]="\'__funcref\' attribute can only be applied to a function pointer type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'__funcref\' attribute can only be applied to a function pointer type", | [h]="\'__funcref\' attribute can only be applied to a function pointer type", | ||
[ | [b]=n, | ||
[ | [j]="\'__funcref\' attribute can only be applied to a function pointer type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={R,1625925174,B,B} | |||
[ | |||
[ | |||
}, | }, | ||
["err_attribute_wrong_decl_type"]={ | ["err_attribute_wrong_decl_type"]={ | ||
[ | [e]="A... only applies to ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0%select{ attribute|}1 only applies to %select{functions|unions|variables and functions|functions and methods|functions, methods and blocks|functions, methods, and parameters|variables|variables and fields|variables, data members and tag types|types and namespaces|variables, functions and classes|kernel functions|non-K&R-style functions}2", | ||
[ | [b]=n, | ||
[ | [j]="(.*?)(?: attribute|) only applies to (?:functions|unions|variables and functions|functions and methods|functions, methods and blocks|functions, methods, and parameters|variables|variables and fields|variables, data members and tag types|types and namespaces|variables, functions and classes|kernel functions|non\\-K&R\\-style functions)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"96d5c76498b2",1258792989,"Added rudimentary C++0x attribute support.","Added rudimentary C++0x attribute support."}, | ||
[k]={{q,2249,"static void handleAnalyzerNoReturnAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // The checking path for \'noreturn\' and \'analyzer_noreturn\' are different\n // because \'analyzer_noreturn\' does not impact the type.\n if (!isFunctionOrMethodOrBlock(D)) {\n if (!VD || (!VD->getType()->isBlockPointerType() && !VD->getType()->isFunctionPointerType())) {\n S.Diag(AL.getLoc(), AL.isStandardAttributeSyntax() ? diag::err_attribute_wrong_decl_type : diag::warn_attribute_wrong_decl_type) << AL << AL.isRegularKeywordAttribute() << ExpectedFunctionMethodOrBlock;"},{q,2904,"static void handleVisibilityAttr(Sema &S, Decl *D, const ParsedAttr &AL, bool isTypeVisibility) {\n // \'type_visibility\' can only go on a type or namespace.\n if (isTypeVisibility && !(isa<TagDecl>(D) || isa<ObjCInterfaceDecl>(D) || isa<NamespaceDecl>(D))) {\n S.Diag(AL.getRange().getBegin(), diag::err_attribute_wrong_decl_type) << AL << AL.isRegularKeywordAttribute() << ExpectedTypeOrNamespace;"},{q,4429,"/// 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 if (isa<ParmVarDecl>(D)) {\n } else if (const auto *VD = dyn_cast<VarDecl>(D)) {\n } else if (const auto *FD = dyn_cast<FieldDecl>(D)) {\n } else if (const auto *ED = dyn_cast<EnumDecl>(D)) {\n } else if (!isa<TagDecl>(D)) {\n return S.Diag(AttrLoc, diag::err_attribute_wrong_decl_type) << &Attr << Attr.isRegularKeywordAttribute() << (Attr.isC11() ? ExpectedVariableOrField : ExpectedVariableFieldOrTag);"},{q,5706,"static void handleTypeTagForDatatypeAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!isa<VarDecl>(D)) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_decl_type) << AL << AL.isRegularKeywordAttribute() << ExpectedVariable;"},{q,6289,"static void handleObjCOwnershipAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n S.Diag(D->getBeginLoc(), diag::err_attribute_wrong_decl_type) << AL.getRange() << AL << AL.isRegularKeywordAttribute() << ExpectedVariable;"},{q,8253,"static void handleNoSanitizeSpecificAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (isGlobalVar(D) && SanitizerName != \"address\")\n S.Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << AL << AL.isRegularKeywordAttribute() << ExpectedFunction;"},{q,9530,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n // diag::err_attribute_wrong_decl_type + ExpectedKernelFunction."},{q,9544,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<WorkGroupSizeHintAttr>()) {\n } else if (const auto *A = D->getAttr<VecTypeHintAttr>()) {\n } else if (const auto *A = D->getAttr<OpenCLIntelReqdSubGroupSizeAttr>()) {\n } else if (!D->hasAttr<CUDAGlobalAttr>()) {\n if (const auto *A = D->getAttr<AMDGPUFlatWorkGroupSizeAttr>()) {\n Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << A << A->isRegularKeywordAttribute() << ExpectedKernelFunction;"},{q,9548,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<WorkGroupSizeHintAttr>()) {\n } else if (const auto *A = D->getAttr<VecTypeHintAttr>()) {\n } else if (const auto *A = D->getAttr<OpenCLIntelReqdSubGroupSizeAttr>()) {\n } else if (!D->hasAttr<CUDAGlobalAttr>()) {\n if (const auto *A = D->getAttr<AMDGPUFlatWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUWavesPerEUAttr>()) {\n Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << A << A->isRegularKeywordAttribute() << ExpectedKernelFunction;"},{q,9552,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<WorkGroupSizeHintAttr>()) {\n } else if (const auto *A = D->getAttr<VecTypeHintAttr>()) {\n } else if (const auto *A = D->getAttr<OpenCLIntelReqdSubGroupSizeAttr>()) {\n } else if (!D->hasAttr<CUDAGlobalAttr>()) {\n if (const auto *A = D->getAttr<AMDGPUFlatWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUWavesPerEUAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUNumSGPRAttr>()) {\n Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << A << A->isRegularKeywordAttribute() << ExpectedKernelFunction;"},{q,9556,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<WorkGroupSizeHintAttr>()) {\n } else if (const auto *A = D->getAttr<VecTypeHintAttr>()) {\n } else if (const auto *A = D->getAttr<OpenCLIntelReqdSubGroupSizeAttr>()) {\n } else if (!D->hasAttr<CUDAGlobalAttr>()) {\n if (const auto *A = D->getAttr<AMDGPUFlatWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUWavesPerEUAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUNumSGPRAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUNumVGPRAttr>()) {\n Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << A << A->isRegularKeywordAttribute() << ExpectedKernelFunction;"}}, | [k]={{q,2249,"static void handleAnalyzerNoReturnAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // The checking path for \'noreturn\' and \'analyzer_noreturn\' are different\n // because \'analyzer_noreturn\' does not impact the type.\n if (!isFunctionOrMethodOrBlock(D)) {\n if (!VD || (!VD->getType()->isBlockPointerType() && !VD->getType()->isFunctionPointerType())) {\n S.Diag(AL.getLoc(), AL.isStandardAttributeSyntax() ? diag::err_attribute_wrong_decl_type : diag::warn_attribute_wrong_decl_type) << AL << AL.isRegularKeywordAttribute() << ExpectedFunctionMethodOrBlock;"},{q,2904,"static void handleVisibilityAttr(Sema &S, Decl *D, const ParsedAttr &AL, bool isTypeVisibility) {\n // \'type_visibility\' can only go on a type or namespace.\n if (isTypeVisibility && !(isa<TagDecl>(D) || isa<ObjCInterfaceDecl>(D) || isa<NamespaceDecl>(D))) {\n S.Diag(AL.getRange().getBegin(), diag::err_attribute_wrong_decl_type) << AL << AL.isRegularKeywordAttribute() << ExpectedTypeOrNamespace;"},{q,4429,"/// 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 if (isa<ParmVarDecl>(D)) {\n } else if (const auto *VD = dyn_cast<VarDecl>(D)) {\n } else if (const auto *FD = dyn_cast<FieldDecl>(D)) {\n } else if (const auto *ED = dyn_cast<EnumDecl>(D)) {\n } else if (!isa<TagDecl>(D)) {\n return S.Diag(AttrLoc, diag::err_attribute_wrong_decl_type) << &Attr << Attr.isRegularKeywordAttribute() << (Attr.isC11() ? ExpectedVariableOrField : ExpectedVariableFieldOrTag);"},{q,5706,"static void handleTypeTagForDatatypeAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!isa<VarDecl>(D)) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_decl_type) << AL << AL.isRegularKeywordAttribute() << ExpectedVariable;"},{q,6289,"static void handleObjCOwnershipAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n S.Diag(D->getBeginLoc(), diag::err_attribute_wrong_decl_type) << AL.getRange() << AL << AL.isRegularKeywordAttribute() << ExpectedVariable;"},{q,8253,"static void handleNoSanitizeSpecificAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (isGlobalVar(D) && SanitizerName != \"address\")\n S.Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << AL << AL.isRegularKeywordAttribute() << ExpectedFunction;"},{q,9530,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n // diag::err_attribute_wrong_decl_type + ExpectedKernelFunction."},{q,9544,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<WorkGroupSizeHintAttr>()) {\n } else if (const auto *A = D->getAttr<VecTypeHintAttr>()) {\n } else if (const auto *A = D->getAttr<OpenCLIntelReqdSubGroupSizeAttr>()) {\n } else if (!D->hasAttr<CUDAGlobalAttr>()) {\n if (const auto *A = D->getAttr<AMDGPUFlatWorkGroupSizeAttr>()) {\n Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << A << A->isRegularKeywordAttribute() << ExpectedKernelFunction;"},{q,9548,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<WorkGroupSizeHintAttr>()) {\n } else if (const auto *A = D->getAttr<VecTypeHintAttr>()) {\n } else if (const auto *A = D->getAttr<OpenCLIntelReqdSubGroupSizeAttr>()) {\n } else if (!D->hasAttr<CUDAGlobalAttr>()) {\n if (const auto *A = D->getAttr<AMDGPUFlatWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUWavesPerEUAttr>()) {\n Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << A << A->isRegularKeywordAttribute() << ExpectedKernelFunction;"},{q,9552,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<WorkGroupSizeHintAttr>()) {\n } else if (const auto *A = D->getAttr<VecTypeHintAttr>()) {\n } else if (const auto *A = D->getAttr<OpenCLIntelReqdSubGroupSizeAttr>()) {\n } else if (!D->hasAttr<CUDAGlobalAttr>()) {\n if (const auto *A = D->getAttr<AMDGPUFlatWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUWavesPerEUAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUNumSGPRAttr>()) {\n Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << A << A->isRegularKeywordAttribute() << ExpectedKernelFunction;"},{q,9556,"/// ProcessDeclAttributeList - Apply all the decl attributes in the specified\n/// attribute list to the specified decl, ignoring any type attributes.\nvoid Sema::ProcessDeclAttributeList(Scope *S, Decl *D, const ParsedAttributesView &AttrList, const ProcessDeclAttributeOptions &Options) {\n // FIXME: We should be able to handle this in TableGen as well. It would be\n // good to have a way to specify \"these attributes must appear as a group\",\n // for these. Additionally, it would be good to have a way to specify \"these\n // attribute must never appear as a group\" for attributes like cold and hot.\n if (!D->hasAttr<OpenCLKernelAttr>()) {\n // These attributes cannot be applied to a non-kernel function.\n if (const auto *A = D->getAttr<ReqdWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<WorkGroupSizeHintAttr>()) {\n } else if (const auto *A = D->getAttr<VecTypeHintAttr>()) {\n } else if (const auto *A = D->getAttr<OpenCLIntelReqdSubGroupSizeAttr>()) {\n } else if (!D->hasAttr<CUDAGlobalAttr>()) {\n if (const auto *A = D->getAttr<AMDGPUFlatWorkGroupSizeAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUWavesPerEUAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUNumSGPRAttr>()) {\n } else if (const auto *A = D->getAttr<AMDGPUNumVGPRAttr>()) {\n Diag(D->getLocation(), diag::err_attribute_wrong_decl_type) << A << A->isRegularKeywordAttribute() << ExpectedKernelFunction;"}}, | ||
[o]={ | [o]={ | ||
Line 5,033: | Line 5,053: | ||
}, | }, | ||
["err_attribute_wrong_decl_type_str"]={ | ["err_attribute_wrong_decl_type_str"]={ | ||
[ | [e]="A... only applies to B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0%select{ attribute|}1 only applies to %2", | ||
[ | [b]=n, | ||
[ | [j]="(.*?)(?: attribute|) only applies to (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"adf66b617461",1511726472,"Determine the attribute subject for diagnostics based on declarative information in DeclNodes.td. Th...","Determine the attribute subject for diagnostics based on declarative information in DeclNodes.td. This greatly reduces the number of enumerated values used for more complex diagnostics; these are now only required when the \"attribute only applies to\" diagnostic needs to be generated manually as part of semantic processing."}, | ||
[k]={{q,2173,"static void handleNakedAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isDeclspecAttribute()) {\n // This form is not allowed to be written on a member function (static or\n // nonstatic) when in Microsoft compatibility mode.\n if (S.getLangOpts().MSVCCompat && isa<CXXMethodDecl>(D)) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_decl_type_str) << AL << AL.isRegularKeywordAttribute() << \"non-member functions\";"}}, | [k]={{q,2173,"static void handleNakedAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.isDeclspecAttribute()) {\n // This form is not allowed to be written on a member function (static or\n // nonstatic) when in Microsoft compatibility mode.\n if (S.getLangOpts().MSVCCompat && isa<CXXMethodDecl>(D)) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_decl_type_str) << AL << AL.isRegularKeywordAttribute() << \"non-member functions\";"}}, | ||
[o]={ | [o]={ | ||
Line 5,048: | Line 5,068: | ||
}, | }, | ||
["err_attribute_wrong_number_arguments"]={ | ["err_attribute_wrong_number_arguments"]={ | ||
[ | [e]="A attribute takes no arguments", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute %plural{0:takes no arguments|1:takes one argument|:requires exactly %1 arguments}1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute (?:takes no arguments|takes one argument|requires exactly (.*?) arguments)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{"clang/lib/Sema/ParsedAttr.cpp",284,"bool ParsedAttr::checkExactlyNumArgs(Sema &S, unsigned Num) const { return checkAttributeNumArgsImpl(S, *this, Num, diag::err_attribute_wrong_number_arguments, std::not_equal_to<unsigned>()); }"},{q,1505,"static void handleIBOutletCollection(Sema &S, Decl *D, const ParsedAttr &AL) {\n // The iboutletcollection attribute can have zero or one arguments.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << 1;"},{q,1917,"static void handleWeakRefAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Check the attribute arguments.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << 1;"},{q,3260,"static void handleVecTypeHint(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.hasParsedType()) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << 1;"},{q,4162,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (CalleeFnProtoType->getNumParams() > EncodingIndices.size() - 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << (unsigned)(EncodingIndices.size() - 1);"},{q,4168,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (CalleeFnProtoType->getNumParams() < EncodingIndices.size() - 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << (unsigned)(EncodingIndices.size() - 1);"},{q,4373,"static void handleAlignedAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // check the attribute arguments.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << 1;"},{ | [k]={{"clang/lib/Sema/ParsedAttr.cpp",284,"bool ParsedAttr::checkExactlyNumArgs(Sema &S, unsigned Num) const { return checkAttributeNumArgsImpl(S, *this, Num, diag::err_attribute_wrong_number_arguments, std::not_equal_to<unsigned>()); }"},{q,1505,"static void handleIBOutletCollection(Sema &S, Decl *D, const ParsedAttr &AL) {\n // The iboutletcollection attribute can have zero or one arguments.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << 1;"},{q,1917,"static void handleWeakRefAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Check the attribute arguments.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << 1;"},{q,3260,"static void handleVecTypeHint(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!AL.hasParsedType()) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << 1;"},{q,4162,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (CalleeFnProtoType->getNumParams() > EncodingIndices.size() - 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << (unsigned)(EncodingIndices.size() - 1);"},{q,4168,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (CalleeFnProtoType->getNumParams() < EncodingIndices.size() - 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << (unsigned)(EncodingIndices.size() - 1);"},{q,4373,"static void handleAlignedAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // check the attribute arguments.\n if (AL.getNumArgs() > 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments) << AL << 1;"},{t,6795,"static void HandleBTFTypeTagAttribute(QualType &Type, const ParsedAttr &Attr, TypeProcessingState &State) {\n // Check the number of attribute arguments.\n if (Attr.getNumArgs() != 1) {\n S.Diag(Attr.getLoc(), diag::err_attribute_wrong_number_arguments) << Attr << 1;"},{t,6837,"/// 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 if (Attr.getKind() == ParsedAttr::AT_AddressSpace) {\n // Check the attribute arguments.\n if (Attr.getNumArgs() != 1) {\n S.Diag(Attr.getLoc(), diag::err_attribute_wrong_number_arguments) << Attr << 1;"},{t,7114,"/// 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 if (attr.getNumArgs() > 1) {\n S.Diag(attr.getLoc(), diag::err_attribute_wrong_number_arguments) << attr << 1;"},{t,8094,"/// HandleVectorSizeAttribute - this attribute is only applicable to integral\n/// and float scalars, although arrays, pointers, and function return values are\n/// allowed in conjunction with this construct. Aggregates with this attribute\n/// are invalid, even if they are of the same size as a corresponding scalar.\n/// The raw attribute should contain precisely 1 argument, the vector size for\n/// the variable, measured in bytes. If curType and rawAttr are well formed,\n/// this routine will return a new vector type.\nstatic void HandleVectorSizeAttr(QualType &CurType, const ParsedAttr &Attr, Sema &S) {\n // Check the attribute arguments.\n if (Attr.getNumArgs() != 1) {\n S.Diag(Attr.getLoc(), diag::err_attribute_wrong_number_arguments) << Attr << 1;"},{t,8114,"/// Process the OpenCL-like ext_vector_type attribute when it occurs on\n/// a type.\nstatic void HandleExtVectorTypeAttr(QualType &CurType, const ParsedAttr &Attr, Sema &S) {\n // check the attribute arguments.\n if (Attr.getNumArgs() != 1) {\n S.Diag(Attr.getLoc(), diag::err_attribute_wrong_number_arguments) << Attr << 1;"},{t,8218,"/// 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 // Check the attribute arguments.\n if (Attr.getNumArgs() != 1) {\n S.Diag(Attr.getLoc(), diag::err_attribute_wrong_number_arguments) << Attr << 1;"},{t,8273,"/// 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 // Check the attribute arguments.\n if (Attr.getNumArgs() != 1) {\n S.Diag(Attr.getLoc(), diag::err_attribute_wrong_number_arguments) << Attr << 1;"},{t,8356,"/// 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 // Check the attribute arguments.\n if (Attr.getNumArgs() != 1) {\n S.Diag(Attr.getLoc(), diag::err_attribute_wrong_number_arguments) << Attr << 1;"},{t,8461,"/// HandleMatrixTypeAttr - \"matrix_type\" attribute, like ext_vector_type\nstatic void HandleMatrixTypeAttr(QualType &CurType, const ParsedAttr &Attr, Sema &S) {\n if (Attr.getNumArgs() != 2) {\n S.Diag(Attr.getLoc(), diag::err_attribute_wrong_number_arguments) << Attr << 2;"},{t,8777,"static void processTypeAttrs(TypeProcessingState &state, QualType &type, TypeAttrLocation TAL, const ParsedAttributesView &attrs) {\n for (ParsedAttr &attr : AttrsCopy) {\n case ParsedAttr::AT_AcquireHandle: {\n if (attr.getNumArgs() != 1) {\n state.getSema().Diag(attr.getLoc(), diag::err_attribute_wrong_number_arguments) << attr << 1;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/warn-consumed-parsing.cpp"]={"clang/test/SemaCXX/warn-consumed-parsing.cpp:20:41: error: \'set_typestate\' attribute takes one argument","clang/test/SemaCXX/warn-consumed-parsing.cpp:21:41: error: \'test_typestate\' attribute takes one argument"} | ["clang/test/SemaCXX/warn-consumed-parsing.cpp"]={"clang/test/SemaCXX/warn-consumed-parsing.cpp:20:41: error: \'set_typestate\' attribute takes one argument","clang/test/SemaCXX/warn-consumed-parsing.cpp:21:41: error: \'test_typestate\' attribute takes one argument"} | ||
Line 5,063: | Line 5,083: | ||
}, | }, | ||
["err_attribute_wrong_number_arguments_for"]={ | ["err_attribute_wrong_number_arguments_for"]={ | ||
[ | [e]="A attribute references function B, which takes no arguments", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 attribute references function %1, which %plural{0:takes no arguments|1:takes one argument|:takes exactly %2 arguments}2", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) attribute references function (.*?), which (?:takes no arguments|takes one argument|takes exactly (.*?) arguments)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={yb,1616787805,S,S}, | ||
[k]={{q,1055,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AttrFD->getNumParams() != AL.getNumArgs() - 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments_for) << AL << AttrFD << AttrFD->getNumParams();"}}, | [k]={{q,1055,"static void handleDiagnoseAsBuiltinAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AttrFD->getNumParams() != AL.getNumArgs() - 1) {\n S.Diag(AL.getLoc(), diag::err_attribute_wrong_number_arguments_for) << AL << AttrFD << AttrFD->getNumParams();"}}, | ||
[o]={ | [o]={ | ||
Line 5,078: | Line 5,098: | ||
}, | }, | ||
["err_attribute_zero_size"]={ | ["err_attribute_zero_size"]={ | ||
[ | [e]="zero A size", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="zero %0 size", | ||
[ | [b]=n, | ||
[ | [j]="zero (.*?) size", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{t,2750,"QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, SourceLocation AttrLoc) {\n if (VectorSizeBits == 0) {\n Diag(AttrLoc, diag::err_attribute_zero_size) << SizeExpr->getSourceRange() << \"vector\";"},{t,2823,"/// 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 if (!ArraySize->isTypeDependent() && !ArraySize->isValueDependent()) {\n if (vectorSize == 0) {\n Diag(AttrLoc, diag::err_attribute_zero_size) << ArraySize->getSourceRange() << \"vector\";"},{t,2885,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n if (MatrixRows == 0 && MatrixColumns == 0) {\n Diag(AttrLoc, diag::err_attribute_zero_size) << \"matrix\" << RowRange << ColRange;"},{t,2890,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n if (MatrixRows == 0) {\n Diag(AttrLoc, diag::err_attribute_zero_size) << \"matrix\" << RowRange;"},{t,2894,"QualType Sema::BuildMatrixType(QualType ElementTy, Expr *NumRows, Expr *NumCols, SourceLocation AttrLoc) {\n if (MatrixColumns == 0) {\n Diag(AttrLoc, diag::err_attribute_zero_size) << \"matrix\" << ColRange;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaTemplate/matrix-type.cpp"]={"clang/test/SemaTemplate/matrix-type.cpp:111:28: error: zero matrix size","clang/test/SemaTemplate/matrix-type.cpp:15:42: error: zero matrix size"} | ["clang/test/SemaTemplate/matrix-type.cpp"]={"clang/test/SemaTemplate/matrix-type.cpp:111:28: error: zero matrix size","clang/test/SemaTemplate/matrix-type.cpp:15:42: error: zero matrix size"} | ||
Line 5,093: | Line 5,113: | ||
}, | }, | ||
["err_attributes_are_not_compatible"]={ | ["err_attributes_are_not_compatible"]={ | ||
[ | [e]="A and B... are not compatible", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 and %1%select{ attributes|}2 are not compatible", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) and (.*?)(?: attributes|) are not compatible", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{q,277,"/// Diagnose mutually exclusive attributes when present on a given\n/// declaration. Returns true if diagnosed.\ntemplate <typename AttrTy> static bool checkAttrMutualExclusion(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (const auto *A = D->getAttr<AttrTy>()) {\n S.Diag(AL.getLoc(), diag::err_attributes_are_not_compatible) << AL << A << (AL.isRegularKeywordAttribute() || A->isRegularKeywordAttribute());"},{q,289,"template <typename AttrTy> static bool checkAttrMutualExclusion(Sema &S, Decl *D, const Attr &AL) {\n if (const auto *A = D->getAttr<AttrTy>()) {\n S.Diag(AL.getLocation(), diag::err_attributes_are_not_compatible) << &AL << A << (AL.isRegularKeywordAttribute() || A->isRegularKeywordAttribute());"},{q,1885,"static void handleOwnershipAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned i = 1; i < AL.getNumArgs(); ++i) {\n // Check we don\'t have a conflict with another ownership attribute.\n for (const auto *I : D->specific_attrs<OwnershipAttr>()) {\n // Cannot have two ownership attributes of different kinds for the same\n // index.\n if (I->getOwnKind() != K && llvm::is_contained(I->args(), Idx)) {\n S.Diag(AL.getLoc(), diag::err_attributes_are_not_compatible) << AL << I << (AL.isRegularKeywordAttribute() || I->isRegularKeywordAttribute());"},{q,3898,"ErrorAttr *Sema::mergeErrorAttr(Decl *D, const AttributeCommonInfo &CI, StringRef NewUserDiagnostic) {\n if (const auto *EA = D->getAttr<ErrorAttr>()) {\n if (!Match) {\n Diag(EA->getLocation(), diag::err_attributes_are_not_compatible) << CI << EA << (CI.isRegularKeywordAttribute() || EA->isRegularKeywordAttribute());"},{q,4958,"SwiftNameAttr *Sema::mergeSwiftNameAttr(Decl *D, const SwiftNameAttr &SNA, StringRef Name) {\n if (const auto *PrevSNA = D->getAttr<SwiftNameAttr>()) {\n if (PrevSNA->getName() != Name && !PrevSNA->isImplicit()) {\n Diag(PrevSNA->getLocation(), diag::err_attributes_are_not_compatible) << PrevSNA << &SNA << (PrevSNA->isRegularKeywordAttribute() || SNA.isRegularKeywordAttribute());"},{q,5256,"static void handleLifetimeCategoryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getKind() == ParsedAttr::AT_Owner) {\n if (const auto *OAttr = D->getAttr<OwnerAttr>()) {\n if (ExistingDerefType != ParmType.getTypePtrOrNull()) {\n S.Diag(AL.getLoc(), diag::err_attributes_are_not_compatible) << AL << OAttr << (AL.isRegularKeywordAttribute() || OAttr->isRegularKeywordAttribute());"},{q,5275,"static void handleLifetimeCategoryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getKind() == ParsedAttr::AT_Owner) {\n } else {\n if (const auto *PAttr = D->getAttr<PointerAttr>()) {\n if (ExistingDerefType != ParmType.getTypePtrOrNull()) {\n S.Diag(AL.getLoc(), diag::err_attributes_are_not_compatible) << AL << PAttr << (AL.isRegularKeywordAttribute() || PAttr->isRegularKeywordAttribute());"},{q,5512,"void Sema::AddParameterABIAttr(Decl *D, const AttributeCommonInfo &CI, ParameterABI abi) {\n if (auto existingAttr = D->getAttr<ParameterABIAttr>()) {\n if (existingAttr->getABI() != abi) {\n Diag(CI.getLoc(), diag::err_attributes_are_not_compatible) << getParameterABISpelling(abi) << existingAttr << (CI.isRegularKeywordAttribute() || existingAttr->isRegularKeywordAttribute());"},{ | [k]={{q,277,"/// Diagnose mutually exclusive attributes when present on a given\n/// declaration. Returns true if diagnosed.\ntemplate <typename AttrTy> static bool checkAttrMutualExclusion(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (const auto *A = D->getAttr<AttrTy>()) {\n S.Diag(AL.getLoc(), diag::err_attributes_are_not_compatible) << AL << A << (AL.isRegularKeywordAttribute() || A->isRegularKeywordAttribute());"},{q,289,"template <typename AttrTy> static bool checkAttrMutualExclusion(Sema &S, Decl *D, const Attr &AL) {\n if (const auto *A = D->getAttr<AttrTy>()) {\n S.Diag(AL.getLocation(), diag::err_attributes_are_not_compatible) << &AL << A << (AL.isRegularKeywordAttribute() || A->isRegularKeywordAttribute());"},{q,1885,"static void handleOwnershipAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned i = 1; i < AL.getNumArgs(); ++i) {\n // Check we don\'t have a conflict with another ownership attribute.\n for (const auto *I : D->specific_attrs<OwnershipAttr>()) {\n // Cannot have two ownership attributes of different kinds for the same\n // index.\n if (I->getOwnKind() != K && llvm::is_contained(I->args(), Idx)) {\n S.Diag(AL.getLoc(), diag::err_attributes_are_not_compatible) << AL << I << (AL.isRegularKeywordAttribute() || I->isRegularKeywordAttribute());"},{q,3898,"ErrorAttr *Sema::mergeErrorAttr(Decl *D, const AttributeCommonInfo &CI, StringRef NewUserDiagnostic) {\n if (const auto *EA = D->getAttr<ErrorAttr>()) {\n if (!Match) {\n Diag(EA->getLocation(), diag::err_attributes_are_not_compatible) << CI << EA << (CI.isRegularKeywordAttribute() || EA->isRegularKeywordAttribute());"},{q,4958,"SwiftNameAttr *Sema::mergeSwiftNameAttr(Decl *D, const SwiftNameAttr &SNA, StringRef Name) {\n if (const auto *PrevSNA = D->getAttr<SwiftNameAttr>()) {\n if (PrevSNA->getName() != Name && !PrevSNA->isImplicit()) {\n Diag(PrevSNA->getLocation(), diag::err_attributes_are_not_compatible) << PrevSNA << &SNA << (PrevSNA->isRegularKeywordAttribute() || SNA.isRegularKeywordAttribute());"},{q,5256,"static void handleLifetimeCategoryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getKind() == ParsedAttr::AT_Owner) {\n if (const auto *OAttr = D->getAttr<OwnerAttr>()) {\n if (ExistingDerefType != ParmType.getTypePtrOrNull()) {\n S.Diag(AL.getLoc(), diag::err_attributes_are_not_compatible) << AL << OAttr << (AL.isRegularKeywordAttribute() || OAttr->isRegularKeywordAttribute());"},{q,5275,"static void handleLifetimeCategoryAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (AL.getKind() == ParsedAttr::AT_Owner) {\n } else {\n if (const auto *PAttr = D->getAttr<PointerAttr>()) {\n if (ExistingDerefType != ParmType.getTypePtrOrNull()) {\n S.Diag(AL.getLoc(), diag::err_attributes_are_not_compatible) << AL << PAttr << (AL.isRegularKeywordAttribute() || PAttr->isRegularKeywordAttribute());"},{q,5512,"void Sema::AddParameterABIAttr(Decl *D, const AttributeCommonInfo &CI, ParameterABI abi) {\n if (auto existingAttr = D->getAttr<ParameterABIAttr>()) {\n if (existingAttr->getABI() != abi) {\n Diag(CI.getLoc(), diag::err_attributes_are_not_compatible) << getParameterABISpelling(abi) << existingAttr << (CI.isRegularKeywordAttribute() || existingAttr->isRegularKeywordAttribute());"},{t,7363,"static bool handleMSPointerTypeQualifierAttr(TypeProcessingState &State, ParsedAttr &PAttr, QualType &Type) {\n // You cannot have both __sptr and __uptr on the same type, nor can you\n // have __ptr32 and __ptr64.\n if (Attrs[attr::Ptr32] && Attrs[attr::Ptr64]) {\n S.Diag(PAttr.getLoc(), diag::err_attributes_are_not_compatible) << \"\'__ptr32\'\""},{t,7368,"static bool handleMSPointerTypeQualifierAttr(TypeProcessingState &State, ParsedAttr &PAttr, QualType &Type) {\n // You cannot have both __sptr and __uptr on the same type, nor can you\n // have __ptr32 and __ptr64.\n if (Attrs[attr::Ptr32] && Attrs[attr::Ptr64]) {\n } else if (Attrs[attr::SPtr] && Attrs[attr::UPtr]) {\n S.Diag(PAttr.getLoc(), diag::err_attributes_are_not_compatible) << \"\'__sptr\'\""},{t,7892,"/// Process an individual function attribute. Returns true to\n/// indicate that the attribute was handled, false if it wasn\'t.\nstatic bool handleFunctionTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n if (attr.getKind() == ParsedAttr::AT_Regparm) {\n if (CC == CC_X86FastCall) {\n S.Diag(attr.getLoc(), diag::err_attributes_are_not_compatible) << FunctionType::getNameForCallConv(CC) << \"regparm\" << attr.isRegularKeywordAttribute();"},{t,7972,"/// Process an individual function attribute. Returns true to\n/// indicate that the attribute was handled, false if it wasn\'t.\nstatic bool handleFunctionTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n if (CCOld != CC) {\n // Error out on when there\'s already an attribute on the type\n // and the CCs don\'t match.\n if (S.getCallingConvAttributedType(type)) {\n S.Diag(attr.getLoc(), diag::err_attributes_are_not_compatible) << FunctionType::getNameForCallConv(CC) << FunctionType::getNameForCallConv(CCOld) << attr.isRegularKeywordAttribute();"},{t,8006,"/// Process an individual function attribute. Returns true to\n/// indicate that the attribute was handled, false if it wasn\'t.\nstatic bool handleFunctionTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n // Also diagnose fastcall with regparm.\n if (CC == CC_X86FastCall && fn->getHasRegParm()) {\n S.Diag(attr.getLoc(), diag::err_attributes_are_not_compatible) << \"regparm\" << FunctionType::getNameForCallConv(CC_X86FastCall) << attr.isRegularKeywordAttribute();"},{"clang/utils/TableGen/ClangAttrEmitter.cpp",4022,"// Generates the mutual exclusion checks. The checks for parsed attributes are\n// written into OS and the checks for merging declaration attributes are\n// written into MergeOS.\nstatic void GenerateMutualExclusionsChecks(const Record &Attr, const RecordKeeper &Records, raw_ostream &OS, raw_ostream &MergeDeclOS, raw_ostream &MergeStmtOS) {\n // If we discovered any decl or stmt attributes to test for, generate the\n // predicates for them now.\n if (!DeclAttrs.empty()) {\n for (const std::string &A : DeclAttrs) {\n OS << \" S.Diag(AL.getLoc(), diag::err_attributes_are_not_compatible)\""},{"clang/utils/TableGen/ClangAttrEmitter.cpp",4044,"// Generates the mutual exclusion checks. The checks for parsed attributes are\n// written into OS and the checks for merging declaration attributes are\n// written into MergeOS.\nstatic void GenerateMutualExclusionsChecks(const Record &Attr, const RecordKeeper &Records, raw_ostream &OS, raw_ostream &MergeDeclOS, raw_ostream &MergeStmtOS) {\n // If we discovered any decl or stmt attributes to test for, generate the\n // predicates for them now.\n if (!DeclAttrs.empty()) {\n // Also generate the declaration attribute merging logic if the current\n // attribute is one that can be inheritted on a declaration. It is assumed\n // this code will be executed in the context of a function with parameters:\n // Sema &S, Decl *D, Attr *A and that returns a bool (false on diagnostic,\n // true on success).\n if (Attr.isSubClassOf(\"InheritableAttr\")) {\n for (const std::string &A : DeclAttrs) {\n MergeDeclOS << \" S.Diag(First->getLocation(), \"\n << \"diag::err_attributes_are_not_compatible) << First << \""},{"clang/utils/TableGen/ClangAttrEmitter.cpp",4085,"// Generates the mutual exclusion checks. The checks for parsed attributes are\n// written into OS and the checks for merging declaration attributes are\n// written into MergeOS.\nstatic void GenerateMutualExclusionsChecks(const Record &Attr, const RecordKeeper &Records, raw_ostream &OS, raw_ostream &MergeDeclOS, raw_ostream &MergeStmtOS) {\n // Statement attributes are a bit different from declarations. With\n // declarations, each attribute is added to the declaration as it is\n // processed, and so you can look on the Decl * itself to see if there is a\n // conflicting attribute. Statement attributes are processed as a group\n // because AttributedStmt needs to tail-allocate all of the attribute nodes\n // at once. This means we cannot check whether the statement already contains\n // an attribute to check for the conflict. Instead, we need to check whether\n // the given list of semantic attributes contain any conflicts. It is assumed\n // this code will be executed in the context of a function with parameters:\n // Sema &S, const SmallVectorImpl<const Attr *> &C. The code will be within a\n // loop which loops over the container C with a loop variable named A to\n // represent the current attribute to check for conflicts.\n //\n // FIXME: it would be nice not to walk over the list of potential attributes\n // to apply to the statement more than once, but statements typically don\'t\n // have long lists of attributes on them, so re-walking the list should not\n // be an expensive operation.\n if (!StmtAttrs.empty()) {\n MergeStmtOS << \" S.Diag((*Iter)->getLocation(), \"\n << \"diag::err_attributes_are_not_compatible) << *Iter << \""}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/mips-interrupt-attr.c"]={"clang/test/Sema/mips-interrupt-attr.c:22:26: error: \'mips16\' and \'interrupt\' attributes are not compatible","clang/test/Sema/mips-interrupt-attr.c:24:23: error: \'interrupt\' and \'mips16\' attributes are not compatible","clang/test/Sema/mips-interrupt-attr.c:26:44: error: \'mips16\' and \'interrupt\' attributes are not compatible","clang/test/Sema/mips-interrupt-attr.c:28:39: error: \'interrupt\' and \'mips16\' attributes are not compatible"} | ["clang/test/Sema/mips-interrupt-attr.c"]={"clang/test/Sema/mips-interrupt-attr.c:22:26: error: \'mips16\' and \'interrupt\' attributes are not compatible","clang/test/Sema/mips-interrupt-attr.c:24:23: error: \'interrupt\' and \'mips16\' attributes are not compatible","clang/test/Sema/mips-interrupt-attr.c:26:44: error: \'mips16\' and \'interrupt\' attributes are not compatible","clang/test/Sema/mips-interrupt-attr.c:28:39: error: \'interrupt\' and \'mips16\' attributes are not compatible"} | ||
Line 5,108: | Line 5,128: | ||
}, | }, | ||
["err_attributes_misplaced"]={ | ["err_attributes_misplaced"]={ | ||
[e]="misplaced attributes; expected attributes here", | |||
[d]=l, | |||
[f]=m, | |||
[h]="misplaced attributes; expected attributes here", | [h]="misplaced attributes; expected attributes here", | ||
[ | [b]=n, | ||
[ | [j]="misplaced attributes; expected attributes here", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={"c5089c08d4cd",1514240600,"Add a fixit for attributes incorrectly placed prior to \'struct/class/enum\' keyword.","Add a fixit for attributes incorrectly placed prior to \'struct/class/enum\' keyword."}, | |||
[k]={{H,1719,"void Parser::DiagnoseProhibitedAttributes(const ParsedAttributesView &Attrs, const SourceLocation CorrectLocation) {\n if (CorrectLocation.isValid()) {\n (FirstAttr && FirstAttr->isRegularKeywordAttribute() ? Diag(CorrectLocation, diag::err_keyword_misplaced) << FirstAttr : Diag(CorrectLocation, diag::err_attributes_misplaced)) << FixItHint::CreateInsertionFromRange(CorrectLocation, AttrRange) << FixItHint::CreateRemoval(AttrRange);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/cxx0x-attributes.cpp"]={"clang/test/Parser/cxx0x-attributes.cpp:69:12: error: misplaced attributes; expected attributes here","clang/test/Parser/cxx0x-attributes.cpp:70:11: error: misplaced attributes; expected attributes here","clang/test/Parser/cxx0x-attributes.cpp:71:11: error: misplaced attributes; expected attributes here","clang/test/Parser/cxx0x-attributes.cpp:72:10: error: misplaced attributes; expected attributes here","clang/test/Parser/cxx0x-attributes.cpp:101:12: error: misplaced attributes; expected attributes here"} | ["clang/test/Parser/cxx0x-attributes.cpp"]={"clang/test/Parser/cxx0x-attributes.cpp:69:12: error: misplaced attributes; expected attributes here","clang/test/Parser/cxx0x-attributes.cpp:70:11: error: misplaced attributes; expected attributes here","clang/test/Parser/cxx0x-attributes.cpp:71:11: error: misplaced attributes; expected attributes here","clang/test/Parser/cxx0x-attributes.cpp:72:10: error: misplaced attributes; expected attributes here","clang/test/Parser/cxx0x-attributes.cpp:101:12: error: misplaced attributes; expected attributes here"} | ||
Line 5,123: | Line 5,143: | ||
}, | }, | ||
["err_attributes_not_allowed"]={ | ["err_attributes_not_allowed"]={ | ||
[e]="an attribute list cannot appear here", | |||
[d]=l, | |||
[f]=m, | |||
[h]="an attribute list cannot appear here", | [h]="an attribute list cannot appear here", | ||
[ | [b]=n, | ||
[ | [j]="an attribute list cannot appear here", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={"96d5c76498b2",1258792989,"Added rudimentary C++0x attribute support.","Added rudimentary C++0x attribute support."}, | |||
[k]={{H,1683,"/// DiagnoseProhibitedCXX11Attribute - We have found the opening square brackets\n/// of a C++11 attribute-specifier in a location where an attribute is not\n/// permitted. By C++11 [dcl.attr.grammar]p6, this is ill-formed. Diagnose this\n/// situation.\n///\n/// \\return \\c true if we skipped an attribute-like chunk of tokens, \\c false if\n/// this doesn\'t appear to actually be an attribute-specifier, and the caller\n/// should try to parse it.\nbool Parser::DiagnoseProhibitedCXX11Attribute() {\n case CAK_AttributeSpecifier:\n Diag(BeginLoc, diag::err_attributes_not_allowed) << SourceRange(BeginLoc, EndLoc);"},{H,1707,"/// We have found the opening square brackets of a C++11\n/// attribute-specifier in a location where an attribute is not permitted, but\n/// we know where the attributes ought to be written. Parse them anyway, and\n/// provide a fixit moving them to the right place.\nvoid Parser::DiagnoseMisplacedCXX11Attribute(ParsedAttributes &Attrs, SourceLocation CorrectLocation) {\n (Keyword ? Diag(Loc, diag::err_keyword_not_allowed) << Keyword : Diag(Loc, diag::err_attributes_not_allowed)) << FixItHint::CreateInsertionFromRange(CorrectLocation, AttrRange) << FixItHint::CreateRemoval(AttrRange);"},{H,1726,"void Parser::DiagnoseProhibitedAttributes(const ParsedAttributesView &Attrs, const SourceLocation CorrectLocation) {\n if (CorrectLocation.isValid()) {\n } else {\n (FirstAttr && FirstAttr->isRegularKeywordAttribute() ? Diag(Range.getBegin(), diag::err_keyword_not_allowed) << FirstAttr : Diag(Range.getBegin(), diag::err_attributes_not_allowed)) << Range;"},{H,5052,"/// 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 // An elaborated-type-specifier has a much more constrained grammar:\n //\n // \'enum\' nested-name-specifier[opt] identifier\n //\n // If we parsed any other bits, reject them now.\n //\n // MSVC and (for now at least) Objective-C permit a full enum-specifier\n // or opaque-enum-declaration anywhere.\n if (IsElaboratedTypeSpecifier && !getLangOpts().MicrosoftExt && !getLangOpts().ObjC) {\n ProhibitCXX11Attributes(attrs, diag::err_attributes_not_allowed, diag::err_keyword_not_allowed,"},{H,6052,"/// ParseTypeQualifierListOpt\n/// type-qualifier-list: [C99 6.7.5]\n/// type-qualifier\n/// [vendor] attributes\n/// [ only if AttrReqs & AR_VendorAttributesParsed ]\n/// type-qualifier-list type-qualifier\n/// [vendor] type-qualifier-list attributes\n/// [ only if AttrReqs & AR_VendorAttributesParsed ]\n/// [C++0x] attribute-specifier[opt] is allowed before cv-qualifier-seq\n/// [ only if AttReqs & AR_CXX11AttributesParsed ]\n/// Note: vendor can be GNU, MS, etc and can be explicitly controlled via\n/// AttrRequirements bitmask values.\nvoid Parser::ParseTypeQualifierListOpt(DeclSpec &DS, unsigned AttrReqs, bool AtomicAllowed, bool IdentifierRequired, std::optional<llvm::function_ref<void()>> CodeCompletionHandler) {\n while (true) {\n case tok::kw___attribute:\n if (AttrReqs & AR_GNUAttributesParsedAndRejected)\n Diag(Tok, diag::err_attributes_not_allowed);"},{P,777,"/// ParseUsingDeclaration - Parse C++ using-declaration or alias-declaration.\n/// Assumes that \'using\' was already seen.\n///\n/// using-declaration: [C++ 7.3.p3: namespace.udecl]\n/// \'using\' using-declarator-list[opt] ;\n///\n/// using-declarator-list: [C++1z]\n/// using-declarator \'...\'[opt]\n/// using-declarator-list \',\' using-declarator \'...\'[opt]\n///\n/// using-declarator-list: [C++98-14]\n/// using-declarator\n///\n/// alias-declaration: C++11 [dcl.dcl]p1\n/// \'using\' identifier attribute-specifier-seq[opt] = type-id ;\n///\n/// using-enum-declaration: [C++20, dcl.enum]\n/// \'using\' elaborated-enum-specifier ;\n/// The terminal name of the elaborated-enum-specifier undergoes\n/// ordinary lookup\n///\n/// elaborated-enum-specifier:\n/// \'enum\' nested-name-specifier[opt] identifier\nParser::DeclGroupPtrTy Parser::ParseUsingDeclaration(DeclaratorContext Context, const ParsedTemplateInfo &TemplateInfo, SourceLocation UsingLoc, SourceLocation &DeclEnd, ParsedAttributes &PrefixAttrs, AccessSpecifier AS) {\n // If we had any misplaced attributes from earlier, this is where they\n // should have been written.\n if (MisplacedAttrs.Range.isValid()) {\n (FirstAttr && FirstAttr->isRegularKeywordAttribute() ? Diag(Range.getBegin(), diag::err_keyword_not_allowed) << FirstAttr : Diag(Range.getBegin(), diag::err_attributes_not_allowed)) << FixItHint::CreateInsertionFromRange(Tok.getLocation(), CharSourceRange::getTokenRange(Range)) << FixItHint::CreateRemoval(Range);"},{P,1932,"#include \"clang/Basic/TransformTypeTraits.def\"\n // Forbid misplaced attributes. In cases of a reference, we pass attributes\n // to caller to handle.\n if (TUK != Sema::TUK_Reference) {\n if (AttrRange.isValid()) {\n (FirstAttr && FirstAttr->isRegularKeywordAttribute() ? Diag(Loc, diag::err_keyword_not_allowed) << FirstAttr : Diag(Loc, diag::err_attributes_not_allowed)) << AttrRange << FixItHint::CreateInsertionFromRange(AttrFixitLoc, CharSourceRange(AttrRange, true)) << FixItHint::CreateRemoval(AttrRange);"},{P,1979,"#include \"clang/Basic/TransformTypeTraits.def\"\n if (TemplateId) {\n if (TemplateId->isInvalid()) {\n } else if (TemplateInfo.Kind == ParsedTemplateInfo::ExplicitInstantiation && TUK == Sema::TUK_Declaration) {\n ProhibitCXX11Attributes(attrs, diag::err_attributes_not_allowed, diag::err_keyword_not_allowed,"},{P,1996,"#include \"clang/Basic/TransformTypeTraits.def\"\n if (TemplateId) {\n if (TemplateId->isInvalid()) {\n } else if (TemplateInfo.Kind == ParsedTemplateInfo::ExplicitInstantiation && TUK == Sema::TUK_Declaration) {\n } else if (TUK == Sema::TUK_Reference || (TUK == Sema::TUK_Friend && TemplateInfo.Kind == ParsedTemplateInfo::NonTemplate)) {\n ProhibitCXX11Attributes(attrs, diag::err_attributes_not_allowed, diag::err_keyword_not_allowed,"},{P,2066,"#include \"clang/Basic/TransformTypeTraits.def\"\n if (TemplateId) {\n } else if (TemplateInfo.Kind == ParsedTemplateInfo::ExplicitInstantiation && TUK == Sema::TUK_Declaration) {\n } else if (TUK == Sema::TUK_Friend && TemplateInfo.Kind != ParsedTemplateInfo::NonTemplate) {\n ProhibitCXX11Attributes(attrs, diag::err_attributes_not_allowed, diag::err_keyword_not_allowed,"},{P,2077,"#include \"clang/Basic/TransformTypeTraits.def\"\n if (TemplateId) {\n } else if (TemplateInfo.Kind == ParsedTemplateInfo::ExplicitInstantiation && TUK == Sema::TUK_Declaration) {\n } else if (TUK == Sema::TUK_Friend && TemplateInfo.Kind != ParsedTemplateInfo::NonTemplate) {\n } else {\n if (TUK != Sema::TUK_Declaration && TUK != Sema::TUK_Definition)\n ProhibitCXX11Attributes(attrs, diag::err_attributes_not_allowed, diag::err_keyword_not_allowed,"},{P,3060,"/// 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 while (true) {\n if (DS.isFriendSpecified()) {\n // C++11 [dcl.attr.grammar] p4: If an attribute-specifier-seq appertains\n // to a friend declaration, that declaration shall be a definition.\n //\n // Diagnose attributes that appear in a friend member function declarator:\n // friend int foo [[]] ();\n for (const ParsedAttr &AL : DeclaratorInfo.getAttributes())\n if (AL.isCXX11Attribute() || AL.isRegularKeywordAttribute()) {\n (AL.isRegularKeywordAttribute() ? Diag(Loc, diag::err_keyword_not_allowed) << AL : Diag(Loc, diag::err_attributes_not_allowed)) << AL.getRange();"},{P,4664,"void Parser::DiagnoseAndSkipCXX11Attributes() {\n if (EndLoc.isValid()) {\n (Keyword ? Diag(StartLoc, diag::err_keyword_not_allowed) << Keyword : Diag(StartLoc, diag::err_attributes_not_allowed)) << Range;"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/warn-unused-label-error.cpp"]={"clang/test/SemaCXX/warn-unused-label-error.cpp:15:7: error: an attribute list cannot appear here"} | ["clang/test/SemaCXX/warn-unused-label-error.cpp"]={"clang/test/SemaCXX/warn-unused-label-error.cpp:15:7: error: an attribute list cannot appear here"} | ||
Line 5,138: | Line 5,158: | ||
}, | }, | ||
["err_auto_bitfield"]={ | ["err_auto_bitfield"]={ | ||
[e]="cannot pass bit-field as __auto_type initializer in C", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot pass bit-field as __auto_type initializer in C", | [h]="cannot pass bit-field as __auto_type initializer in C", | ||
[ | [b]=n, | ||
[ | [j]="cannot pass bit\\-field as __auto_type initializer in C", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"e301ba2b4891",1447207335,"Add support for GCC\'s \'__auto_type\' extension, per the GCC manual:","Add support for GCC\'s \'__auto_type\' extension, per the GCC manual:"}, | |||
[ | [k]={{dc,4868,"/// Deduce the type for an auto type-specifier (C++11 [dcl.spec.auto]p6)\n///\n/// Note that this is done even if the initializer is dependent. (This is\n/// necessary to support partial ordering of templates using \'auto\'.)\n/// A dependent type will be produced when deducing from a dependent type.\n///\n/// \\param Type the type pattern using the auto type-specifier.\n/// \\param Init the initializer for the variable whose type is to be deduced.\n/// \\param Result if type deduction was successful, this will be set to the\n/// deduced type.\n/// \\param Info the argument will be updated to provide additional information\n/// about template argument deduction.\n/// \\param DependentDeduction Set if we should permit deduction in\n/// dependent cases. This is necessary for template partial ordering with\n/// \'auto\' template parameters. The template parameter depth to be used\n/// should be specified in the \'Info\' parameter.\n/// \\param IgnoreConstraints Set if we should not fail if the deduced type does\n/// not satisfy the type-constraint in the auto type.\nSema::TemplateDeductionResult Sema::DeduceAutoType(TypeLoc Type, Expr *Init, QualType &Result, TemplateDeductionInfo &Info, bool DependentDeduction, bool IgnoreConstraints, TemplateSpecCandidateSet *FailedTSC) {\n // If this is a \'decltype(auto)\' specifier, do the decltype dance.\n if (AT->isDecltypeAuto()) {\n } else {\n if (InitList) {\n } else {\n if (!getLangOpts().CPlusPlus && Init->refersToBitField()) {\n Diag(Loc, diag::err_auto_bitfield);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/auto-type.c"]={"clang/test/Sema/auto-type.c:20:40: error: cannot pass bit-field as __auto_type initializer in C"} | ["clang/test/Sema/auto-type.c"]={"clang/test/Sema/auto-type.c:20:40: error: cannot pass bit-field as __auto_type initializer in C"} | ||
Line 5,153: | Line 5,173: | ||
}, | }, | ||
["err_auto_different_deductions"]={ | ["err_auto_different_deductions"]={ | ||
[ | [e]="... deduced as A in declaration of B and deduced as C in declaration of D", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{\'auto\'|\'decltype(auto)\'|\'__auto_type\'|template arguments}0 deduced as %1 in declaration of %2 and deduced as %3 in declaration of %4", | ||
[ | [b]=n, | ||
[ | [j]="(?:\'auto\'|\'decltype\\(auto\\)\'|\'__auto_type\'|template arguments) deduced as (.*?) in declaration of (.*?) and deduced as (.*?) in declaration of (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Nb,1298171975,fb,fb}, | ||
[k]={{ | [k]={{s,14629,"/// BuildDeclaratorGroup - convert a list of declarations into a declaration\n/// group, performing any necessary semantic checking.\nSema::DeclGroupPtrTy Sema::BuildDeclaratorGroup(MutableArrayRef<Decl *> Group) {\n // C++14 [dcl.spec.auto]p7: (DR1347)\n // If the type that replaces the placeholder type is not the same in each\n // deduction, the program is ill-formed.\n if (Group.size() > 1) {\n for (unsigned i = 0, e = Group.size(); i != e; ++i) {\n if (Deduced.isNull()) {\n } else if (!Context.hasSameType(DT->getDeducedType(), Deduced)) {\n auto Dia = Diag(D->getTypeSourceInfo()->getTypeLoc().getBeginLoc(), diag::err_auto_different_deductions) << (AT ? (unsigned)AT->getKeyword() : 3) << Deduced << DeducedDecl->getDeclName() << DT->getDeducedType() << D->getDeclName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/auto-invalid-init-crash.cpp"]={"clang/test/SemaCXX/auto-invalid-init-crash.cpp:7:1: error: \'auto\' deduced as \'int\' in declaration of \'c\' and deduced as \'std::initializer_list<int>\' in declaration of \'d\'"} | ["clang/test/SemaCXX/auto-invalid-init-crash.cpp"]={"clang/test/SemaCXX/auto-invalid-init-crash.cpp:7:1: error: \'auto\' deduced as \'int\' in declaration of \'c\' and deduced as \'std::initializer_list<int>\' in declaration of \'d\'"} | ||
Line 5,168: | Line 5,188: | ||
}, | }, | ||
["err_auto_expr_deduction_failure"]={ | ["err_auto_expr_deduction_failure"]={ | ||
[ | [e]="functional-style cast to A has incompatible initializer of type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="functional-style cast to %0 has incompatible initializer of type %1", | ||
[ | [b]=n, | ||
[ | [j]="functional\\-style cast to (.*?) has incompatible initializer of type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"f60dc3caa673",1620118562,xb,xb}, | ||
[k]={{y,1533,"ExprResult Sema::BuildCXXTypeConstructExpr(TypeSourceInfo *TInfo, SourceLocation LParenOrBraceLoc, MultiExprArg Exprs, SourceLocation RParenOrBraceLoc, bool ListInitialization) {\n if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Result != TDK_Success && Result != TDK_AlreadyDiagnosed)\n return ExprError(Diag(TyBeginLoc, diag::err_auto_expr_deduction_failure) << Ty << Deduce->getType() << FullRange << Deduce->getSourceRange());"}}, | [k]={{y,1533,"ExprResult Sema::BuildCXXTypeConstructExpr(TypeSourceInfo *TInfo, SourceLocation LParenOrBraceLoc, MultiExprArg Exprs, SourceLocation RParenOrBraceLoc, bool ListInitialization) {\n if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Result != TDK_Success && Result != TDK_AlreadyDiagnosed)\n return ExprError(Diag(TyBeginLoc, diag::err_auto_expr_deduction_failure) << Ty << Deduce->getType() << FullRange << Deduce->getSourceRange());"}}, | ||
[o]={ | [o]={ | ||
Line 5,183: | Line 5,203: | ||
}, | }, | ||
["err_auto_expr_init_multiple_expressions"]={ | ["err_auto_expr_init_multiple_expressions"]={ | ||
[ | [e]="initializer for functional-style cast to A contains multiple expressions", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="initializer for functional-style cast to %0 contains multiple expressions", | ||
[ | [b]=n, | ||
[ | [j]="initializer for functional\\-style cast to (.*?) contains multiple expressions", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"f60dc3caa673",1620118562,xb,xb}, | ||
[k]={{y,1516,"ExprResult Sema::BuildCXXTypeConstructExpr(TypeSourceInfo *TInfo, SourceLocation LParenOrBraceLoc, MultiExprArg Exprs, SourceLocation RParenOrBraceLoc, bool ListInitialization) {\n if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Inits.size() > 1) {\n return ExprError(Diag(FirstBad->getBeginLoc(), diag::err_auto_expr_init_multiple_expressions) << Ty << FullRange);"}}, | [k]={{y,1516,"ExprResult Sema::BuildCXXTypeConstructExpr(TypeSourceInfo *TInfo, SourceLocation LParenOrBraceLoc, MultiExprArg Exprs, SourceLocation RParenOrBraceLoc, bool ListInitialization) {\n if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Inits.size() > 1) {\n return ExprError(Diag(FirstBad->getBeginLoc(), diag::err_auto_expr_init_multiple_expressions) << Ty << FullRange);"}}, | ||
[o]={ | [o]={ | ||
Line 5,198: | Line 5,218: | ||
}, | }, | ||
["err_auto_expr_init_no_expression"]={ | ["err_auto_expr_init_no_expression"]={ | ||
[ | [e]="initializer for functional-style cast to A is empty", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="initializer for functional-style cast to %0 is empty", | ||
[ | [b]=n, | ||
[ | [j]="initializer for functional\\-style cast to (.*?) is empty", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"f60dc3caa673",1620118562,xb,xb}, | ||
[k]={{y,1511,"ExprResult Sema::BuildCXXTypeConstructExpr(TypeSourceInfo *TInfo, SourceLocation LParenOrBraceLoc, MultiExprArg Exprs, SourceLocation RParenOrBraceLoc, bool ListInitialization) {\n if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Inits.empty())\n return ExprError(Diag(TyBeginLoc, diag::err_auto_expr_init_no_expression) << Ty << FullRange);"}}, | [k]={{y,1511,"ExprResult Sema::BuildCXXTypeConstructExpr(TypeSourceInfo *TInfo, SourceLocation LParenOrBraceLoc, MultiExprArg Exprs, SourceLocation RParenOrBraceLoc, bool ListInitialization) {\n if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Inits.empty())\n return ExprError(Diag(TyBeginLoc, diag::err_auto_expr_init_no_expression) << Ty << FullRange);"}}, | ||
[o]={ | [o]={ | ||
Line 5,213: | Line 5,233: | ||
}, | }, | ||
["err_auto_expr_init_paren_braces"]={ | ["err_auto_expr_init_paren_braces"]={ | ||
[ | [e]="cannot deduce actual type for A from ... initializer list", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot deduce actual type for %1 from %select{parenthesized|nested}0 initializer list", | ||
[ | [b]=n, | ||
[ | [j]="cannot deduce actual type for (.*?) from (?:parenthesized|nested) initializer list", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"f60dc3caa673",1620118562,xb,xb}, | ||
[k]={{y,1526,"ExprResult Sema::BuildCXXTypeConstructExpr(TypeSourceInfo *TInfo, SourceLocation LParenOrBraceLoc, MultiExprArg Exprs, SourceLocation RParenOrBraceLoc, bool ListInitialization) {\n if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (isa<InitListExpr>(Deduce))\n return ExprError(Diag(Deduce->getBeginLoc(), diag::err_auto_expr_init_paren_braces) << ListInitialization << Ty << FullRange);"},{y,2065,"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 if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (isa<InitListExpr>(Deduce))\n return ExprError(Diag(Deduce->getBeginLoc(), diag::err_auto_expr_init_paren_braces) << Braced << AllocType << TypeRange);"}}, | [k]={{y,1526,"ExprResult Sema::BuildCXXTypeConstructExpr(TypeSourceInfo *TInfo, SourceLocation LParenOrBraceLoc, MultiExprArg Exprs, SourceLocation RParenOrBraceLoc, bool ListInitialization) {\n if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (isa<InitListExpr>(Deduce))\n return ExprError(Diag(Deduce->getBeginLoc(), diag::err_auto_expr_init_paren_braces) << ListInitialization << Ty << FullRange);"},{y,2065,"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 if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (isa<InitListExpr>(Deduce))\n return ExprError(Diag(Deduce->getBeginLoc(), diag::err_auto_expr_init_paren_braces) << Braced << AllocType << TypeRange);"}}, | ||
[o]={ | [o]={ | ||
Line 5,228: | Line 5,248: | ||
}, | }, | ||
["err_auto_fn_deduction_failure"]={ | ["err_auto_fn_deduction_failure"]={ | ||
[ | [e]="cannot deduce return type A from returned value of type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot deduce return type %0 from returned value of type %1", | ||
[ | [b]=n, | ||
[ | [j]="cannot deduce return type (.*?) from returned value of type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Db,1367650832,X,X}, | ||
[k]={{ | [k]={{bb,3869,"/// Deduce the return type for a function from a returned expression, per\n/// C++1y [dcl.spec.auto]p6.\nbool Sema::DeduceFunctionTypeFromReturnExpr(FunctionDecl *FD, SourceLocation ReturnLoc, Expr *RetExpr, const AutoType *AT) {\n {\n default:\n Diag(RetExpr->getExprLoc(), diag::err_auto_fn_deduction_failure) << OrigResultType.getType() << RetExpr->getType();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/deduced-return-void.cpp"]={"clang/test/SemaCXX/deduced-return-void.cpp:74:10: error: cannot deduce return type \'auto *\' from returned value of type \'void\'","clang/test/SemaCXX/deduced-return-void.cpp:82:10: error: cannot deduce return type \'auto *\' from returned value of type \'void\'","clang/test/SemaCXX/deduced-return-void.cpp:90:10: error: cannot deduce return type \'auto *\' from returned value of type \'void\'","clang/test/SemaCXX/deduced-return-void.cpp:98:10: error: cannot deduce return type \'auto *\' from returned value of type \'void\'"} | ["clang/test/SemaCXX/deduced-return-void.cpp"]={"clang/test/SemaCXX/deduced-return-void.cpp:74:10: error: cannot deduce return type \'auto *\' from returned value of type \'void\'","clang/test/SemaCXX/deduced-return-void.cpp:82:10: error: cannot deduce return type \'auto *\' from returned value of type \'void\'","clang/test/SemaCXX/deduced-return-void.cpp:90:10: error: cannot deduce return type \'auto *\' from returned value of type \'void\'","clang/test/SemaCXX/deduced-return-void.cpp:98:10: error: cannot deduce return type \'auto *\' from returned value of type \'void\'"} | ||
Line 5,243: | Line 5,263: | ||
}, | }, | ||
["err_auto_fn_different_deductions"]={ | ["err_auto_fn_different_deductions"]={ | ||
[ | [e]="\'...\' in return type deduced as A here but deduced as B in earlier return statement", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'%select{auto|decltype(auto)}0\' in return type deduced as %1 here but deduced as %2 in earlier return statement", | ||
[ | [b]=n, | ||
[ | [j]="\'(?:auto|decltype\\(auto\\))\' in return type deduced as (.*?) here but deduced as (.*?) in earlier return statement", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Db,1367650832,X,X}, | ||
[k]={{ | [k]={{bb,3863,"/// Deduce the return type for a function from a returned expression, per\n/// C++1y [dcl.spec.auto]p6.\nbool Sema::DeduceFunctionTypeFromReturnExpr(FunctionDecl *FD, SourceLocation ReturnLoc, Expr *RetExpr, const AutoType *AT) {\n {\n case TDK_Inconsistent: {\n if (LambdaSI && LambdaSI->HasImplicitReturnType)\n else\n Diag(ReturnLoc, diag::err_auto_fn_different_deductions) << (AT->isDecltypeAuto() ? 1 : 0) << Info.SecondArg << Info.FirstArg;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/cxx2b-consteval-if.cpp"]={"clang/test/SemaCXX/cxx2b-consteval-if.cpp:6:19: error: \'auto\' in return type deduced as \'double\' here but deduced as \'int\' in earlier return statement","clang/test/SemaCXX/cxx2b-consteval-if.cpp:11:19: error: \'auto\' in return type deduced as \'double\' here but deduced as \'int\' in earlier return statement","clang/test/SemaCXX/cxx2b-consteval-if.cpp:26:5: error: \'auto\' in return type deduced as \'double\' here but deduced as \'int\' in earlier return statement"} | ["clang/test/SemaCXX/cxx2b-consteval-if.cpp"]={"clang/test/SemaCXX/cxx2b-consteval-if.cpp:6:19: error: \'auto\' in return type deduced as \'double\' here but deduced as \'int\' in earlier return statement","clang/test/SemaCXX/cxx2b-consteval-if.cpp:11:19: error: \'auto\' in return type deduced as \'double\' here but deduced as \'int\' in earlier return statement","clang/test/SemaCXX/cxx2b-consteval-if.cpp:26:5: error: \'auto\' in return type deduced as \'double\' here but deduced as \'int\' in earlier return statement"} | ||
Line 5,258: | Line 5,278: | ||
}, | }, | ||
["err_auto_fn_no_return_but_not_auto"]={ | ["err_auto_fn_no_return_but_not_auto"]={ | ||
[ | [e]="cannot deduce return type A for function with no return statements", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot deduce return type %0 for function with no return statements", | ||
[ | [b]=n, | ||
[ | [j]="cannot deduce return type (.*?) for function with no return statements", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Db,1367650832,X,X}, | ||
[k]={{ | [k]={{s,15589,"Decl *Sema::ActOnFinishFunctionBody(Decl *dcl, Stmt *Body, bool IsInstantiation) {\n {\n if (FD) {\n if (getLangOpts().CPlusPlus14) {\n if (!FD->isInvalidDecl() && Body && !FD->isDependentContext() && FD->getReturnType()->isUndeducedType()) {\n // For a function with a deduced result type to return void,\n // the result type as written must be \'auto\' or \'decltype(auto)\',\n // possibly cv-qualified or constrained, but not ref-qualified.\n if (!FD->getReturnType()->getAs<AutoType>()) {\n Diag(dcl->getLocation(), diag::err_auto_fn_no_return_but_not_auto) << FD->getReturnType();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/deduced-return-void.cpp"]={"clang/test/SemaCXX/deduced-return-void.cpp:69:7: error: cannot deduce return type \'auto *\' for function with no return statements","clang/test/SemaCXX/deduced-return-void.cpp:85:11: error: cannot deduce return type \'auto *\' for function with no return statements","clang/test/SemaCXX/deduced-return-void.cpp:104:7: error: cannot deduce return type \'auto &\' for function with no return statements","clang/test/SemaCXX/deduced-return-void.cpp:122:11: error: cannot deduce return type \'auto &\' for function with no return statements"} | ["clang/test/SemaCXX/deduced-return-void.cpp"]={"clang/test/SemaCXX/deduced-return-void.cpp:69:7: error: cannot deduce return type \'auto *\' for function with no return statements","clang/test/SemaCXX/deduced-return-void.cpp:85:11: error: cannot deduce return type \'auto *\' for function with no return statements","clang/test/SemaCXX/deduced-return-void.cpp:104:7: error: cannot deduce return type \'auto &\' for function with no return statements","clang/test/SemaCXX/deduced-return-void.cpp:122:11: error: cannot deduce return type \'auto &\' for function with no return statements"} | ||
Line 5,273: | Line 5,293: | ||
}, | }, | ||
["err_auto_fn_return_init_list"]={ | ["err_auto_fn_return_init_list"]={ | ||
[e]="cannot deduce return type from initializer list", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot deduce return type from initializer list", | [h]="cannot deduce return type from initializer list", | ||
[ | [b]=n, | ||
[ | [j]="cannot deduce return type from initializer list", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={Db,1367650832,X,X}, | |||
[k]={{bb,3799,"/// Deduce the return type for a function from a returned expression, per\n/// C++1y [dcl.spec.auto]p6.\nbool Sema::DeduceFunctionTypeFromReturnExpr(FunctionDecl *FD, SourceLocation ReturnLoc, Expr *RetExpr, const AutoType *AT) {\n if (RetExpr && isa<InitListExpr>(RetExpr)) {\n Diag(RetExpr->getExprLoc(), getCurLambda() ? diag::err_lambda_return_init_list : diag::err_auto_fn_return_init_list) << RetExpr->getSourceRange();"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7-cxx14.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7-cxx14.cpp:99:29: error: cannot deduce return type from initializer list","clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7-cxx14.cpp:100:39: error: cannot deduce return type from initializer list"} | ["clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7-cxx14.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7-cxx14.cpp:99:29: error: cannot deduce return type from initializer list","clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7-cxx14.cpp:100:39: error: cannot deduce return type from initializer list"} | ||
Line 5,288: | Line 5,308: | ||
}, | }, | ||
["err_auto_fn_return_void_but_not_auto"]={ | ["err_auto_fn_return_void_but_not_auto"]={ | ||
[ | [e]="cannot deduce return type A from omitted return expression", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot deduce return type %0 from omitted return expression", | ||
[ | [b]=n, | ||
[ | [j]="cannot deduce return type (.*?) from omitted return expression", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Db,1367650832,X,X}, | ||
[k]={{ | [k]={{bb,3823,"/// Deduce the return type for a function from a returned expression, per\n/// C++1y [dcl.spec.auto]p6.\nbool Sema::DeduceFunctionTypeFromReturnExpr(FunctionDecl *FD, SourceLocation ReturnLoc, Expr *RetExpr, const AutoType *AT) {\n if (!RetExpr) {\n // For a function with a deduced result type to return with omitted\n // expression, the result type as written must be \'auto\' or\n // \'decltype(auto)\', possibly cv-qualified or constrained, but not\n // ref-qualified.\n if (!OrigResultType.getType()->getAs<AutoType>()) {\n Diag(ReturnLoc, diag::err_auto_fn_return_void_but_not_auto) << OrigResultType.getType();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/deduced-return-void.cpp"]={"clang/test/SemaCXX/deduced-return-void.cpp:71:3: error: cannot deduce return type \'auto *\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:78:3: error: cannot deduce return type \'auto *\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:87:3: error: cannot deduce return type \'auto *\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:94:3: error: cannot deduce return type \'auto *\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:107:3: error: cannot deduce return type \'auto &\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:114:3: error: cannot deduce return type \'auto &\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:124:3: error: cannot deduce return type \'auto &\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:131:3: error: cannot deduce return type \'auto &\' from omitted return expression"} | ["clang/test/SemaCXX/deduced-return-void.cpp"]={"clang/test/SemaCXX/deduced-return-void.cpp:71:3: error: cannot deduce return type \'auto *\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:78:3: error: cannot deduce return type \'auto *\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:87:3: error: cannot deduce return type \'auto *\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:94:3: error: cannot deduce return type \'auto *\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:107:3: error: cannot deduce return type \'auto &\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:114:3: error: cannot deduce return type \'auto &\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:124:3: error: cannot deduce return type \'auto &\' from omitted return expression","clang/test/SemaCXX/deduced-return-void.cpp:131:3: error: cannot deduce return type \'auto &\' from omitted return expression"} | ||
Line 5,303: | Line 5,323: | ||
}, | }, | ||
["err_auto_fn_used_before_defined"]={ | ["err_auto_fn_used_before_defined"]={ | ||
[ | [e]="function A with deduced return type cannot be used before it is defined", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="function %0 with deduced return type cannot be used before it is defined", | ||
[ | [b]=n, | ||
[ | [j]="function (.*?) with deduced return type cannot be used before it is defined", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Db,1367650832,X,X}, | ||
[k]={{ | [k]={{dc,5038,"bool Sema::DeduceReturnType(FunctionDecl *FD, SourceLocation Loc, bool Diagnose) {\n if (StillUndeduced && Diagnose && !FD->isInvalidDecl()) {\n Diag(Loc, diag::err_auto_fn_used_before_defined) << FD;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/deduced-return-type-cxx14.cpp"]={"clang/test/SemaCXX/deduced-return-type-cxx14.cpp:22:14: error: function \'operator auto\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:97:9: error: function \'fwd_decl\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:98:16: error: function \'fwd_decl\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:108:16: error: function \'fac_2\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:142:11: error: function \'fwd_decl<int>\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:259:14: error: function \'f\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:350:15: error: function \'f\' with deduced return type cannot be used before it is defined"} | ["clang/test/SemaCXX/deduced-return-type-cxx14.cpp"]={"clang/test/SemaCXX/deduced-return-type-cxx14.cpp:22:14: error: function \'operator auto\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:97:9: error: function \'fwd_decl\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:98:16: error: function \'fwd_decl\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:108:16: error: function \'fac_2\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:142:11: error: function \'fwd_decl<int>\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:259:14: error: function \'f\' with deduced return type cannot be used before it is defined","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:350:15: error: function \'f\' with deduced return type cannot be used before it is defined"} | ||
Line 5,318: | Line 5,338: | ||
}, | }, | ||
["err_auto_fn_virtual"]={ | ["err_auto_fn_virtual"]={ | ||
[e]="function with deduced return type cannot be virtual", | |||
[d]=l, | |||
[f]=m, | |||
[h]="function with deduced return type cannot be virtual", | [h]="function with deduced return type cannot be virtual", | ||
[ | [b]=n, | ||
[ | [j]="function with deduced return type cannot be virtual", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={Db,1367650832,X,X}, | |||
[k]={{s,9898,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\n if (getLangOpts().CPlusPlus) {\n // C++ [dcl.fct.spec]p5:\n // The virtual specifier shall only be used in declarations of\n // nonstatic class member functions that appear within a\n // member-specification of a class declaration; see 10.3.\n //\n if (isVirtual && !NewFD->isInvalidDecl()) {\n if (getLangOpts().CPlusPlus14 && NewFD->getReturnType()->isUndeducedType())\n Diag(D.getDeclSpec().getVirtualSpecLoc(), diag::err_auto_fn_virtual);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/deduced-return-type-cxx14.cpp"]={"clang/test/SemaCXX/deduced-return-type-cxx14.cpp:313:5: error: function with deduced return type cannot be virtual","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:324:14: error: function with deduced return type cannot be virtual","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:325:18: error: function with deduced return type cannot be virtual"} | ["clang/test/SemaCXX/deduced-return-type-cxx14.cpp"]={"clang/test/SemaCXX/deduced-return-type-cxx14.cpp:313:5: error: function with deduced return type cannot be virtual","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:324:14: error: function with deduced return type cannot be virtual","clang/test/SemaCXX/deduced-return-type-cxx14.cpp:325:18: error: function with deduced return type cannot be virtual"} | ||
Line 5,333: | Line 5,353: | ||
}, | }, | ||
["err_auto_inconsistent_deduction"]={ | ["err_auto_inconsistent_deduction"]={ | ||
[ | [e]="deduced conflicting types (A vs B) for initializer list element type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="deduced conflicting types %diff{($ vs $) |}0,1for initializer list element type", | ||
[ | [b]=n, | ||
[ | [j]="deduced conflicting types (?:\\((.*?) vs (.*?)\\) |)for initializer list element type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"b1efc9b410ea",1504053848,"Give a better error if auto deduction fails due to inconsistent element types in a braced initialize...","Give a better error if auto deduction fails due to inconsistent element types in a braced initializer list."}, | ||
[k]={{ | [k]={{dc,4854,"/// Deduce the type for an auto type-specifier (C++11 [dcl.spec.auto]p6)\n///\n/// Note that this is done even if the initializer is dependent. (This is\n/// necessary to support partial ordering of templates using \'auto\'.)\n/// A dependent type will be produced when deducing from a dependent type.\n///\n/// \\param Type the type pattern using the auto type-specifier.\n/// \\param Init the initializer for the variable whose type is to be deduced.\n/// \\param Result if type deduction was successful, this will be set to the\n/// deduced type.\n/// \\param Info the argument will be updated to provide additional information\n/// about template argument deduction.\n/// \\param DependentDeduction Set if we should permit deduction in\n/// dependent cases. This is necessary for template partial ordering with\n/// \'auto\' template parameters. The template parameter depth to be used\n/// should be specified in the \'Info\' parameter.\n/// \\param IgnoreConstraints Set if we should not fail if the deduced type does\n/// not satisfy the type-constraint in the auto type.\nSema::TemplateDeductionResult Sema::DeduceAutoType(TypeLoc Type, Expr *Init, QualType &Result, TemplateDeductionInfo &Info, bool DependentDeduction, bool IgnoreConstraints, TemplateSpecCandidateSet *FailedTSC) {\n // If this is a \'decltype(auto)\' specifier, do the decltype dance.\n if (AT->isDecltypeAuto()) {\n } else {\n if (InitList) {\n for (Expr *Init : InitList->inits()) {\n if (auto TDK = DeduceTemplateArgumentsFromCallArgument(*this, TemplateParamsSt.get(), 0, TemplArg, Init, Info, Deduced, OriginalCallArgs, /*Decomposed=*/true,\n if (TDK == TDK_Inconsistent) {\n Diag(Info.getLocation(), diag::err_auto_inconsistent_deduction) << Info.FirstArg << Info.SecondArg << DeducedFromInitRange << Init->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp"]={"clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:139:13: error: deduced conflicting types (\'int\' vs \'double\') for initializer list element type","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:144:13: error: deduced conflicting types (\'void (*)(int)\' vs \'void (*)(float)\') for initializer list element type","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:147:16: error: deduced conflicting types (\'double\' vs \'float\') for initializer list element type"} | ["clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp"]={"clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:139:13: error: deduced conflicting types (\'int\' vs \'double\') for initializer list element type","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:144:13: error: deduced conflicting types (\'void (*)(int)\' vs \'void (*)(float)\') for initializer list element type","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:147:16: error: deduced conflicting types (\'double\' vs \'float\') for initializer list element type"} | ||
Line 5,348: | Line 5,368: | ||
}, | }, | ||
["err_auto_init_list_from_c"]={ | ["err_auto_init_list_from_c"]={ | ||
[e]="cannot use __auto_type with initializer list in C", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot use __auto_type with initializer list in C", | [h]="cannot use __auto_type with initializer list in C", | ||
[ | [b]=n, | ||
[ | [j]="cannot use __auto_type with initializer list in C", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"e301ba2b4891",1447207335,"Add support for GCC\'s \'__auto_type\' extension, per the GCC manual:","Add support for GCC\'s \'__auto_type\' extension, per the GCC manual:"}, | |||
[k]={{dc,4791,"/// Deduce the type for an auto type-specifier (C++11 [dcl.spec.auto]p6)\n///\n/// Note that this is done even if the initializer is dependent. (This is\n/// necessary to support partial ordering of templates using \'auto\'.)\n/// A dependent type will be produced when deducing from a dependent type.\n///\n/// \\param Type the type pattern using the auto type-specifier.\n/// \\param Init the initializer for the variable whose type is to be deduced.\n/// \\param Result if type deduction was successful, this will be set to the\n/// deduced type.\n/// \\param Info the argument will be updated to provide additional information\n/// about template argument deduction.\n/// \\param DependentDeduction Set if we should permit deduction in\n/// dependent cases. This is necessary for template partial ordering with\n/// \'auto\' template parameters. The template parameter depth to be used\n/// should be specified in the \'Info\' parameter.\n/// \\param IgnoreConstraints Set if we should not fail if the deduced type does\n/// not satisfy the type-constraint in the auto type.\nSema::TemplateDeductionResult Sema::DeduceAutoType(TypeLoc Type, Expr *Init, QualType &Result, TemplateDeductionInfo &Info, bool DependentDeduction, bool IgnoreConstraints, TemplateSpecCandidateSet *FailedTSC) {\n if (!getLangOpts().CPlusPlus && InitList) {\n Diag(Init->getBeginLoc(), diag::err_auto_init_list_from_c);"}} | |||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_auto_missing_trailing_return"]={ | ["err_auto_missing_trailing_return"]={ | ||
[e]="\'auto\' return without trailing return type; deduced return types are a C++14 extension", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'auto\' return without trailing return type; deduced return types are a C++14 extension", | [h]="\'auto\' return without trailing return type; deduced return types are a C++14 extension", | ||
[ | [b]=n, | ||
[ | [j]="\'auto\' return without trailing return type; deduced return types are a C\\+\\+14 extension", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"7fb25418ed72",1285958690,"Implement the C++0x \"trailing return type\" feature, e.g.,","Implement the C++0x \"trailing return type\" feature, e.g.,"}, | |||
[ | [k]={{t,5198,"static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, QualType declSpecType, TypeSourceInfo *TInfo) {\n for (unsigned i = 0, e = D.getNumTypeObjects(); i != e; ++i) {\n case DeclaratorChunk::Function: {\n // Check for auto functions and trailing return type and adjust the\n // return type accordingly.\n if (!D.isInvalidType()) {\n // trailing-return-type is only required if we\'re declaring a function,\n // and not, for instance, a pointer to a function.\n if (D.getDeclSpec().hasAutoTypeSpec() && !FTI.hasTrailingReturnType() && chunkIndex == 0) {\n if (!S.getLangOpts().CPlusPlus14) {\n S.Diag(D.getDeclSpec().getTypeSpecTypeLoc(), D.getDeclSpec().getTypeSpecType() == DeclSpec::TST_auto ? diag::err_auto_missing_trailing_return : diag::err_deduced_return_type);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/ParserHLSL/group_shared_202x.hlsl"]={"clang/test/ParserHLSL/group_shared_202x.hlsl:21:1: error: \'auto\' return without trailing return type; deduced return types are a C++14 extension"} | ["clang/test/ParserHLSL/group_shared_202x.hlsl"]={"clang/test/ParserHLSL/group_shared_202x.hlsl:21:1: error: \'auto\' return without trailing return type; deduced return types are a C++14 extension"} | ||
Line 5,375: | Line 5,395: | ||
}, | }, | ||
["err_auto_new_ctor_multiple_expressions"]={ | ["err_auto_new_ctor_multiple_expressions"]={ | ||
[ | [e]="new expression for type A contains multiple constructor arguments", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="new expression for type %0 contains multiple constructor arguments", | ||
[ | [b]=n, | ||
[ | [j]="new expression for type (.*?) contains multiple constructor arguments", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Nb,1298171975,fb,fb}, | ||
[k]={{y,2056,"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 if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Inits.size() > 1) {\n return ExprError(Diag(FirstBad->getBeginLoc(), diag::err_auto_new_ctor_multiple_expressions) << AllocType << TypeRange);"}}, | [k]={{y,2056,"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 if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Inits.size() > 1) {\n return ExprError(Diag(FirstBad->getBeginLoc(), diag::err_auto_new_ctor_multiple_expressions) << AllocType << TypeRange);"}}, | ||
[o]={ | [o]={ | ||
Line 5,390: | Line 5,410: | ||
}, | }, | ||
["err_auto_new_deduction_failure"]={ | ["err_auto_new_deduction_failure"]={ | ||
[ | [e]="new expression for type A has incompatible constructor argument of type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="new expression for type %0 has incompatible constructor argument of type %1", | ||
[ | [b]=n, | ||
[ | [j]="new expression for type (.*?) has incompatible constructor argument of type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Nb,1298171975,fb,fb}, | ||
[k]={{y,2072,"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 if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Result != TDK_Success && Result != TDK_AlreadyDiagnosed)\n return ExprError(Diag(StartLoc, diag::err_auto_new_deduction_failure) << AllocType << Deduce->getType() << TypeRange << Deduce->getSourceRange());"}}, | [k]={{y,2072,"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 if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (Result != TDK_Success && Result != TDK_AlreadyDiagnosed)\n return ExprError(Diag(StartLoc, diag::err_auto_new_deduction_failure) << AllocType << Deduce->getType() << TypeRange << Deduce->getSourceRange());"}}, | ||
[o]={ | [o]={ | ||
Line 5,405: | Line 5,425: | ||
}, | }, | ||
["err_auto_new_requires_ctor_arg"]={ | ["err_auto_new_requires_ctor_arg"]={ | ||
[ | [e]="new expression for type A requires a constructor argument", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="new expression for type %0 requires a constructor argument", | ||
[ | [b]=n, | ||
[ | [j]="new expression for type (.*?) requires a constructor argument", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Nb,1298171975,fb,fb}, | ||
[k]={{y,2051,"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 if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (initStyle == CXXNewExpr::NoInit || Inits.empty())\n return ExprError(Diag(StartLoc, diag::err_auto_new_requires_ctor_arg) << AllocType << TypeRange);"}}, | [k]={{y,2051,"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 if (Deduced && !Deduced->isDeduced() && isa<DeducedTemplateSpecializationType>(Deduced)) {\n } else if (Deduced && !Deduced->isDeduced()) {\n if (initStyle == CXXNewExpr::NoInit || Inits.empty())\n return ExprError(Diag(StartLoc, diag::err_auto_new_requires_ctor_arg) << AllocType << TypeRange);"}}, | ||
[o]={ | [o]={ | ||
Line 5,420: | Line 5,440: | ||
}, | }, | ||
["err_auto_non_deduced_not_alone"]={ | ["err_auto_non_deduced_not_alone"]={ | ||
[ | [e]="... must be the only declaration in its group", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{function with deduced return type|declaration with trailing return type}0 must be the only declaration in its group", | ||
[ | [b]=n, | ||
[ | [j]="(?:function with deduced return type|declaration with trailing return type) must be the only declaration in its group", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"8210ed558662",1484274121,"Implement DR1265 (wg21.link/cwg1265).","Implement DR1265 (wg21.link/cwg1265)."}, | ||
[k]={{ | [k]={{s,14580,"Sema::DeclGroupPtrTy Sema::FinalizeDeclaratorGroup(Scope *S, const DeclSpec &DS, ArrayRef<Decl *> Group) {\n for (unsigned i = 0, e = Group.size(); i != e; ++i) {\n if (Decl *D = Group[i]) {\n // For declarators, there are some additional syntactic-ish checks we need\n // to perform.\n if (auto *DD = dyn_cast<DeclaratorDecl>(D)) {\n if (FirstDeclaratorInGroup != DD) {\n // A declarator that uses \'auto\' in any way other than to declare a\n // variable with a deduced type cannot be combined with any other\n // declarator in the same group.\n if (FirstNonDeducedAutoInGroup && !DiagnosedNonDeducedAuto) {\n Diag(FirstNonDeducedAutoInGroup->getLocation(), diag::err_auto_non_deduced_not_alone) << FirstNonDeducedAutoInGroup->getType()->hasAutoForTrailingReturnType() << FirstDeclaratorInGroup->getSourceRange() << DD->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp:25:10: error: declaration with trailing return type must be the only declaration in its group","clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp:28:8: error: declaration with trailing return type must be the only declaration in its group","clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp:30:8: error: declaration with trailing return type must be the only declaration in its group","clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp:41:15: error: declaration with trailing return type must be the only declaration in its group"} | ["clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp:25:10: error: declaration with trailing return type must be the only declaration in its group","clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp:28:8: error: declaration with trailing return type must be the only declaration in its group","clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp:30:8: error: declaration with trailing return type must be the only declaration in its group","clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7.cpp:41:15: error: declaration with trailing return type must be the only declaration in its group"} | ||
Line 5,435: | Line 5,455: | ||
}, | }, | ||
["err_auto_not_allowed"]={ | ["err_auto_not_allowed"]={ | ||
[ | [e]="... not allowed ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{\'auto\'|\'decltype(auto)\'|\'__auto_type\'|use of %select{class template|function template|variable template|alias template|template template parameter|concept|template}2 %3 requires template arguments; argument deduction}0 not allowed %select{in function prototype|in non-static struct member|in struct member|in non-static union member|in union member|in non-static class member|in interface member|in exception declaration|in template parameter until C++17|in block literal|in template argument|in typedef|in type alias|in function return type|in conversion function type|here|in lambda parameter|in type allocated by \'new\'|in K&R-style function parameter|in template parameter|in friend declaration|in function prototype that is not a function declaration|in requires expression parameter}1", | ||
[ | [b]=n, | ||
[ | [j]="(?:\'auto\'|\'decltype\\(auto\\)\'|\'__auto_type\'|use of (?:class template|function template|variable template|alias template|template template parameter|concept|template) (.*?) requires template arguments; argument deduction) not allowed (?:in function prototype|in non\\-static struct member|in struct member|in non\\-static union member|in union member|in non\\-static class member|in interface member|in exception declaration|in template parameter until C\\+\\+17|in block literal|in template argument|in typedef|in type alias|in function return type|in conversion function type|here|in lambda parameter|in type allocated by \'new\'|in K&R\\-style function parameter|in template parameter|in friend declaration|in function prototype that is not a function declaration|in requires expression parameter)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"94ff77a356a7",1246054739,"More auto work.","More auto work."}, | ||
[k]={{ | [k]={{t,3735,"static QualType GetDeclSpecTypeForDeclarator(TypeProcessingState &state, TypeSourceInfo *&ReturnTypeInfo) {\n // C++11 [dcl.spec.auto]p5: reject \'auto\' if it is not in an allowed context.\n if (Deduced) {\n if (Error != -1) {\n SemaRef.Diag(AutoRange.getBegin(), diag::err_auto_not_allowed) << Kind << Error << (int)SemaRef.getTemplateNameKindForDiagnostics(TN) << QualType(Deduced, 0) << AutoRange;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/auto-type.c"]={"clang/test/Sema/auto-type.c:12:12: error: \'__auto_type\' not allowed in struct member","clang/test/Sema/auto-type.c:16:1: error: \'__auto_type\' not allowed in function return type","clang/test/Sema/auto-type.c:25:1: error: \'__auto_type\' not allowed in K&R-style function parameter","clang/test/Sema/auto-type.c:39:11: error: \'__auto_type\' not allowed here"} | ["clang/test/Sema/auto-type.c"]={"clang/test/Sema/auto-type.c:12:12: error: \'__auto_type\' not allowed in struct member","clang/test/Sema/auto-type.c:16:1: error: \'__auto_type\' not allowed in function return type","clang/test/Sema/auto-type.c:25:1: error: \'__auto_type\' not allowed in K&R-style function parameter","clang/test/Sema/auto-type.c:39:11: error: \'__auto_type\' not allowed here"} | ||
Line 5,450: | Line 5,470: | ||
}, | }, | ||
["err_auto_not_allowed_var_inst"]={ | ["err_auto_not_allowed_var_inst"]={ | ||
[e]="\'auto\' variable template instantiation is not allowed", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'auto\' variable template instantiation is not allowed", | [h]="\'auto\' variable template instantiation is not allowed", | ||
[ | [b]=n, | ||
[ | [j]="\'auto\' variable template instantiation is not allowed", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"39a1e507ff0b",1375750985,"Started implementing variable templates. Top level declarations should be fully supported, up to som...","Started implementing variable templates. Top level declarations should be fully supported, up to some limitations documented as FIXMEs or TODO. Static data member templates work very partially. Static data member templates of class templates need particular attention..."}, | |||
[k]={{nc,10482,"DeclResult Sema::ActOnExplicitInstantiation(Scope *S, SourceLocation ExternLoc, SourceLocation TemplateLoc, Declarator &D) {\n if (!R->isFunctionType()) {\n if (!PrevTemplate) {\n } else {\n // C++1y [dcl.spec.auto]p6:\n // ... A program that uses auto or decltype(auto) in a context not\n // explicitly allowed in this section is ill-formed.\n //\n // This includes auto-typed variable template instantiations.\n if (R->isUndeducedType()) {\n Diag(T->getTypeLoc().getBeginLoc(), diag::err_auto_not_allowed_var_inst);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/cxx1y-variable-templates_top_level.cpp"]={"clang/test/SemaCXX/cxx1y-variable-templates_top_level.cpp:161:14: error: \'auto\' variable template instantiation is not allowed"} | ["clang/test/SemaCXX/cxx1y-variable-templates_top_level.cpp"]={"clang/test/SemaCXX/cxx1y-variable-templates_top_level.cpp:161:14: error: \'auto\' variable template instantiation is not allowed"} | ||
Line 5,465: | Line 5,485: | ||
}, | }, | ||
["err_auto_var_deduction_failure"]={ | ["err_auto_var_deduction_failure"]={ | ||
[ | [e]="variable A with type B has incompatible initializer of type C", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="variable %0 with type %1 has incompatible initializer of type %2", | ||
[ | [b]=n, | ||
[ | [j]="variable (.*?) with type (.*?) has incompatible initializer of type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Nb,1298171975,fb,fb}, | ||
[k]={{ | [k]={{dc,4977,"void Sema::DiagnoseAutoDeductionFailure(VarDecl *VDecl, Expr *Init) {\n if (isa<InitListExpr>(Init))\n else\n Diag(VDecl->getLocation(), VDecl->isInitCapture() ? diag::err_init_capture_deduction_failure : diag::err_auto_var_deduction_failure) << VDecl->getDeclName() << VDecl->getType() << Init->getType() << Init->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/auto-subst-failure.cpp"]={"clang/test/SemaCXX/auto-subst-failure.cpp:6:9: error: variable \'c\' with type \'auto *\' has incompatible initializer of type \'void\'","clang/test/SemaCXX/auto-subst-failure.cpp:10:9: error: variable \'g\' with type \'auto *\' has incompatible initializer of type \'void\'"} | ["clang/test/SemaCXX/auto-subst-failure.cpp"]={"clang/test/SemaCXX/auto-subst-failure.cpp:6:9: error: variable \'c\' with type \'auto *\' has incompatible initializer of type \'void\'","clang/test/SemaCXX/auto-subst-failure.cpp:10:9: error: variable \'g\' with type \'auto *\' has incompatible initializer of type \'void\'"} | ||
Line 5,480: | Line 5,500: | ||
}, | }, | ||
["err_auto_var_deduction_failure_from_init_list"]={ | ["err_auto_var_deduction_failure_from_init_list"]={ | ||
[ | [e]="cannot deduce actual type for variable A with type B from initializer list", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot deduce actual type for variable %0 with type %1 from initializer list", | ||
[ | [b]=n, | ||
[ | [j]="cannot deduce actual type for variable (.*?) with type (.*?) from initializer list", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"42acd4a05b52",1326840608,"Auto deduction support for std::initializer_list, including for-range support. This means you can no...","Auto deduction support for std::initializer_list, including for-range support. This means you can now write:"}, | ||
[k]={{ | [k]={{dc,4972,"void Sema::DiagnoseAutoDeductionFailure(VarDecl *VDecl, Expr *Init) {\n if (isa<InitListExpr>(Init))\n Diag(VDecl->getLocation(), VDecl->isInitCapture() ? diag::err_init_capture_deduction_failure_from_init_list : diag::err_auto_var_deduction_failure_from_init_list) << VDecl->getDeclName() << VDecl->getType() << Init->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp"]={"clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:352:12: error: cannot deduce actual type for variable \'x\' with type \'auto no_conversion_after_auto_list_deduction::X::*\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:355:10: error: cannot deduce actual type for variable \'y\' with type \'auto (*)()\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:359:18: error: cannot deduce actual type for variable \'a\' with type \'const auto\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:360:18: error: cannot deduce actual type for variable \'b\' with type \'const auto\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:361:18: error: cannot deduce actual type for variable \'c\' with type \'const auto\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:362:18: error: cannot deduce actual type for variable \'d\' with type \'const auto\' from initializer list"} | ["clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp"]={"clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:352:12: error: cannot deduce actual type for variable \'x\' with type \'auto no_conversion_after_auto_list_deduction::X::*\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:355:10: error: cannot deduce actual type for variable \'y\' with type \'auto (*)()\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:359:18: error: cannot deduce actual type for variable \'a\' with type \'const auto\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:360:18: error: cannot deduce actual type for variable \'b\' with type \'const auto\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:361:18: error: cannot deduce actual type for variable \'c\' with type \'const auto\' from initializer list","clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:362:18: error: cannot deduce actual type for variable \'d\' with type \'const auto\' from initializer list"} | ||
Line 5,495: | Line 5,515: | ||
}, | }, | ||
["err_auto_var_init_multiple_expressions"]={ | ["err_auto_var_init_multiple_expressions"]={ | ||
[ | [e]="initializer for variable A with type B contains multiple expressions", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="initializer for variable %0 with type %1 contains multiple expressions", | ||
[ | [b]=n, | ||
[ | [j]="initializer for variable (.*?) with type (.*?) contains multiple expressions", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Nb,1298171975,fb,fb}, | ||
[k]={{ | [k]={{s,12740,"QualType Sema::deduceVarTypeFromInitializer(VarDecl *VDecl, DeclarationName Name, QualType Type, TypeSourceInfo *TSI, SourceRange Range, bool DirectInit, Expr *Init) {\n if (DeduceInits.size() > 1) {\n Diag(DeduceInits[1]->getBeginLoc(), IsInitCapture ? diag::err_init_capture_multiple_expressions : diag::err_auto_var_init_multiple_expressions) << VN << Type << Range;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/dependent-auto.cpp"]={"clang/test/SemaCXX/dependent-auto.cpp:11:10: error: initializer for variable \'x\' with type \'auto\' contains multiple expressions"} | ["clang/test/SemaCXX/dependent-auto.cpp"]={"clang/test/SemaCXX/dependent-auto.cpp:11:10: error: initializer for variable \'x\' with type \'auto\' contains multiple expressions"} | ||
Line 5,510: | Line 5,530: | ||
}, | }, | ||
["err_auto_var_init_no_expression"]={ | ["err_auto_var_init_no_expression"]={ | ||
[ | [e]="initializer for variable A with type B is empty", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="initializer for variable %0 with type %1 is empty", | ||
[ | [b]=n, | ||
[ | [j]="initializer for variable (.*?) with type (.*?) is empty", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"de30e523b40d",1325802848,"Tweak the fix to PR8977: an empty expression-list represents value initialization, not default initi...","Tweak the fix to PR8977: an empty expression-list represents value initialization, not default initialization. Fixes PR11712."}, | ||
[k]={{ | [k]={{s,12732,"QualType Sema::deduceVarTypeFromInitializer(VarDecl *VDecl, DeclarationName Name, QualType Type, TypeSourceInfo *TSI, SourceRange Range, bool DirectInit, Expr *Init) {\n // Deduction only works if we have exactly one source expression.\n if (DeduceInits.empty()) {\n Diag(Init->getBeginLoc(), IsInitCapture ? diag::err_init_capture_no_expression : diag::err_auto_var_init_no_expression) << VN << Type << Range;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/dependent-auto.cpp"]={"clang/test/SemaCXX/dependent-auto.cpp:11:9: error: initializer for variable \'x\' with type \'auto\' is empty"} | ["clang/test/SemaCXX/dependent-auto.cpp"]={"clang/test/SemaCXX/dependent-auto.cpp:11:9: error: initializer for variable \'x\' with type \'auto\' is empty"} | ||
Line 5,525: | Line 5,545: | ||
}, | }, | ||
["err_auto_var_init_paren_braces"]={ | ["err_auto_var_init_paren_braces"]={ | ||
[ | [e]="cannot deduce type for variable A with type B from ... initializer list", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot deduce type for variable %1 with type %2 from %select{parenthesized|nested}0 initializer list", | ||
[ | [b]=n, | ||
[ | [j]="cannot deduce type for variable (.*?) with type (.*?) from (?:parenthesized|nested) initializer list", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"66204ecff985",1394646165,"DR1346: a parenthesized braced-init-list cannot be used as the initializer when","DR1346: a parenthesized braced-init-list cannot be used as the initializer when"}, | ||
[k]={{ | [k]={{s,12749,"QualType Sema::deduceVarTypeFromInitializer(VarDecl *VDecl, DeclarationName Name, QualType Type, TypeSourceInfo *TSI, SourceRange Range, bool DirectInit, Expr *Init) {\n if (DirectInit && isa<InitListExpr>(DeduceInit)) {\n Diag(Init->getBeginLoc(), IsInitCapture ? diag::err_init_capture_paren_braces : diag::err_auto_var_init_paren_braces) << isa<InitListExpr>(Init) << VN << Type << Range;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp"]={"clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:217:10: error: cannot deduce type for variable \'x\' with type \'auto\' from nested initializer list"} | ["clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp"]={"clang/test/SemaCXX/cxx0x-initializer-stdinitializerlist.cpp:217:10: error: cannot deduce type for variable \'x\' with type \'auto\' from nested initializer list"} | ||
Line 5,540: | Line 5,560: | ||
}, | }, | ||
["err_auto_var_requires_init"]={ | ["err_auto_var_requires_init"]={ | ||
[ | [e]="declaration of variable A with deduced type B requires an initializer", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="declaration of variable %0 with deduced type %1 requires an initializer", | ||
[ | [b]=n, | ||
[ | [j]="declaration of variable (.*?) with deduced type (.*?) requires an initializer", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"ae01993a12d6",1247272479,"Implement more of C++0x \'auto\'. A variable with an auto type specifier must have an initializer. Als...","Implement more of C++0x \'auto\'. A variable with an auto type specifier must have an initializer. Also, move some tests around to match the C++0x draft better."}, | ||
[k]={{ | [k]={{s,12696,"QualType Sema::deduceVarTypeFromInitializer(VarDecl *VDecl, DeclarationName Name, QualType Type, TypeSourceInfo *TSI, SourceRange Range, bool DirectInit, Expr *Init) {\n // C++11 [dcl.spec.auto]p3\n if (!Init) {\n // Except for class argument deduction, and then for an initializing\n // declaration only, i.e. no static at class scope or extern.\n if (!isa<DeducedTemplateSpecializationType>(Deduced) || VDecl->hasExternalStorage() || VDecl->isStaticDataMember()) {\n Diag(VDecl->getLocation(), diag::err_auto_var_requires_init) << VDecl->getDeclName() << Type;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/crash-auto-36064.cpp"]={"clang/test/SemaCXX/crash-auto-36064.cpp:5:15: error: declaration of variable \'c\' with deduced type \'auto\' requires an initializer"} | ["clang/test/SemaCXX/crash-auto-36064.cpp"]={"clang/test/SemaCXX/crash-auto-36064.cpp:5:15: error: declaration of variable \'c\' with deduced type \'auto\' requires an initializer"} | ||
Line 5,555: | Line 5,575: | ||
}, | }, | ||
["err_auto_variable_cannot_appear_in_own_initializer"]={ | ["err_auto_variable_cannot_appear_in_own_initializer"]={ | ||
[ | [e]="variable A declared with deduced type B cannot appear in its own initializer", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="variable %0 declared with deduced type %1 cannot appear in its own initializer", | ||
[ | [b]=n, | ||
[ | [j]="variable (.*?) declared with deduced type (.*?) cannot appear in its own initializer", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"364035d1a821",1246043767,"An auto variable can\'t appear in its own initializer.","An auto variable can\'t appear in its own initializer."}, | ||
[k]={{ | [k]={{A,260,"/// Determine whether the use of this declaration is valid, and\n/// emit any corresponding diagnostics.\n///\n/// This routine diagnoses various problems with referencing\n/// declarations that can occur when using a declaration. For example,\n/// it might warn if a deprecated or unavailable declaration is being\n/// used, or produce an error (and return true) if a C++0x deleted\n/// function is being used.\n///\n/// \\returns true if there was an error (this declaration cannot be\n/// referenced), false otherwise.\n///\nbool Sema::DiagnoseUseOfDecl(NamedDecl *D, ArrayRef<SourceLocation> Locs, const ObjCInterfaceDecl *UnknownObjCClass, bool ObjCPropertyAccess, bool AvoidPartialAvailabilityChecks, ObjCInterfaceDecl *ClassReceiver, bool SkipTrailingRequiresClause) {\n // See if this is an auto-typed variable whose initializer we are parsing.\n if (ParsingInitForAutoVars.count(D)) {\n if (isa<BindingDecl>(D)) {\n } else {\n Diag(Loc, diag::err_auto_variable_cannot_appear_in_own_initializer) << D->getDeclName() << cast<VarDecl>(D)->getType();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/auto-type.c"]={"clang/test/Sema/auto-type.c:10:17: error: variable \'e\' declared with deduced type \'__auto_type\' cannot appear in its own initializer"} | ["clang/test/Sema/auto-type.c"]={"clang/test/Sema/auto-type.c:10:17: error: variable \'e\' declared with deduced type \'__auto_type\' cannot appear in its own initializer"} | ||
Line 5,570: | Line 5,590: | ||
}, | }, | ||
["err_avail_query_expected_platform_name"]={ | ["err_avail_query_expected_platform_name"]={ | ||
[e]="expected a platform name here", | |||
[d]=l, | |||
[f]=m, | |||
[h]="expected a platform name here", | [h]="expected a platform name here", | ||
[ | [b]=n, | ||
[ | [j]="expected a platform name here", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={ic,1468629323,jb,jb}, | |||
[ | [k]={{Gb,3773,"/// Parse availability query specification.\n///\n/// availability-spec:\n/// \'*\'\n/// identifier version-tuple\nstd::optional<AvailabilitySpec> Parser::ParseAvailabilitySpec() {\n if (Tok.is(tok::star)) {\n } else {\n if (Tok.isNot(tok::identifier)) {\n Diag(Tok, diag::err_avail_query_expected_platform_name);"}}, | ||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/objc-available.m"]={"clang/test/Parser/objc-available.m:18:20: error: expected a platform name here","clang/test/Parser/objc-available.m:19:32: error: expected a platform name here"} | ["clang/test/Parser/objc-available.m"]={"clang/test/Parser/objc-available.m:18:20: error: expected a platform name here","clang/test/Parser/objc-available.m:19:32: error: expected a platform name here"} | ||
Line 5,585: | Line 5,605: | ||
}, | }, | ||
["err_avail_query_unrecognized_platform_name"]={ | ["err_avail_query_unrecognized_platform_name"]={ | ||
[ | [e]="unrecognized platform name A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="unrecognized platform name %0", | ||
[ | [b]=n, | ||
[ | [j]="unrecognized platform name (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={ic,1468629323,jb,jb}, | ||
[k]={{ | [k]={{Gb,3790,"/// Parse availability query specification.\n///\n/// availability-spec:\n/// \'*\'\n/// identifier version-tuple\nstd::optional<AvailabilitySpec> Parser::ParseAvailabilitySpec() {\n if (Tok.is(tok::star)) {\n } else {\n if (AvailabilityAttr::getPrettyPlatformName(Platform).empty()) {\n Diag(PlatformIdentifier->Loc, diag::err_avail_query_unrecognized_platform_name) << GivenPlatform;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Parser/objc-available.m"]={"clang/test/Parser/objc-available.m:14:20: error: unrecognized platform name erik_os","clang/test/Parser/objc-available.m:16:20: error: unrecognized platform name erik_os","clang/test/Parser/objc-available.m:16:35: error: unrecognized platform name hat_os"} | ["clang/test/Parser/objc-available.m"]={"clang/test/Parser/objc-available.m:14:20: error: unrecognized platform name erik_os","clang/test/Parser/objc-available.m:16:20: error: unrecognized platform name erik_os","clang/test/Parser/objc-available.m:16:35: error: unrecognized platform name hat_os"} | ||
Line 5,600: | Line 5,620: | ||
}, | }, | ||
["err_availability_expected_change"]={ | ["err_availability_expected_change"]={ | ||
[e]="expected \'introduced\', \'deprecated\', or \'obsoleted\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="expected \'introduced\', \'deprecated\', or \'obsoleted\'", | [h]="expected \'introduced\', \'deprecated\', or \'obsoleted\'", | ||
[ | [b]=n, | ||
[ | [j]="expected \'introduced\', \'deprecated\', or \'obsoleted\'", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={"20b2ebd78586",1300841403,wb,wb}, | |||
[k]={{H,1187,"/// Parse the contents of the \"availability\" attribute.\n///\n/// availability-attribute:\n/// \'availability\' \'(\' platform \',\' opt-strict version-arg-list,\n/// opt-replacement, opt-message\')\'\n///\n/// platform:\n/// identifier\n///\n/// opt-strict:\n/// \'strict\' \',\'\n///\n/// version-arg-list:\n/// version-arg\n/// version-arg \',\' version-arg-list\n///\n/// version-arg:\n/// \'introduced\' \'=\' version\n/// \'deprecated\' \'=\' version\n/// \'obsoleted\' = version\n/// \'unavailable\'\n/// opt-replacement:\n/// \'replacement\' \'=\' <string>\n/// opt-message:\n/// \'message\' \'=\' <string>\nvoid Parser::ParseAvailabilityAttribute(IdentifierInfo &Availability, SourceLocation AvailabilityLoc, ParsedAttributes &attrs, SourceLocation *endLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n do {\n if (Tok.isNot(tok::identifier)) {\n Diag(Tok, diag::err_availability_expected_change);"}} | |||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_availability_expected_platform"]={ | ["err_availability_expected_platform"]={ | ||
[e]="expected a platform name, e.g., \'macos\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="expected a platform name, e.g., \'macos\'", | [h]="expected a platform name, e.g., \'macos\'", | ||
[ | [b]=n, | ||
[ | [j]="expected a platform name, e\\.g\\., \'macos\'", | ||
[c]=a, | |||
[i]=D, | |||
[g]={"20b2ebd78586",1300841403,wb,wb}, | |||
[ | [k]={{H,1146,"/// Parse the contents of the \"availability\" attribute.\n///\n/// availability-attribute:\n/// \'availability\' \'(\' platform \',\' opt-strict version-arg-list,\n/// opt-replacement, opt-message\')\'\n///\n/// platform:\n/// identifier\n///\n/// opt-strict:\n/// \'strict\' \',\'\n///\n/// version-arg-list:\n/// version-arg\n/// version-arg \',\' version-arg-list\n///\n/// version-arg:\n/// \'introduced\' \'=\' version\n/// \'deprecated\' \'=\' version\n/// \'obsoleted\' = version\n/// \'unavailable\'\n/// opt-replacement:\n/// \'replacement\' \'=\' <string>\n/// opt-message:\n/// \'message\' \'=\' <string>\nvoid Parser::ParseAvailabilityAttribute(IdentifierInfo &Availability, SourceLocation AvailabilityLoc, ParsedAttributes &attrs, SourceLocation *endLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n // Parse the platform name.\n if (Tok.isNot(tok::identifier)) {\n Diag(Tok, diag::err_availability_expected_platform);"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_availability_query_repeated_platform"]={ | ["err_availability_query_repeated_platform"]={ | ||
[ | [e]="version for \'A\' already specified", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="version for \'%0\' already specified", | ||
[ | [b]=n, | ||
[ | [j]="version for \'(.*?)\' already specified", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={ic,1468629323,jb,jb}, | ||
[k]={{ | [k]={{Gb,3741,"/// Validate availability spec list, emitting diagnostics if necessary. Returns\n/// true if invalid.\nstatic bool CheckAvailabilitySpecList(Parser &P, ArrayRef<AvailabilitySpec> AvailSpecs) {\n for (const auto &Spec : AvailSpecs) {\n if (!Inserted) {\n P.Diag(Spec.getBeginLoc(), diag::err_availability_query_repeated_platform) << Spec.getEndLoc() << Platform;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Parser/objc-available.m"]={"clang/test/Parser/objc-available.m:12:33: error: version for \'macos\' already specified"} | ["clang/test/Parser/objc-available.m"]={"clang/test/Parser/objc-available.m:12:33: error: version for \'macos\' already specified"} | ||
Line 5,639: | Line 5,659: | ||
}, | }, | ||
["err_availability_query_repeated_star"]={ | ["err_availability_query_repeated_star"]={ | ||
[e]="\'*\' query has already been specified", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'*\' query has already been specified", | [h]="\'*\' query has already been specified", | ||
[ | [b]=n, | ||
[ | [j]="\'\\*\' query has already been specified", | ||
[c]=a, | |||
[i]=D, | |||
[g]={ic,1468629323,jb,jb}, | |||
[ | [k]={{Gb,3727,"/// Validate availability spec list, emitting diagnostics if necessary. Returns\n/// true if invalid.\nstatic bool CheckAvailabilitySpecList(Parser &P, ArrayRef<AvailabilitySpec> AvailSpecs) {\n for (const auto &Spec : AvailSpecs) {\n if (Spec.isOtherPlatformSpec()) {\n if (HasOtherPlatformSpec) {\n P.Diag(Spec.getBeginLoc(), diag::err_availability_query_repeated_star);"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_availability_query_wildcard_required"]={ | ["err_availability_query_wildcard_required"]={ | ||
[e]="must handle potential future platforms with \'*\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="must handle potential future platforms with \'*\'", | [h]="must handle potential future platforms with \'*\'", | ||
[ | [b]=n, | ||
[ | [j]="must handle potential future platforms with \'\\*\'", | ||
[c]=a, | |||
[i]=D, | |||
[g]={ic,1468629323,jb,jb}, | |||
[ | [k]={{Gb,3749,"/// Validate availability spec list, emitting diagnostics if necessary. Returns\n/// true if invalid.\nstatic bool CheckAvailabilitySpecList(Parser &P, ArrayRef<AvailabilitySpec> AvailSpecs) {\n if (!HasOtherPlatformSpec) {\n P.Diag(InsertWildcardLoc, diag::err_availability_query_wildcard_required) << FixItHint::CreateInsertion(InsertWildcardLoc, \", *\");"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/objc-available.m"]={"clang/test/Parser/objc-available.m:11:31: error: must handle potential future platforms with \'*\'"} | ["clang/test/Parser/objc-available.m"]={"clang/test/Parser/objc-available.m:11:31: error: must handle potential future platforms with \'*\'"} | ||
Line 5,666: | Line 5,686: | ||
}, | }, | ||
["err_availability_redundant"]={ | ["err_availability_redundant"]={ | ||
[ | [e]="redundant A availability change; only the last specified change will be used", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="redundant %0 availability change; only the last specified change will be used", | ||
[ | [b]=n, | ||
[ | [j]="redundant (.*?) availability change; only the last specified change will be used", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"20b2ebd78586",1300841403,wb,wb}, | ||
[k]={{ | [k]={{H,1196,"/// Parse the contents of the \"availability\" attribute.\n///\n/// availability-attribute:\n/// \'availability\' \'(\' platform \',\' opt-strict version-arg-list,\n/// opt-replacement, opt-message\')\'\n///\n/// platform:\n/// identifier\n///\n/// opt-strict:\n/// \'strict\' \',\'\n///\n/// version-arg-list:\n/// version-arg\n/// version-arg \',\' version-arg-list\n///\n/// version-arg:\n/// \'introduced\' \'=\' version\n/// \'deprecated\' \'=\' version\n/// \'obsoleted\' = version\n/// \'unavailable\'\n/// opt-replacement:\n/// \'replacement\' \'=\' <string>\n/// opt-message:\n/// \'message\' \'=\' <string>\nvoid Parser::ParseAvailabilityAttribute(IdentifierInfo &Availability, SourceLocation AvailabilityLoc, ParsedAttributes &attrs, SourceLocation *endLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n do {\n if (Keyword == Ident_strict) {\n if (StrictLoc.isValid()) {\n Diag(KeywordLoc, diag::err_availability_redundant) << Keyword << SourceRange(StrictLoc);"},{H,1205,"/// Parse the contents of the \"availability\" attribute.\n///\n/// availability-attribute:\n/// \'availability\' \'(\' platform \',\' opt-strict version-arg-list,\n/// opt-replacement, opt-message\')\'\n///\n/// platform:\n/// identifier\n///\n/// opt-strict:\n/// \'strict\' \',\'\n///\n/// version-arg-list:\n/// version-arg\n/// version-arg \',\' version-arg-list\n///\n/// version-arg:\n/// \'introduced\' \'=\' version\n/// \'deprecated\' \'=\' version\n/// \'obsoleted\' = version\n/// \'unavailable\'\n/// opt-replacement:\n/// \'replacement\' \'=\' <string>\n/// opt-message:\n/// \'message\' \'=\' <string>\nvoid Parser::ParseAvailabilityAttribute(IdentifierInfo &Availability, SourceLocation AvailabilityLoc, ParsedAttributes &attrs, SourceLocation *endLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n do {\n if (Keyword == Ident_unavailable) {\n if (UnavailableLoc.isValid()) {\n Diag(KeywordLoc, diag::err_availability_redundant) << Keyword << SourceRange(UnavailableLoc);"},{H,1216,"/// Parse the contents of the \"availability\" attribute.\n///\n/// availability-attribute:\n/// \'availability\' \'(\' platform \',\' opt-strict version-arg-list,\n/// opt-replacement, opt-message\')\'\n///\n/// platform:\n/// identifier\n///\n/// opt-strict:\n/// \'strict\' \',\'\n///\n/// version-arg-list:\n/// version-arg\n/// version-arg \',\' version-arg-list\n///\n/// version-arg:\n/// \'introduced\' \'=\' version\n/// \'deprecated\' \'=\' version\n/// \'obsoleted\' = version\n/// \'unavailable\'\n/// opt-replacement:\n/// \'replacement\' \'=\' <string>\n/// opt-message:\n/// \'message\' \'=\' <string>\nvoid Parser::ParseAvailabilityAttribute(IdentifierInfo &Availability, SourceLocation AvailabilityLoc, ParsedAttributes &attrs, SourceLocation *endLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n do {\n if (Keyword == Ident_deprecated && Platform->Ident && Platform->Ident->isStr(\"swift\")) {\n // For swift, we deprecate for all versions.\n if (Changes[Deprecated].KeywordLoc.isValid()) {\n Diag(KeywordLoc, diag::err_availability_redundant) << Keyword << SourceRange(Changes[Deprecated].KeywordLoc);"},{H,1294,"/// Parse the contents of the \"availability\" attribute.\n///\n/// availability-attribute:\n/// \'availability\' \'(\' platform \',\' opt-strict version-arg-list,\n/// opt-replacement, opt-message\')\'\n///\n/// platform:\n/// identifier\n///\n/// opt-strict:\n/// \'strict\' \',\'\n///\n/// version-arg-list:\n/// version-arg\n/// version-arg \',\' version-arg-list\n///\n/// version-arg:\n/// \'introduced\' \'=\' version\n/// \'deprecated\' \'=\' version\n/// \'obsoleted\' = version\n/// \'unavailable\'\n/// opt-replacement:\n/// \'replacement\' \'=\' <string>\n/// opt-message:\n/// \'message\' \'=\' <string>\nvoid Parser::ParseAvailabilityAttribute(IdentifierInfo &Availability, SourceLocation AvailabilityLoc, ParsedAttributes &attrs, SourceLocation *endLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n do {\n if (Index < Unknown) {\n if (!Changes[Index].KeywordLoc.isInvalid()) {\n Diag(KeywordLoc, diag::err_availability_redundant) << Keyword << SourceRange(Changes[Index].KeywordLoc, Changes[Index].VersionRange.getEnd());"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Parser/attr-availability.c"]={"clang/test/Parser/attr-availability.c:13:94: error: redundant \'introduced\' availability change; only the last specified change will be used","clang/test/Parser/attr-availability.c:17:98: error: redundant \'unavailable\' availability change; only the last specified change will be used"} | ["clang/test/Parser/attr-availability.c"]={"clang/test/Parser/attr-availability.c:13:94: error: redundant \'introduced\' availability change; only the last specified change will be used","clang/test/Parser/attr-availability.c:17:98: error: redundant \'unavailable\' availability change; only the last specified change will be used"} | ||
Line 5,681: | Line 5,701: | ||
}, | }, | ||
["err_availability_unknown_change"]={ | ["err_availability_unknown_change"]={ | ||
[ | [e]="A is not an availability stage; use \'introduced\', \'deprecated\', or \'obsoleted\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 is not an availability stage; use \'introduced\', \'deprecated\', or \'obsoleted\'", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) is not an availability stage; use \'introduced\', \'deprecated\', or \'obsoleted\'", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"20b2ebd78586",1300841403,wb,wb}, | ||
[k]={{ | [k]={{H,1304,"/// Parse the contents of the \"availability\" attribute.\n///\n/// availability-attribute:\n/// \'availability\' \'(\' platform \',\' opt-strict version-arg-list,\n/// opt-replacement, opt-message\')\'\n///\n/// platform:\n/// identifier\n///\n/// opt-strict:\n/// \'strict\' \',\'\n///\n/// version-arg-list:\n/// version-arg\n/// version-arg \',\' version-arg-list\n///\n/// version-arg:\n/// \'introduced\' \'=\' version\n/// \'deprecated\' \'=\' version\n/// \'obsoleted\' = version\n/// \'unavailable\'\n/// opt-replacement:\n/// \'replacement\' \'=\' <string>\n/// opt-message:\n/// \'message\' \'=\' <string>\nvoid Parser::ParseAvailabilityAttribute(IdentifierInfo &Availability, SourceLocation AvailabilityLoc, ParsedAttributes &attrs, SourceLocation *endLoc, IdentifierInfo *ScopeName, SourceLocation ScopeLoc, ParsedAttr::Form Form) {\n do {\n if (Index < Unknown) {\n } else {\n Diag(KeywordLoc, diag::err_availability_unknown_change) << Keyword << VersionRange;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/attr-availability-square-brackets.c"]={"clang/test/Sema/attr-availability-square-brackets.c:25:35: error: \'should\' is not an availability stage; use \'introduced\', \'deprecated\', or \'obsoleted\'"} | ["clang/test/Sema/attr-availability-square-brackets.c"]={"clang/test/Sema/attr-availability-square-brackets.c:25:35: error: \'should\' is not an availability stage; use \'introduced\', \'deprecated\', or \'obsoleted\'"} | ||
Line 5,696: | Line 5,716: | ||
}, | }, | ||
["err_avx_calling_convention"]={ | ["err_avx_calling_convention"]={ | ||
[ | [e]="AVX vector ... of type A without \'B\' enabled changes the ABI", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="AVX vector %select{return|argument}0 of type %1 without \'%2\' enabled changes the ABI", | ||
[ | [b]=n, | ||
[ | [j]="AVX vector (?:return|argument) of type (.*?) without \'(.*?)\' enabled changes the ABI", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"2831a317b689",1592939649,"Implement AVX ABI Warning/error","Implement AVX ABI Warning/error"}, | ||
[k]={{"clang/lib/CodeGen/Targets/X86.cpp",1504,"static bool checkAVXParamFeature(DiagnosticsEngine &Diag, SourceLocation CallLoc, const llvm::StringMap<bool> &CallerMap, const llvm::StringMap<bool> &CalleeMap, QualType Ty, StringRef Feature, bool IsArgument) {\n // Mixing calling conventions here is very clearly an error.\n if (!CallerHasFeat || !CalleeHasFeat)\n return Diag.Report(CallLoc, diag::err_avx_calling_convention) << IsArgument << Ty << Feature;"}}, | [k]={{"clang/lib/CodeGen/Targets/X86.cpp",1504,"static bool checkAVXParamFeature(DiagnosticsEngine &Diag, SourceLocation CallLoc, const llvm::StringMap<bool> &CallerMap, const llvm::StringMap<bool> &CalleeMap, QualType Ty, StringRef Feature, bool IsArgument) {\n // Mixing calling conventions here is very clearly an error.\n if (!CallerHasFeat || !CalleeHasFeat)\n return Diag.Report(CallLoc, diag::err_avx_calling_convention) << IsArgument << Ty << Feature;"}}, | ||
[o]={ | [o]={ | ||
Line 5,711: | Line 5,731: | ||
}, | }, | ||
["err_await_suspend_invalid_return_type"]={ | ["err_await_suspend_invalid_return_type"]={ | ||
[ | [e]="return type of \'await_suspend\' is required to be \'void\' or \'bool\' (have A)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="return type of \'await_suspend\' is required to be \'void\' or \'bool\' (have %0)", | ||
[ | [b]=n, | ||
[ | [j]="return type of \'await_suspend\' is required to be \'void\' or \'bool\' \\(have (.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]="Coroutines Issue", | ||
[ | [g]={"d978e53c6d70",1495995672,"[coroutines] Diagnose invalid result types for `await_resume` and `await_suspend` and add missing c...","[coroutines] Diagnose invalid result types for `await_resume` and `await_suspend` and add missing conversions."}, | ||
[k]={{"clang/lib/Sema/SemaCoroutine.cpp",448,"/// Build calls to await_ready, await_suspend, and await_resume for a co_await\n/// expression.\n/// The generated AST tries to clean up temporary objects as early as\n/// possible so that they don\'t live across suspension points if possible.\n/// Having temporary objects living across suspension points unnecessarily can\n/// lead to large frame size, and also lead to memory corruptions if the\n/// coroutine frame is destroyed after coming back from suspension. This is done\n/// by wrapping both the await_ready call and the await_suspend call with\n/// ExprWithCleanups. In the end of this function, we also need to explicitly\n/// set cleanup state so that the CoawaitExpr is also wrapped with an\n/// ExprWithCleanups to clean up the awaiter associated with the co_await\n/// expression.\nstatic ReadySuspendResumeResult buildCoawaitCalls(Sema &S, VarDecl *CoroPromise, SourceLocation Loc, Expr *E) {\n if (!AwaitSuspend->getType()->isDependentType()) {\n // Support for coroutine_handle returning await_suspend.\n if (Expr *TailCallSuspend = maybeTailCall(S, RetType, AwaitSuspend, Loc))\n else {\n // non-class prvalues always have cv-unqualified types\n if (RetType->isReferenceType() || (!RetType->isBooleanType() && !RetType->isVoidType())) {\n S.Diag(AwaitSuspend->getCalleeDecl()->getLocation(), diag::err_await_suspend_invalid_return_type) << RetType;"}}, | [k]={{"clang/lib/Sema/SemaCoroutine.cpp",448,"/// Build calls to await_ready, await_suspend, and await_resume for a co_await\n/// expression.\n/// The generated AST tries to clean up temporary objects as early as\n/// possible so that they don\'t live across suspension points if possible.\n/// Having temporary objects living across suspension points unnecessarily can\n/// lead to large frame size, and also lead to memory corruptions if the\n/// coroutine frame is destroyed after coming back from suspension. This is done\n/// by wrapping both the await_ready call and the await_suspend call with\n/// ExprWithCleanups. In the end of this function, we also need to explicitly\n/// set cleanup state so that the CoawaitExpr is also wrapped with an\n/// ExprWithCleanups to clean up the awaiter associated with the co_await\n/// expression.\nstatic ReadySuspendResumeResult buildCoawaitCalls(Sema &S, VarDecl *CoroPromise, SourceLocation Loc, Expr *E) {\n if (!AwaitSuspend->getType()->isDependentType()) {\n // Support for coroutine_handle returning await_suspend.\n if (Expr *TailCallSuspend = maybeTailCall(S, RetType, AwaitSuspend, Loc))\n else {\n // non-class prvalues always have cv-unqualified types\n if (RetType->isReferenceType() || (!RetType->isBooleanType() && !RetType->isVoidType())) {\n S.Diag(AwaitSuspend->getCalleeDecl()->getLocation(), diag::err_await_suspend_invalid_return_type) << RetType;"}}, | ||
[o]={ | [o]={ | ||
Line 5,726: | Line 5,746: | ||
}, | }, | ||
["err_bad_cast_incomplete"]={ | ["err_bad_cast_incomplete"]={ | ||
[ | [e]="A is an incomplete type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 is an incomplete type", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) is an incomplete type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"fe17b30a7957",1575504770,"[attributes][analyzer] Add annotations for handles.","[attributes][analyzer] Add annotations for handles."}, | ||
[k]={{x,816,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointee->isVoidType()) {\n } else if (DestRecord) {\n if (Self.RequireCompleteType(OpRange.getBegin(), DestPointee, diag::err_bad_cast_incomplete, DestRange)) {"},{x,861,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (SrcRecord) {\n if (Self.RequireCompleteType(OpRange.getBegin(), SrcPointee, diag::err_bad_cast_incomplete, SrcExpr.get())) {"},{x,1400,"/// TryStaticCast - Check if a static cast can be performed, and do so if\n/// possible. If @p CStyle, ignore access restrictions on hierarchy casting\n/// and casting away constness.\nstatic TryCastResult TryStaticCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, Sema::CheckedConversionKind CCK, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath, bool ListInitialization) {\n // Reverse integral promotion/conversion. All such conversions are themselves\n // again integral promotions or conversions and are thus already handled by\n // p2 (TryDirectInitialization above).\n // (Note: any data loss warnings should be suppressed.)\n // The exception is the reverse of enum->integer, i.e. integer->enum (and\n // enum->enum). See also C++ 5.2.9p7.\n // The same goes for reverse floating point promotion/conversion and\n // floating-integral conversions. Again, only floating->enum is relevant.\n if (DestType->isEnumeralType()) {\n if (Self.RequireCompleteType(OpRange.getBegin(), DestType, diag::err_bad_cast_incomplete)) {"},{x,1883,"/// 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)) {"}}, | [k]={{x,816,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointee->isVoidType()) {\n } else if (DestRecord) {\n if (Self.RequireCompleteType(OpRange.getBegin(), DestPointee, diag::err_bad_cast_incomplete, DestRange)) {"},{x,861,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (SrcRecord) {\n if (Self.RequireCompleteType(OpRange.getBegin(), SrcPointee, diag::err_bad_cast_incomplete, SrcExpr.get())) {"},{x,1400,"/// TryStaticCast - Check if a static cast can be performed, and do so if\n/// possible. If @p CStyle, ignore access restrictions on hierarchy casting\n/// and casting away constness.\nstatic TryCastResult TryStaticCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, Sema::CheckedConversionKind CCK, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath, bool ListInitialization) {\n // Reverse integral promotion/conversion. All such conversions are themselves\n // again integral promotions or conversions and are thus already handled by\n // p2 (TryDirectInitialization above).\n // (Note: any data loss warnings should be suppressed.)\n // The exception is the reverse of enum->integer, i.e. integer->enum (and\n // enum->enum). See also C++ 5.2.9p7.\n // The same goes for reverse floating point promotion/conversion and\n // floating-integral conversions. Again, only floating->enum is relevant.\n if (DestType->isEnumeralType()) {\n if (Self.RequireCompleteType(OpRange.getBegin(), DestType, diag::err_bad_cast_incomplete)) {"},{x,1883,"/// 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)) {"}}, | ||
[o]={ | [o]={ | ||
[ | [Ab]={"clang/test/SemaCXX/dynamic-cast.cpp:37:9: error: \'Incomplete\' is an incomplete type","clang/test/SemaCXX/dynamic-cast.cpp:39:9: error: \'Incomplete\' is an incomplete type"} | ||
} | } | ||
}, | }, | ||
["err_bad_category_property_decl"]={ | ["err_bad_category_property_decl"]={ | ||
[ | [e]="property implementation must have its declaration in the category A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="property implementation must have its declaration in the category %0", | ||
[ | [b]=n, | ||
[ | [j]="property implementation must have its declaration in the category (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Xb,1480718311,gb,gb}, | ||
[k]={{ | [k]={{Y,1194,"/// 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 if ((IC = dyn_cast<ObjCImplementationDecl>(ClassImpDecl))) {\n } else if ((CatImplClass = dyn_cast<ObjCCategoryImplDecl>(ClassImpDecl))) {\n if (!property) {\n Diag(PropertyLoc, diag::err_bad_category_property_decl) << Category->getDeclName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/property.m"]={"clang/test/SemaObjC/property.m:27:10: error: property implementation must have its declaration in the category \'CAT\'"} | ["clang/test/SemaObjC/property.m"]={"clang/test/SemaObjC/property.m:27:10: error: property implementation must have its declaration in the category \'CAT\'"} | ||
Line 5,756: | Line 5,776: | ||
}, | }, | ||
["err_bad_character_encoding"]={ | ["err_bad_character_encoding"]={ | ||
[e]="illegal character encoding in character literal", | |||
[d]=l, | |||
[f]=m, | |||
[h]="illegal character encoding in character literal", | [h]="illegal character encoding in character literal", | ||
[ | [b]=n, | ||
[ | [j]="illegal character encoding in character literal", | ||
[c]=a, | |||
[ | [i]=rb, | ||
[g]={"8b2b677f390d",1326889624,"Improves support for Unicode in character literals","Improves support for Unicode in character literals"}, | |||
[ | |||
[ | |||
[k]={{"clang/lib/Lex/LiteralSupport.cpp",1745,"/// \\verbatim\n/// user-defined-character-literal: [C++11 lex.ext]\n/// character-literal ud-suffix\n/// ud-suffix:\n/// identifier\n/// character-literal: [C++11 lex.ccon]\n/// \' c-char-sequence \'\n/// u\' c-char-sequence \'\n/// U\' c-char-sequence \'\n/// L\' c-char-sequence \'\n/// u8\' c-char-sequence \' [C++1z lex.ccon]\n/// c-char-sequence:\n/// c-char\n/// c-char-sequence c-char\n/// c-char:\n/// any member of the source character set except the single-quote \',\n/// backslash \\, or new-line character\n/// escape-sequence\n/// universal-character-name\n/// escape-sequence:\n/// simple-escape-sequence\n/// octal-escape-sequence\n/// hexadecimal-escape-sequence\n/// simple-escape-sequence:\n/// one of \\\' \\\" \\? \\\\ \\a \\b \\f \\n \\r \\t \\v\n/// octal-escape-sequence:\n/// \\ octal-digit\n/// \\ octal-digit octal-digit\n/// \\ octal-digit octal-digit octal-digit\n/// hexadecimal-escape-sequence:\n/// \\x hexadecimal-digit\n/// hexadecimal-escape-sequence hexadecimal-digit\n/// universal-character-name: [C++11 lex.charset]\n/// \\u hex-quad\n/// \\U hex-quad hex-quad\n/// hex-quad:\n/// hex-digit hex-digit hex-digit hex-digit\n/// \\endverbatim\n///\nCharLiteralParser::CharLiteralParser(const char *begin, const char *end, SourceLocation Loc, Preprocessor &PP, tok::TokenKind kind) {\n while (begin != end) {\n // Is this a span of non-escape characters?\n if (begin[0] != \'\\\\\') {\n if (res != llvm::conversionOK) {\n unsigned Msg = diag::err_bad_character_encoding;"}}, | [k]={{"clang/lib/Lex/LiteralSupport.cpp",1745,"/// \\verbatim\n/// user-defined-character-literal: [C++11 lex.ext]\n/// character-literal ud-suffix\n/// ud-suffix:\n/// identifier\n/// character-literal: [C++11 lex.ccon]\n/// \' c-char-sequence \'\n/// u\' c-char-sequence \'\n/// U\' c-char-sequence \'\n/// L\' c-char-sequence \'\n/// u8\' c-char-sequence \' [C++1z lex.ccon]\n/// c-char-sequence:\n/// c-char\n/// c-char-sequence c-char\n/// c-char:\n/// any member of the source character set except the single-quote \',\n/// backslash \\, or new-line character\n/// escape-sequence\n/// universal-character-name\n/// escape-sequence:\n/// simple-escape-sequence\n/// octal-escape-sequence\n/// hexadecimal-escape-sequence\n/// simple-escape-sequence:\n/// one of \\\' \\\" \\? \\\\ \\a \\b \\f \\n \\r \\t \\v\n/// octal-escape-sequence:\n/// \\ octal-digit\n/// \\ octal-digit octal-digit\n/// \\ octal-digit octal-digit octal-digit\n/// hexadecimal-escape-sequence:\n/// \\x hexadecimal-digit\n/// hexadecimal-escape-sequence hexadecimal-digit\n/// universal-character-name: [C++11 lex.charset]\n/// \\u hex-quad\n/// \\U hex-quad hex-quad\n/// hex-quad:\n/// hex-digit hex-digit hex-digit hex-digit\n/// \\endverbatim\n///\nCharLiteralParser::CharLiteralParser(const char *begin, const char *end, SourceLocation Loc, Preprocessor &PP, tok::TokenKind kind) {\n while (begin != end) {\n // Is this a span of non-escape characters?\n if (begin[0] != \'\\\\\') {\n if (res != llvm::conversionOK) {\n unsigned Msg = diag::err_bad_character_encoding;"}}, | ||
[o]={ | [o]={ | ||
Line 5,771: | Line 5,791: | ||
}, | }, | ||
["err_bad_const_cast_dest"]={ | ["err_bad_const_cast_dest"]={ | ||
[ | [e]="... to A, which is not a reference, pointer-to-object, or pointer-to-data-member", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{const_cast||||C-style cast|functional-style cast|}0 to %2, which is not a reference, pointer-to-object, or pointer-to-data-member", | ||
[ | [b]=n, | ||
[ | [j]="(?:const_cast||||C\\-style cast|functional\\-style cast|) to (.*?), which is not a reference, pointer\\-to\\-object, or pointer\\-to\\-data\\-member", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,1998,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (!DestType->isPointerType() && !DestType->isMemberPointerType() && !DestType->isObjCObjectPointerType()) {\n // Cannot cast to non-pointer, non-reference type. Note that, if DestType\n // was a reference type, we converted it to a pointer above.\n // The status of rvalue references isn\'t entirely clear, but it looks like\n // conversion to them is simply invalid.\n // C++ 5.2.11p3: For two pointer types [...]\n if (!CStyle)\n msg = diag::err_bad_const_cast_dest;"},{x,2007,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (DestType->isFunctionPointerType() || DestType->isMemberFunctionPointerType()) {\n // Cannot cast direct function pointers.\n // C++ 5.2.11p2: [...] where T is any object type or the void type [...]\n // T is the ultimate pointee of source and target type.\n if (!CStyle)\n msg = diag::err_bad_const_cast_dest;"}}, | [k]={{x,1998,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (!DestType->isPointerType() && !DestType->isMemberPointerType() && !DestType->isObjCObjectPointerType()) {\n // Cannot cast to non-pointer, non-reference type. Note that, if DestType\n // was a reference type, we converted it to a pointer above.\n // The status of rvalue references isn\'t entirely clear, but it looks like\n // conversion to them is simply invalid.\n // C++ 5.2.11p3: For two pointer types [...]\n if (!CStyle)\n msg = diag::err_bad_const_cast_dest;"},{x,2007,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (DestType->isFunctionPointerType() || DestType->isMemberFunctionPointerType()) {\n // Cannot cast direct function pointers.\n // C++ 5.2.11p2: [...] where T is any object type or the void type [...]\n // T is the ultimate pointee of source and target type.\n if (!CStyle)\n msg = diag::err_bad_const_cast_dest;"}}, | ||
[o]={ | [o]={ | ||
Line 5,786: | Line 5,806: | ||
}, | }, | ||
["err_bad_cstyle_cast_overload"]={ | ["err_bad_cstyle_cast_overload"]={ | ||
[ | [e]="address of overloaded function A cannot be cast to type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address of overloaded function %0 cannot be cast to type %1", | ||
[ | [b]=n, | ||
[ | [j]="address of overloaded function (.*?) cannot be cast to type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"b491ed36b4ef",1298151169,"Handle the resolution of a reference to a function template (which","Handle the resolution of a reference to a function template (which"}, | ||
[k]={{x,2738,"void CastOperation::CheckCXXCStyleCast(bool FunctionalStyle, bool ListInitialization) {\n // C++ 5.2.9p4: Any expression can be explicitly converted to type \"cv void\".\n // This test is outside everything else because it\'s the only case where\n // a non-lvalue-reference target type does not lead to decay.\n if (DestType->isVoidType()) {\n if (claimPlaceholder(BuiltinType::Overload)) {\n Self.ResolveAndFixSingleFunctionTemplateSpecialization(SrcExpr, /* Decay Function to ptr */ false,\n /* Complain */ true, DestRange, DestType, diag::err_bad_cstyle_cast_overload);"},{x,2848,"void CastOperation::CheckCXXCStyleCast(bool FunctionalStyle, bool ListInitialization) {\n if (tcr != TC_Success && msg != 0) {\n if (SrcExpr.get()->getType() == Self.Context.OverloadTy) {\n if (Fn) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_cstyle_cast_overload) << OE->getName() << DestType << OpRange << OE->getQualifierLoc().getSourceRange();"}}, | [k]={{x,2738,"void CastOperation::CheckCXXCStyleCast(bool FunctionalStyle, bool ListInitialization) {\n // C++ 5.2.9p4: Any expression can be explicitly converted to type \"cv void\".\n // This test is outside everything else because it\'s the only case where\n // a non-lvalue-reference target type does not lead to decay.\n if (DestType->isVoidType()) {\n if (claimPlaceholder(BuiltinType::Overload)) {\n Self.ResolveAndFixSingleFunctionTemplateSpecialization(SrcExpr, /* Decay Function to ptr */ false,\n /* Complain */ true, DestRange, DestType, diag::err_bad_cstyle_cast_overload);"},{x,2848,"void CastOperation::CheckCXXCStyleCast(bool FunctionalStyle, bool ListInitialization) {\n if (tcr != TC_Success && msg != 0) {\n if (SrcExpr.get()->getType() == Self.Context.OverloadTy) {\n if (Fn) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_cstyle_cast_overload) << OE->getName() << DestType << OpRange << OE->getQualifierLoc().getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 5,801: | Line 5,821: | ||
}, | }, | ||
["err_bad_cxx_cast_addr_space_mismatch"]={ | ["err_bad_cxx_cast_addr_space_mismatch"]={ | ||
[ | [e]="... from A to B converts between mismatching address spaces", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{const_cast|static_cast|reinterpret_cast|dynamic_cast|C-style cast|functional-style cast|addrspace_cast}0 from %1 to %2 converts between mismatching address spaces", | ||
[ | [b]=n, | ||
[ | [j]="(?:const_cast|static_cast|reinterpret_cast|dynamic_cast|C\\-style cast|functional\\-style cast|addrspace_cast) from (.*?) to (.*?) converts between mismatching address spaces", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"6f7c536e083b",1551978390,"[Sema] Change addr space diagnostics in casts to follow C++ style.","[Sema] Change addr space diagnostics in casts to follow C++ style."}, | ||
[k]={{x,2622,"static TryCastResult TryAddressSpaceCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg, CastKind &Kind) {\n if (!DestPointeeType.isAddressSpaceOverlapping(SrcPointeeType)) {\n msg = diag::err_bad_cxx_cast_addr_space_mismatch;"}}, | [k]={{x,2622,"static TryCastResult TryAddressSpaceCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg, CastKind &Kind) {\n if (!DestPointeeType.isAddressSpaceOverlapping(SrcPointeeType)) {\n msg = diag::err_bad_cxx_cast_addr_space_mismatch;"}}, | ||
[o]={ | [o]={ | ||
Line 5,816: | Line 5,836: | ||
}, | }, | ||
["err_bad_cxx_cast_bitfield"]={ | ["err_bad_cxx_cast_bitfield"]={ | ||
[ | [e]="... from bit-field lvalue to reference type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{const_cast|static_cast|reinterpret_cast|dynamic_cast|C-style cast|functional-style cast|}0 from bit-field lvalue to reference type %2", | ||
[ | [b]=n, | ||
[ | [j]="(?:const_cast|static_cast|reinterpret_cast|dynamic_cast|C\\-style cast|functional\\-style cast|) from bit\\-field lvalue to reference type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"d25db7ed0f8e",1367876352,"Grab-bag of bit-field fixes:","Grab-bag of bit-field fixes:"}, | ||
[k]={{x,1978,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n // It\'s not completely clear under the standard whether we can\n // const_cast bit-field gl-values. Doing so would not be\n // intrinsically complicated, but for now, we say no for\n // consistency with other compilers and await the word of the\n // committee.\n if (SrcExpr.get()->refersToBitField()) {\n msg = diag::err_bad_cxx_cast_bitfield;"},{x,2290,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n case OK_BitField:\n msg = diag::err_bad_cxx_cast_bitfield;"}}, | [k]={{x,1978,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n // It\'s not completely clear under the standard whether we can\n // const_cast bit-field gl-values. Doing so would not be\n // intrinsically complicated, but for now, we say no for\n // consistency with other compilers and await the word of the\n // committee.\n if (SrcExpr.get()->refersToBitField()) {\n msg = diag::err_bad_cxx_cast_bitfield;"},{x,2290,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n case OK_BitField:\n msg = diag::err_bad_cxx_cast_bitfield;"}}, | ||
[o]={ | [o]={ | ||
Line 5,831: | Line 5,851: | ||
}, | }, | ||
["err_bad_cxx_cast_generic"]={ | ["err_bad_cxx_cast_generic"]={ | ||
[ | [e]="... from A to B is not allowed", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{const_cast|static_cast|reinterpret_cast|dynamic_cast|C-style cast|functional-style cast|addrspace_cast}0 from %1 to %2 is not allowed", | ||
[ | [b]=n, | ||
[ | [j]="(?:const_cast|static_cast|reinterpret_cast|dynamic_cast|C\\-style cast|functional\\-style cast|addrspace_cast) from (.*?) to (.*?) is not allowed", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,521,"/// Diagnose a failed cast.\nstatic void diagnoseBadCast(Sema &S, unsigned msg, CastType castType, SourceRange opRange, Expr *src, QualType destType, bool listInitialization) {\n if (msg == diag::err_bad_cxx_cast_generic && tryDiagnoseOverloadedCast(S, castType, opRange, src, destType, listInitialization))"},{x,966,"/// CheckConstCast - Check that a const_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.11 for details. const_cast is typically used in code\n/// like this:\n/// const char *str = \"literal\";\n/// legacy_function(const_cast\\<char*\\>(str));\nvoid CastOperation::CheckConstCast() {\n unsigned msg = diag::err_bad_cxx_cast_generic;"},{x,977,"void CastOperation::CheckAddrspaceCast() {\n unsigned msg = diag::err_bad_cxx_cast_generic;"},{x,1193,"/// CheckReinterpretCast - Check that a reinterpret_cast\\<DestType\\>(SrcExpr) is\n/// valid.\n/// Refer to C++ 5.2.10 for details. reinterpret_cast is typically used in code\n/// like this:\n/// char *bytes = reinterpret_cast\\<char*\\>(int_ptr);\nvoid CastOperation::CheckReinterpretCast() {\n unsigned msg = diag::err_bad_cxx_cast_generic;"},{x,1265,"/// CheckStaticCast - Check that a static_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.9 for details. Static casts are mostly used for making\n/// implicit conversions explicit and getting rid of data loss warnings.\nvoid CastOperation::CheckStaticCast() {\n unsigned msg = diag::err_bad_cxx_cast_generic;"},{x,2798,"void CastOperation::CheckCXXCStyleCast(bool FunctionalStyle, bool ListInitialization) {\n unsigned msg = diag::err_bad_cxx_cast_generic;"}}, | [k]={{x,521,"/// Diagnose a failed cast.\nstatic void diagnoseBadCast(Sema &S, unsigned msg, CastType castType, SourceRange opRange, Expr *src, QualType destType, bool listInitialization) {\n if (msg == diag::err_bad_cxx_cast_generic && tryDiagnoseOverloadedCast(S, castType, opRange, src, destType, listInitialization))"},{x,966,"/// CheckConstCast - Check that a const_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.11 for details. const_cast is typically used in code\n/// like this:\n/// const char *str = \"literal\";\n/// legacy_function(const_cast\\<char*\\>(str));\nvoid CastOperation::CheckConstCast() {\n unsigned msg = diag::err_bad_cxx_cast_generic;"},{x,977,"void CastOperation::CheckAddrspaceCast() {\n unsigned msg = diag::err_bad_cxx_cast_generic;"},{x,1193,"/// CheckReinterpretCast - Check that a reinterpret_cast\\<DestType\\>(SrcExpr) is\n/// valid.\n/// Refer to C++ 5.2.10 for details. reinterpret_cast is typically used in code\n/// like this:\n/// char *bytes = reinterpret_cast\\<char*\\>(int_ptr);\nvoid CastOperation::CheckReinterpretCast() {\n unsigned msg = diag::err_bad_cxx_cast_generic;"},{x,1265,"/// CheckStaticCast - Check that a static_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.9 for details. Static casts are mostly used for making\n/// implicit conversions explicit and getting rid of data loss warnings.\nvoid CastOperation::CheckStaticCast() {\n unsigned msg = diag::err_bad_cxx_cast_generic;"},{x,2798,"void CastOperation::CheckCXXCStyleCast(bool FunctionalStyle, bool ListInitialization) {\n unsigned msg = diag::err_bad_cxx_cast_generic;"}}, | ||
[o]={ | [o]={ | ||
Line 5,846: | Line 5,866: | ||
}, | }, | ||
["err_bad_cxx_cast_member_pointer_size"]={ | ["err_bad_cxx_cast_member_pointer_size"]={ | ||
[ | [e]="cannot ... from member pointer type A to member pointer type B of different size", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot %select{||reinterpret_cast||C-style cast||}0 from member pointer type %1 to member pointer type %2 of different size", | ||
[ | [b]=n, | ||
[ | [j]="cannot (?:||reinterpret_cast||C\\-style cast||) from member pointer type (.*?) to member pointer type (.*?) of different size", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"ebab1ed5d30c",1281936644,"Error out if reinterpret_casting between member pointers of two different","Error out if reinterpret_casting between member pointers of two different"}, | ||
[k]={{x,2340,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (DestMemPtr && SrcMemPtr) {\n // Don\'t allow casting between member pointers of different sizes.\n if (Self.Context.getTypeSize(DestMemPtr) != Self.Context.getTypeSize(SrcMemPtr)) {\n msg = diag::err_bad_cxx_cast_member_pointer_size;"}}, | [k]={{x,2340,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (DestMemPtr && SrcMemPtr) {\n // Don\'t allow casting between member pointers of different sizes.\n if (Self.Context.getTypeSize(DestMemPtr) != Self.Context.getTypeSize(SrcMemPtr)) {\n msg = diag::err_bad_cxx_cast_member_pointer_size;"}}, | ||
[o]={ | [o]={ | ||
Line 5,861: | Line 5,881: | ||
}, | }, | ||
["err_bad_cxx_cast_qualifiers_away"]={ | ["err_bad_cxx_cast_qualifiers_away"]={ | ||
[ | [e]="... from A to B casts away qualifiers", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{const_cast|static_cast|reinterpret_cast|dynamic_cast|C-style cast|functional-style cast|}0 from %1 to %2 casts away qualifiers", | ||
[ | [b]=n, | ||
[ | [j]="(?:const_cast|static_cast|reinterpret_cast|dynamic_cast|C\\-style cast|functional\\-style cast|) from (.*?) to (.*?) casts away qualifiers", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"b472e93af799",1302890394,"Implement appropriate semantics for C++ casting and conversion when","Implement appropriate semantics for C++ casting and conversion when"}, | ||
[k]={{x,767,"static TryCastResult getCastAwayConstnessCastKind(CastAwayConstnessKind CACK, unsigned &DiagID) {\n case CastAwayConstnessKind::CACK_SimilarKind:\n DiagID = diag::err_bad_cxx_cast_qualifiers_away;"},{x,881,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n // C++ 5.2.7p1: The dynamic_cast operator shall not cast away constness.\n if (!DestPointee.isAtLeastAsQualifiedAs(SrcPointee)) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_cxx_cast_qualifiers_away) << CT_Dynamic << OrigSrcType << this->DestType << OpRange;"},{x,1455,"/// TryStaticCast - Check if a static cast can be performed, and do so if\n/// possible. If @p CStyle, ignore access restrictions on hierarchy casting\n/// and casting away constness.\nstatic TryCastResult TryStaticCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, Sema::CheckedConversionKind CCK, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath, bool ListInitialization) {\n // Reverse pointer conversion to void*. C++ 4.10.p2 specifies conversion to\n // void*. C++ 5.2.9p10 specifies additional restrictions, which really is\n // just the usual constness stuff.\n if (const PointerType *SrcPointer = SrcType->getAs<PointerType>()) {\n if (SrcPointee->isVoidType()) {\n if (const PointerType *DestPointer = DestType->getAs<PointerType>()) {\n if (DestPointee->isIncompleteOrObjectType()) {\n // This is definitely the intended conversion, but it might fail due\n // to a qualifier violation. Note that we permit Objective-C lifetime\n // and GC qualifier mismatches here.\n if (!CStyle) {\n if (DestPointeeQuals != SrcPointeeQuals && !DestPointeeQuals.compatiblyIncludes(SrcPointeeQuals)) {\n msg = diag::err_bad_cxx_cast_qualifiers_away;"},{x,1687,"/// 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 // Must preserve cv, as always, unless we\'re in C-style mode.\n if (!CStyle && !DestType.isAtLeastAsQualifiedAs(SrcType)) {\n msg = diag::err_bad_cxx_cast_qualifiers_away;"}}, | [k]={{x,767,"static TryCastResult getCastAwayConstnessCastKind(CastAwayConstnessKind CACK, unsigned &DiagID) {\n case CastAwayConstnessKind::CACK_SimilarKind:\n DiagID = diag::err_bad_cxx_cast_qualifiers_away;"},{x,881,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n // C++ 5.2.7p1: The dynamic_cast operator shall not cast away constness.\n if (!DestPointee.isAtLeastAsQualifiedAs(SrcPointee)) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_cxx_cast_qualifiers_away) << CT_Dynamic << OrigSrcType << this->DestType << OpRange;"},{x,1455,"/// TryStaticCast - Check if a static cast can be performed, and do so if\n/// possible. If @p CStyle, ignore access restrictions on hierarchy casting\n/// and casting away constness.\nstatic TryCastResult TryStaticCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, Sema::CheckedConversionKind CCK, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath, bool ListInitialization) {\n // Reverse pointer conversion to void*. C++ 4.10.p2 specifies conversion to\n // void*. C++ 5.2.9p10 specifies additional restrictions, which really is\n // just the usual constness stuff.\n if (const PointerType *SrcPointer = SrcType->getAs<PointerType>()) {\n if (SrcPointee->isVoidType()) {\n if (const PointerType *DestPointer = DestType->getAs<PointerType>()) {\n if (DestPointee->isIncompleteOrObjectType()) {\n // This is definitely the intended conversion, but it might fail due\n // to a qualifier violation. Note that we permit Objective-C lifetime\n // and GC qualifier mismatches here.\n if (!CStyle) {\n if (DestPointeeQuals != SrcPointeeQuals && !DestPointeeQuals.compatiblyIncludes(SrcPointeeQuals)) {\n msg = diag::err_bad_cxx_cast_qualifiers_away;"},{x,1687,"/// 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 // Must preserve cv, as always, unless we\'re in C-style mode.\n if (!CStyle && !DestType.isAtLeastAsQualifiedAs(SrcType)) {\n msg = diag::err_bad_cxx_cast_qualifiers_away;"}}, | ||
[o]={ | [o]={ | ||
Line 5,876: | Line 5,896: | ||
}, | }, | ||
["err_bad_cxx_cast_rvalue"]={ | ["err_bad_cxx_cast_rvalue"]={ | ||
[ | [e]="... from rvalue to reference type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{const_cast|static_cast|reinterpret_cast|dynamic_cast|C-style cast|functional-style cast|addrspace_cast}0 from rvalue to reference type %2", | ||
[ | [b]=n, | ||
[ | [j]="(?:const_cast|static_cast|reinterpret_cast|dynamic_cast|C\\-style cast|functional\\-style cast|addrspace_cast) from rvalue to reference type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,845,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointer) {\n } else if (DestReference->isLValueReferenceType()) {\n if (!SrcExpr.get()->isLValue()) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_cxx_cast_rvalue) << CT_Dynamic << OrigSrcType << this->DestType << OpRange;"},{x,1595,"/// Tests whether a conversion according to C++ 5.2.9p5 is valid.\nTryCastResult TryStaticReferenceDowncast(Sema &Self, Expr *SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath) {\n if (!RValueRef && !SrcExpr->isLValue()) {\n msg = diag::err_bad_cxx_cast_rvalue;"},{x,1955,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n if (isa<LValueReferenceType>(DestTypeTmp) && !SrcExpr.get()->isLValue()) {\n msg = diag::err_bad_cxx_cast_rvalue;"},{x,1963,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n if (isa<RValueReferenceType>(DestTypeTmp) && SrcExpr.get()->isPRValue()) {\n if (!SrcType->isRecordType()) {\n msg = diag::err_bad_cxx_cast_rvalue;"},{x,2272,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n if (!SrcExpr.get()->isGLValue()) {\n msg = diag::err_bad_cxx_cast_rvalue;"}}, | [k]={{x,845,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointer) {\n } else if (DestReference->isLValueReferenceType()) {\n if (!SrcExpr.get()->isLValue()) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_cxx_cast_rvalue) << CT_Dynamic << OrigSrcType << this->DestType << OpRange;"},{x,1595,"/// Tests whether a conversion according to C++ 5.2.9p5 is valid.\nTryCastResult TryStaticReferenceDowncast(Sema &Self, Expr *SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath) {\n if (!RValueRef && !SrcExpr->isLValue()) {\n msg = diag::err_bad_cxx_cast_rvalue;"},{x,1955,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n if (isa<LValueReferenceType>(DestTypeTmp) && !SrcExpr.get()->isLValue()) {\n msg = diag::err_bad_cxx_cast_rvalue;"},{x,1963,"/// TryConstCast - See if a const_cast from source to destination is allowed,\n/// and perform it if it is.\nstatic TryCastResult TryConstCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, unsigned &msg) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n if (isa<RValueReferenceType>(DestTypeTmp) && SrcExpr.get()->isPRValue()) {\n if (!SrcType->isRecordType()) {\n msg = diag::err_bad_cxx_cast_rvalue;"},{x,2272,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n if (!SrcExpr.get()->isGLValue()) {\n msg = diag::err_bad_cxx_cast_rvalue;"}}, | ||
[o]={ | [o]={ | ||
[ | [Ab]={"clang/test/SemaCXX/dynamic-cast.cpp:41:9: error: dynamic_cast from rvalue to reference type \'A &\'"} | ||
} | } | ||
}, | }, | ||
["err_bad_cxx_cast_scalar_to_vector_different_size"]={ | ["err_bad_cxx_cast_scalar_to_vector_different_size"]={ | ||
[ | [e]="... from scalar A to vector B of different size", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{||reinterpret_cast||C-style cast||}0 from scalar %1 to vector %2 of different size", | ||
[ | [b]=n, | ||
[ | [j]="(?:||reinterpret_cast||C\\-style cast||) from scalar (.*?) to vector (.*?) of different size", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"570af5d42678",1253128783,ac,ac}, | ||
[k]={{x,2419,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (srcIsVector || destIsVector) {\n // Otherwise, pick a reasonable diagnostic.\n if (!destIsVector)\n else if (!srcIsVector)\n msg = diag::err_bad_cxx_cast_scalar_to_vector_different_size;"}}, | [k]={{x,2419,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (srcIsVector || destIsVector) {\n // Otherwise, pick a reasonable diagnostic.\n if (!destIsVector)\n else if (!srcIsVector)\n msg = diag::err_bad_cxx_cast_scalar_to_vector_different_size;"}}, | ||
[o]={ | [o]={ | ||
Line 5,906: | Line 5,926: | ||
}, | }, | ||
["err_bad_cxx_cast_unrelated_class"]={ | ["err_bad_cxx_cast_unrelated_class"]={ | ||
[ | [e]="... from A to B, which are not related by inheritance, is not allowed", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{const_cast|static_cast|reinterpret_cast|dynamic_cast|C-style cast|functional-style cast|}0 from %1 to %2, which are not related by inheritance, is not allowed", | ||
[ | [b]=n, | ||
[ | [j]="(?:const_cast|static_cast|reinterpret_cast|dynamic_cast|C\\-style cast|functional\\-style cast|) from (.*?) to (.*?), which are not related by inheritance, is not allowed", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"ffa7dc379f2e",1422480686,"PR 17456","PR 17456"}, | ||
[k]={{x,1505,"/// TryStaticCast - Check if a static cast can be performed, and do so if\n/// possible. If @p CStyle, ignore access restrictions on hierarchy casting\n/// and casting away constness.\nstatic TryCastResult TryStaticCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, Sema::CheckedConversionKind CCK, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath, bool ListInitialization) {\n // See if it looks like the user is trying to convert between\n // related record types, and select a better diagnostic if so.\n if (auto SrcPointer = SrcType->getAs<PointerType>())\n if (auto DestPointer = DestType->getAs<PointerType>())\n if (SrcPointer->getPointeeType()->getAs<RecordType>() && DestPointer->getPointeeType()->getAs<RecordType>())\n msg = diag::err_bad_cxx_cast_unrelated_class;"}}, | [k]={{x,1505,"/// TryStaticCast - Check if a static cast can be performed, and do so if\n/// possible. If @p CStyle, ignore access restrictions on hierarchy casting\n/// and casting away constness.\nstatic TryCastResult TryStaticCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, Sema::CheckedConversionKind CCK, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath, bool ListInitialization) {\n // See if it looks like the user is trying to convert between\n // related record types, and select a better diagnostic if so.\n if (auto SrcPointer = SrcType->getAs<PointerType>())\n if (auto DestPointer = DestType->getAs<PointerType>())\n if (SrcPointer->getPointeeType()->getAs<RecordType>() && DestPointer->getPointeeType()->getAs<RecordType>())\n msg = diag::err_bad_cxx_cast_unrelated_class;"}}, | ||
[o]={ | [o]={ | ||
Line 5,921: | Line 5,941: | ||
}, | }, | ||
["err_bad_cxx_cast_vector_to_scalar_different_size"]={ | ["err_bad_cxx_cast_vector_to_scalar_different_size"]={ | ||
[ | [e]="... from vector A to scalar B of different size", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{||reinterpret_cast||C-style cast||}0 from vector %1 to scalar %2 of different size", | ||
[ | [b]=n, | ||
[ | [j]="(?:||reinterpret_cast||C\\-style cast||) from vector (.*?) to scalar (.*?) of different size", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"570af5d42678",1253128783,ac,ac}, | ||
[k]={{x,2417,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (srcIsVector || destIsVector) {\n // Otherwise, pick a reasonable diagnostic.\n if (!destIsVector)\n msg = diag::err_bad_cxx_cast_vector_to_scalar_different_size;"}}, | [k]={{x,2417,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (srcIsVector || destIsVector) {\n // Otherwise, pick a reasonable diagnostic.\n if (!destIsVector)\n msg = diag::err_bad_cxx_cast_vector_to_scalar_different_size;"}}, | ||
[o]={ | [o]={ | ||
Line 5,936: | Line 5,956: | ||
}, | }, | ||
["err_bad_cxx_cast_vector_to_vector_different_size"]={ | ["err_bad_cxx_cast_vector_to_vector_different_size"]={ | ||
[ | [e]="... from vector A to vector B of different size", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{||reinterpret_cast||C-style cast||}0 from vector %1 to vector %2 of different size", | ||
[ | [b]=n, | ||
[ | [j]="(?:||reinterpret_cast||C\\-style cast||) from vector (.*?) to vector (.*?) of different size", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"570af5d42678",1253128783,ac,ac}, | ||
[k]={{x,2421,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (srcIsVector || destIsVector) {\n // Otherwise, pick a reasonable diagnostic.\n if (!destIsVector)\n else if (!srcIsVector)\n else\n msg = diag::err_bad_cxx_cast_vector_to_vector_different_size;"}}, | [k]={{x,2421,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (srcIsVector || destIsVector) {\n // Otherwise, pick a reasonable diagnostic.\n if (!destIsVector)\n else if (!srcIsVector)\n else\n msg = diag::err_bad_cxx_cast_vector_to_vector_different_size;"}}, | ||
[o]={ | [o]={ | ||
Line 5,951: | Line 5,971: | ||
}, | }, | ||
["err_bad_dynamic_cast_not_class"]={ | ["err_bad_dynamic_cast_not_class"]={ | ||
[ | [e]="A is not a class type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 is not a class type", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) is not a class type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,822,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointee->isVoidType()) {\n } else if (DestRecord) {\n } else {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_class) << DestPointee.getUnqualifiedType() << DestRange;"},{x,867,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (SrcRecord) {\n } else {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_class) << SrcPointee.getUnqualifiedType() << SrcExpr.get()->getSourceRange();"}}, | [k]={{x,822,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointee->isVoidType()) {\n } else if (DestRecord) {\n } else {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_class) << DestPointee.getUnqualifiedType() << DestRange;"},{x,867,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (SrcRecord) {\n } else {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_class) << SrcPointee.getUnqualifiedType() << SrcExpr.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Ab]={"clang/test/SemaCXX/dynamic-cast.cpp:29:9: error: \'int\' is not a class type","clang/test/SemaCXX/dynamic-cast.cpp:31:9: error: \'int\' is not a class type","clang/test/SemaCXX/dynamic-cast.cpp:33:9: error: \'int\' is not a class type","clang/test/SemaCXX/dynamic-cast.cpp:35:9: error: \'int\' is not a class type"} | ||
} | } | ||
}, | }, | ||
["err_bad_dynamic_cast_not_polymorphic"]={ | ["err_bad_dynamic_cast_not_polymorphic"]={ | ||
[ | [e]="A is not polymorphic", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 is not polymorphic", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) is not polymorphic", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,913,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (!cast<CXXRecordDecl>(SrcDecl)->isPolymorphic()) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_polymorphic) << SrcPointee.getUnqualifiedType() << SrcExpr.get()->getSourceRange();"}}, | [k]={{x,913,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (!cast<CXXRecordDecl>(SrcDecl)->isPolymorphic()) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_polymorphic) << SrcPointee.getUnqualifiedType() << SrcExpr.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Ab]={"clang/test/SemaCXX/dynamic-cast.cpp:74:9: error: \'A\' is not polymorphic","clang/test/SemaCXX/dynamic-cast.cpp:75:9: error: \'A\' is not polymorphic"} | ||
} | } | ||
}, | }, | ||
["err_bad_dynamic_cast_not_ptr"]={ | ["err_bad_dynamic_cast_not_ptr"]={ | ||
[ | [e]="cannot use dynamic_cast to convert from A to B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot use dynamic_cast to convert from %0 to %1", | ||
[ | [b]=n, | ||
[ | [j]="cannot use dynamic_cast to convert from (.*?) to (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,838,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointer) {\n if (const PointerType *SrcPointer = SrcType->getAs<PointerType>()) {\n } else {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_ptr) << OrigSrcType << this->DestType << SrcExpr.get()->getSourceRange();"}}, | [k]={{x,838,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointer) {\n if (const PointerType *SrcPointer = SrcType->getAs<PointerType>()) {\n } else {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_ptr) << OrigSrcType << this->DestType << SrcExpr.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Ab]={"clang/test/SemaCXX/dynamic-cast.cpp:27:9: error: cannot use dynamic_cast to convert from \'int\' to \'A *\'"} | ||
} | } | ||
}, | }, | ||
["err_bad_dynamic_cast_not_ref_or_ptr"]={ | ["err_bad_dynamic_cast_not_ref_or_ptr"]={ | ||
[ | [e]="invalid target type A for dynamic_cast; target type must be a reference or pointer type to a defined class", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="invalid target type %0 for dynamic_cast; target type must be a reference or pointer type to a defined class", | ||
[ | [b]=n, | ||
[ | [j]="invalid target type (.*?) for dynamic_cast; target type must be a reference or pointer type to a defined class", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,805,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointer) {\n } else if ((DestReference = DestType->getAs<ReferenceType>())) {\n } else {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_ref_or_ptr) << this->DestType << DestRange;"}}, | [k]={{x,805,"/// CheckDynamicCast - Check that a dynamic_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.7 for details. Dynamic casts are used mostly for runtime-\n/// checked downcasts in class hierarchies.\nvoid CastOperation::CheckDynamicCast() {\n if (DestPointer) {\n } else if ((DestReference = DestType->getAs<ReferenceType>())) {\n } else {\n Self.Diag(OpRange.getBegin(), diag::err_bad_dynamic_cast_not_ref_or_ptr) << this->DestType << DestRange;"}}, | ||
[o]={ | [o]={ | ||
[ | [Ab]={"clang/test/SemaCXX/dynamic-cast.cpp:25:9: error: invalid target type \'A\' for dynamic_cast; target type must be a reference or pointer type to a defined class"} | ||
} | } | ||
}, | }, | ||
["err_bad_kernel_param_type"]={ | ["err_bad_kernel_param_type"]={ | ||
[ | [e]="A cannot be used as the type of a kernel parameter", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 cannot be used as the type of a kernel parameter", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) cannot be used as the type of a kernel parameter", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"efb38192b0b2",1374542616,"Error on more illegal kernel argument types for OpenCL","Error on more illegal kernel argument types for OpenCL"}, | ||
[k]={{ | [k]={{s,9480,"static void checkIsValidOpenCLKernelParameter(Sema &S, Declarator &D, ParmVarDecl *Param, llvm::SmallPtrSetImpl<const Type *> &ValidTypes) {\n case InvalidKernelParam:\n // OpenCL v1.2 s6.8 n:\n // A kernel function argument cannot be declared\n // of event_t type.\n // Do not diagnose half type since it is diagnosed as invalid argument\n // type for any function elsewhere.\n if (!PT->isHalfType()) {\n S.Diag(Param->getLocation(), diag::err_bad_kernel_param_type) << PT;"},{s,9582,"static void checkIsValidOpenCLKernelParameter(Sema &S, Declarator &D, ParmVarDecl *Param, llvm::SmallPtrSetImpl<const Type *> &ValidTypes) {\n do {\n for (const auto *FD : RD->fields()) {\n // OpenCL v1.2 s6.9.p:\n // Arguments to kernel functions that are declared to be a struct or union\n // do not allow OpenCL objects to be passed as elements of the struct or\n // union. This restriction was lifted in OpenCL v2.0 with the introduction\n // of SVM.\n if (ParamType == PtrKernelParam || ParamType == PtrPtrKernelParam || ParamType == InvalidAddrSpacePtrKernelParam) {\n } else {\n S.Diag(Param->getLocation(), diag::err_bad_kernel_param_type) << PT;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaOpenCL/event_t.cl"]={"clang/test/SemaOpenCL/event_t.cl:11:25: error: \'__private event_t\' cannot be used as the type of a kernel parameter"} | ["clang/test/SemaOpenCL/event_t.cl"]={"clang/test/SemaOpenCL/event_t.cl:11:25: error: \'__private event_t\' cannot be used as the type of a kernel parameter"} | ||
Line 6,026: | Line 6,046: | ||
}, | }, | ||
["err_bad_lvalue_to_rvalue_cast"]={ | ["err_bad_lvalue_to_rvalue_cast"]={ | ||
[ | [e]="cannot cast from lvalue of type A to rvalue reference type B; types are not compatible", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot cast from lvalue of type %1 to rvalue reference type %2; types are not compatible", | ||
[ | [b]=n, | ||
[ | [j]="cannot cast from lvalue of type (.*?) to rvalue reference type (.*?); types are not compatible", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e97585f7177e",1237761006,"Implement static_cast from lvalue to rvalue reference.","Implement static_cast from lvalue to rvalue reference."}, | ||
[k]={{x,1553,"/// Tests whether a conversion according to N2844 is valid.\nTryCastResult TryLValueToRValueCast(Sema &Self, Expr *SrcExpr, QualType DestType, bool CStyle, CastKind &Kind, CXXCastPath &BasePath, unsigned &msg) {\n if (RefResult != Sema::Ref_Compatible) {\n msg = SrcExpr->isLValue() ? diag::err_bad_lvalue_to_rvalue_cast : diag::err_bad_rvalue_to_rvalue_cast;"}}, | [k]={{x,1553,"/// Tests whether a conversion according to N2844 is valid.\nTryCastResult TryLValueToRValueCast(Sema &Self, Expr *SrcExpr, QualType DestType, bool CStyle, CastKind &Kind, CXXCastPath &BasePath, unsigned &msg) {\n if (RefResult != Sema::Ref_Compatible) {\n msg = SrcExpr->isLValue() ? diag::err_bad_lvalue_to_rvalue_cast : diag::err_bad_rvalue_to_rvalue_cast;"}}, | ||
[o]={ | [o]={ | ||
Line 6,041: | Line 6,061: | ||
}, | }, | ||
["err_bad_memptr_lhs"]={ | ["err_bad_memptr_lhs"]={ | ||
[ | [e]="left hand operand to A must be a ...class compatible with the right hand operand, but is B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="left hand operand to %0 must be a %select{|pointer to }1class compatible with the right hand operand, but is %2", | ||
[ | [b]=n, | ||
[ | [j]="left hand operand to (.*?) must be a (?:|pointer to )class compatible with the right hand operand, but is (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{y,6022,"QualType Sema::CheckPointerToMemberOperands(ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, SourceLocation Loc, bool isIndirect) {\n if (isIndirect) {\n if (const PointerType *Ptr = LHSType->getAs<PointerType>())\n else {\n Diag(Loc, diag::err_bad_memptr_lhs) << OpSpelling << 1 << LHSType << FixItHint::CreateReplacement(SourceRange(Loc), \".*\");"},{y,6031,"QualType Sema::CheckPointerToMemberOperands(ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, SourceLocation Loc, bool isIndirect) {\n if (!Context.hasSameUnqualifiedType(Class, LHSType)) {\n if (RequireCompleteType(Loc, LHSType, diag::err_bad_memptr_lhs, OpSpelling, (int)isIndirect)) {"},{y,6037,"QualType Sema::CheckPointerToMemberOperands(ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, SourceLocation Loc, bool isIndirect) {\n if (!Context.hasSameUnqualifiedType(Class, LHSType)) {\n if (!IsDerivedFrom(Loc, LHSType, Class)) {\n Diag(Loc, diag::err_bad_memptr_lhs) << OpSpelling << (int)isIndirect << LHS.get()->getType();"}}, | [k]={{y,6022,"QualType Sema::CheckPointerToMemberOperands(ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, SourceLocation Loc, bool isIndirect) {\n if (isIndirect) {\n if (const PointerType *Ptr = LHSType->getAs<PointerType>())\n else {\n Diag(Loc, diag::err_bad_memptr_lhs) << OpSpelling << 1 << LHSType << FixItHint::CreateReplacement(SourceRange(Loc), \".*\");"},{y,6031,"QualType Sema::CheckPointerToMemberOperands(ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, SourceLocation Loc, bool isIndirect) {\n if (!Context.hasSameUnqualifiedType(Class, LHSType)) {\n if (RequireCompleteType(Loc, LHSType, diag::err_bad_memptr_lhs, OpSpelling, (int)isIndirect)) {"},{y,6037,"QualType Sema::CheckPointerToMemberOperands(ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, SourceLocation Loc, bool isIndirect) {\n if (!Context.hasSameUnqualifiedType(Class, LHSType)) {\n if (!IsDerivedFrom(Loc, LHSType, Class)) {\n Diag(Loc, diag::err_bad_memptr_lhs) << OpSpelling << (int)isIndirect << LHS.get()->getType();"}}, | ||
[o]={ | [o]={ | ||
Line 6,056: | Line 6,076: | ||
}, | }, | ||
["err_bad_memptr_rhs"]={ | ["err_bad_memptr_rhs"]={ | ||
[ | [e]="right hand operand to A has non-pointer-to-member type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="right hand operand to %0 has non-pointer-to-member type %1", | ||
[ | [b]=n, | ||
[ | [j]="right hand operand to (.*?) has non\\-pointer\\-to\\-member type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{y,6000,"QualType Sema::CheckPointerToMemberOperands(ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, SourceLocation Loc, bool isIndirect) {\n if (!MemPtr) {\n Diag(Loc, diag::err_bad_memptr_rhs) << OpSpelling << RHSType << RHS.get()->getSourceRange();"}}, | [k]={{y,6000,"QualType Sema::CheckPointerToMemberOperands(ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, SourceLocation Loc, bool isIndirect) {\n if (!MemPtr) {\n Diag(Loc, diag::err_bad_memptr_rhs) << OpSpelling << RHSType << RHS.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 6,071: | Line 6,091: | ||
}, | }, | ||
["err_bad_multiversion_option"]={ | ["err_bad_multiversion_option"]={ | ||
[ | [e]="function multiversioning doesn\'t support ... \'A\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="function multiversioning doesn\'t support %select{feature|architecture}0 \'%1\'", | ||
[ | [b]=n, | ||
[ | [j]="function multiversioning doesn\'t support (?:feature|architecture) \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"281d20b601c8",1515447257,"Implement Attribute Target MultiVersioning","Implement Attribute Target MultiVersioning"}, | ||
[k]={{ | [k]={{s,10957,"/// Check the target or target_version attribute of the function for\n/// MultiVersion validity.\n///\n/// Returns true if there was an error, false otherwise.\nstatic bool CheckMultiVersionValue(Sema &S, const FunctionDecl *FD) {\n if (TA) {\n if (!ParseInfo.CPU.empty() && !TargetInfo.validateCpuIs(ParseInfo.CPU)) {\n S.Diag(FD->getLocation(), diag::err_bad_multiversion_option) << Architecture << ParseInfo.CPU;"},{s,10964,"/// Check the target or target_version attribute of the function for\n/// MultiVersion validity.\n///\n/// Returns true if there was an error, false otherwise.\nstatic bool CheckMultiVersionValue(Sema &S, const FunctionDecl *FD) {\n if (TA) {\n for (const auto &Feat : ParseInfo.Features) {\n if (Feat[0] == \'-\') {\n S.Diag(FD->getLocation(), diag::err_bad_multiversion_option) << Feature << (\"no-\" + BareFeat).str();"},{s,10971,"/// Check the target or target_version attribute of the function for\n/// MultiVersion validity.\n///\n/// Returns true if there was an error, false otherwise.\nstatic bool CheckMultiVersionValue(Sema &S, const FunctionDecl *FD) {\n if (TA) {\n for (const auto &Feat : ParseInfo.Features) {\n if (!TargetInfo.validateCpuSupports(BareFeat) || !TargetInfo.isValidFeatureName(BareFeat)) {\n S.Diag(FD->getLocation(), diag::err_bad_multiversion_option) << Feature << BareFeat;"},{s,10983,"/// Check the target or target_version attribute of the function for\n/// MultiVersion validity.\n///\n/// Returns true if there was an error, false otherwise.\nstatic bool CheckMultiVersionValue(Sema &S, const FunctionDecl *FD) {\n if (TVA) {\n for (const auto &Feat : Feats) {\n if (!TargetInfo.validateCpuSupports(Feat)) {\n S.Diag(FD->getLocation(), diag::err_bad_multiversion_option) << Feature << Feat;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/attr-target-mv.cpp"]={"clang/test/SemaCXX/attr-target-mv.cpp:7:43: error: function multiversioning doesn\'t support feature \'no-sse4.2\'"} | ["clang/test/SemaCXX/attr-target-mv.cpp"]={"clang/test/SemaCXX/attr-target-mv.cpp:7:43: error: function multiversioning doesn\'t support feature \'no-sse4.2\'"} | ||
Line 6,086: | Line 6,106: | ||
}, | }, | ||
["err_bad_new_type"]={ | ["err_bad_new_type"]={ | ||
[ | [e]="cannot allocate ... type A with new", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot allocate %select{function|reference}1 type %0 with new", | ||
[ | [b]=n, | ||
[ | [j]="cannot allocate (?:function|reference) type (.*?) with new", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{y,2458,"/// 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 return Diag(Loc, diag::err_bad_new_type) << AllocType << 0 << R;"},{y,2461,"/// 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 else if (AllocType->isReferenceType())\n return Diag(Loc, diag::err_bad_new_type) << AllocType << 1 << R;"}}, | [k]={{y,2458,"/// 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 return Diag(Loc, diag::err_bad_new_type) << AllocType << 0 << R;"},{y,2461,"/// 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 else if (AllocType->isReferenceType())\n return Diag(Loc, diag::err_bad_new_type) << AllocType << 1 << R;"}}, | ||
[o]={ | [o]={ | ||
Line 6,101: | Line 6,121: | ||
}, | }, | ||
["err_bad_parameter_name"]={ | ["err_bad_parameter_name"]={ | ||
[ | [e]="A cannot be the name of a parameter", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 cannot be the name of a parameter", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) cannot be the name of a parameter", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"a56cbccfc413",1288746426,"Provide an error when a non-identifier name (such as an operator) is used as a","Provide an error when a non-identifier name (such as an operator) is used as a"}, | ||
[k]={{ | [k]={{s,14711,"/// Common checks for a parameter-declaration that should apply to both function\n/// parameters and non-type template parameters.\nvoid Sema::CheckFunctionOrTemplateParamDeclarator(Scope *S, Declarator &D) {\n case UnqualifiedIdKind::IK_DeductionGuideName:\n Diag(D.getIdentifierLoc(), diag::err_bad_parameter_name) << GetNameForDeclarator(D).getName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/PR8012.cpp"]={"clang/test/SemaCXX/PR8012.cpp:3:14: error: \'operator+\' cannot be the name of a parameter"} | ["clang/test/SemaCXX/PR8012.cpp"]={"clang/test/SemaCXX/PR8012.cpp:3:14: error: \'operator+\' cannot be the name of a parameter"} | ||
Line 6,116: | Line 6,136: | ||
}, | }, | ||
["err_bad_parameter_name_template_id"]={ | ["err_bad_parameter_name_template_id"]={ | ||
[e]="parameter name cannot have template arguments", | |||
[d]=l, | |||
[f]=m, | |||
[h]="parameter name cannot have template arguments", | [h]="parameter name cannot have template arguments", | ||
[ | [b]=n, | ||
[ | [j]="parameter name cannot have template arguments", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"da70fc0c5f5b",1560542514,"PR42071: Reject weird names for non-type template parameters.","PR42071: Reject weird names for non-type template parameters."}, | |||
[k]={{s,14718,"/// Common checks for a parameter-declaration that should apply to both function\n/// parameters and non-type template parameters.\nvoid Sema::CheckFunctionOrTemplateParamDeclarator(Scope *S, Declarator &D) {\n case UnqualifiedIdKind::IK_ConstructorTemplateId:\n Diag(D.getIdentifierLoc(), diag::err_bad_parameter_name_template_id);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/cxx-template-decl.cpp"]={"clang/test/Parser/cxx-template-decl.cpp:261:16: error: parameter name cannot have template arguments"} | ["clang/test/Parser/cxx-template-decl.cpp"]={"clang/test/Parser/cxx-template-decl.cpp:261:16: error: parameter name cannot have template arguments"} | ||
Line 6,131: | Line 6,151: | ||
}, | }, | ||
["err_bad_property_context"]={ | ["err_bad_property_context"]={ | ||
[e]="property implementation must be in a class or category implementation", | |||
[d]=l, | |||
[f]=m, | |||
[h]="property implementation must be in a class or category implementation", | [h]="property implementation must be in a class or category implementation", | ||
[ | [b]=n, | ||
[ | [j]="property implementation must be in a class or category implementation", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={Xb,1480718311,gb,gb}, | |||
[ | [k]={{Y,1199,"/// 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 if ((IC = dyn_cast<ObjCImplementationDecl>(ClassImpDecl))) {\n } else if ((CatImplClass = dyn_cast<ObjCCategoryImplDecl>(ClassImpDecl))) {\n } else {\n Diag(AtLoc, diag::err_bad_property_context);"}} | ||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_bad_property_decl"]={ | ["err_bad_property_decl"]={ | ||
[ | [e]="property implementation must have its declaration in interface A or one of its extensions", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="property implementation must have its declaration in interface %0 or one of its extensions", | ||
[ | [b]=n, | ||
[ | [j]="property implementation must have its declaration in interface (.*?) or one of its extensions", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Xb,1480718311,gb,gb}, | ||
[k]={{ | [k]={{Y,1114,"/// 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 if ((IC = dyn_cast<ObjCImplementationDecl>(ClassImpDecl))) {\n if (!property) {\n Diag(PropertyLoc, diag::err_bad_property_decl) << IDecl->getDeclName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/property.m"]={"clang/test/SemaObjC/property.m:19:13: error: property implementation must have its declaration in interface \'I\' or one of its extensions","clang/test/SemaObjC/property.m:31:10: error: property implementation must have its declaration in interface \'E\' or one of its extensions"} | ["clang/test/SemaObjC/property.m"]={"clang/test/SemaObjC/property.m:19:13: error: property implementation must have its declaration in interface \'I\' or one of its extensions","clang/test/SemaObjC/property.m:31:10: error: property implementation must have its declaration in interface \'E\' or one of its extensions"} | ||
Line 6,158: | Line 6,178: | ||
}, | }, | ||
["err_bad_receiver_type"]={ | ["err_bad_receiver_type"]={ | ||
[ | [e]="bad receiver type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="bad receiver type %0", | ||
[ | [b]=n, | ||
[ | [j]="bad receiver type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{M,3130,"/// 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 if (!Method) {\n if (receiverIsIdLike || ReceiverType->isBlockPointerType() || (Receiver && Context.isObjCNSObjectType(Receiver->getType()))) {\n } else if (ReceiverType->isObjCClassOrClassKindOfType() || ReceiverType->isObjCQualifiedClassType()) {\n } else {\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 } else if (const ObjCObjectPointerType *OCIType = ReceiverType->getAsObjCInterfacePointerType()) {\n } else {\n Diag(Loc, diag::err_bad_receiver_type) << ReceiverType << RecRange;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/ARCMT/nonobjc-to-objc-cast-2.m"]={"clang/test/ARCMT/nonobjc-to-objc-cast-2.m:46:10: error: bad receiver type \'CFStringRef\' (aka \'const struct __CFString *\')"} | ["clang/test/ARCMT/nonobjc-to-objc-cast-2.m"]={"clang/test/ARCMT/nonobjc-to-objc-cast-2.m:46:10: error: bad receiver type \'CFStringRef\' (aka \'const struct __CFString *\')"} | ||
Line 6,173: | Line 6,193: | ||
}, | }, | ||
["err_bad_reinterpret_cast_overload"]={ | ["err_bad_reinterpret_cast_overload"]={ | ||
[ | [e]="reinterpret_cast cannot resolve overloaded function A to type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="reinterpret_cast cannot resolve overloaded function %0 to type %1", | ||
[ | [b]=n, | ||
[ | [j]="reinterpret_cast cannot resolve overloaded function (.*?) to type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e81f58e18011",1289187648,"Properly diagnose invalid casts to function references. Patch by","Properly diagnose invalid casts to function references. Patch by"}, | ||
[k]={{x,1202,"/// CheckReinterpretCast - Check that a reinterpret_cast\\<DestType\\>(SrcExpr) is\n/// valid.\n/// Refer to C++ 5.2.10 for details. reinterpret_cast is typically used in code\n/// like this:\n/// char *bytes = reinterpret_cast\\<char*\\>(int_ptr);\nvoid CastOperation::CheckReinterpretCast() {\n if (tcr != TC_Success && msg != 0) {\n if (SrcExpr.get()->getType() == Self.Context.OverloadTy) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_reinterpret_cast_overload) << OverloadExpr::find(SrcExpr.get()).Expression->getName() << DestType << OpRange;"}}, | [k]={{x,1202,"/// CheckReinterpretCast - Check that a reinterpret_cast\\<DestType\\>(SrcExpr) is\n/// valid.\n/// Refer to C++ 5.2.10 for details. reinterpret_cast is typically used in code\n/// like this:\n/// char *bytes = reinterpret_cast\\<char*\\>(int_ptr);\nvoid CastOperation::CheckReinterpretCast() {\n if (tcr != TC_Success && msg != 0) {\n if (SrcExpr.get()->getType() == Self.Context.OverloadTy) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_reinterpret_cast_overload) << OverloadExpr::find(SrcExpr.get()).Expression->getName() << DestType << OpRange;"}}, | ||
[o]={ | [o]={ | ||
Line 6,188: | Line 6,208: | ||
}, | }, | ||
["err_bad_reinterpret_cast_reference"]={ | ["err_bad_reinterpret_cast_reference"]={ | ||
[ | [e]="reinterpret_cast of a A to B needs its address, which is not allowed", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="reinterpret_cast of a %0 to %1 needs its address, which is not allowed", | ||
[ | [b]=n, | ||
[ | [j]="reinterpret_cast of a (.*?) to (.*?) needs its address, which is not allowed", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"bf04231a7254",1303516677,"Don\'t allow reinterpret_cast to reference of vector element and property expression. Thanks goes to ...","Don\'t allow reinterpret_cast to reference of vector element and property expression. Thanks goes to Eli Friedman!"}, | ||
[k]={{x,2302,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n if (inappropriate) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_reinterpret_cast_reference) << inappropriate << DestType << OpRange << SrcExpr.get()->getSourceRange();"}}, | [k]={{x,2302,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (const ReferenceType *DestTypeTmp = DestType->getAs<ReferenceType>()) {\n if (inappropriate) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_reinterpret_cast_reference) << inappropriate << DestType << OpRange << SrcExpr.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 6,203: | Line 6,223: | ||
}, | }, | ||
["err_bad_reinterpret_cast_small_int"]={ | ["err_bad_reinterpret_cast_small_int"]={ | ||
[ | [e]="cast from pointer to smaller type A loses information", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cast from pointer to smaller type %2 loses information", | ||
[ | [b]=n, | ||
[ | [j]="cast from pointer to smaller type (.*?) loses information", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{x,2367,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n // See below for the enumeral issue.\n if (SrcType->isNullPtrType() && DestType->isIntegralType(Self.Context)) {\n // C++0x 5.2.10p4: A pointer can be explicitly converted to any integral\n // type large enough to hold it. A value of std::nullptr_t can be\n // converted to an integral type; the conversion has the same meaning\n // and validity as a conversion of (void*)0 to the integral type.\n if (Self.Context.getTypeSize(SrcType) > Self.Context.getTypeSize(DestType)) {\n msg = diag::err_bad_reinterpret_cast_small_int;"},{x,2471,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (DestType->isIntegralType(Self.Context)) {\n // C++ 5.2.10p4: A pointer can be explicitly converted to any integral\n // type large enough to hold it; except in Microsoft mode, where the\n // integral type size doesn\'t matter (except we don\'t allow bool).\n if ((Self.Context.getTypeSize(SrcType) > Self.Context.getTypeSize(DestType))) {\n if (MicrosoftException) {\n } else {\n msg = diag::err_bad_reinterpret_cast_small_int;"}}, | [k]={{x,2367,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n // See below for the enumeral issue.\n if (SrcType->isNullPtrType() && DestType->isIntegralType(Self.Context)) {\n // C++0x 5.2.10p4: A pointer can be explicitly converted to any integral\n // type large enough to hold it. A value of std::nullptr_t can be\n // converted to an integral type; the conversion has the same meaning\n // and validity as a conversion of (void*)0 to the integral type.\n if (Self.Context.getTypeSize(SrcType) > Self.Context.getTypeSize(DestType)) {\n msg = diag::err_bad_reinterpret_cast_small_int;"},{x,2471,"static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind) {\n if (DestType->isIntegralType(Self.Context)) {\n // C++ 5.2.10p4: A pointer can be explicitly converted to any integral\n // type large enough to hold it; except in Microsoft mode, where the\n // integral type size doesn\'t matter (except we don\'t allow bool).\n if ((Self.Context.getTypeSize(SrcType) > Self.Context.getTypeSize(DestType))) {\n if (MicrosoftException) {\n } else {\n msg = diag::err_bad_reinterpret_cast_small_int;"}}, | ||
[o]={ | [o]={ | ||
Line 6,218: | Line 6,238: | ||
}, | }, | ||
["err_bad_rvalue_to_rvalue_cast"]={ | ["err_bad_rvalue_to_rvalue_cast"]={ | ||
[ | [e]="cannot cast from rvalue of type A to rvalue reference type B; types are not compatible", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot cast from rvalue of type %1 to rvalue reference type %2; types are not compatible", | ||
[ | [b]=n, | ||
[ | [j]="cannot cast from rvalue of type (.*?) to rvalue reference type (.*?); types are not compatible", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e4e9e281a1fb",1478139197,"[Sema] Allow static_cast<T&&>(e) to check explicit conversions for non-reference-related types.","[Sema] Allow static_cast<T&&>(e) to check explicit conversions for non-reference-related types."}, | ||
[k]={{x,1554,"/// Tests whether a conversion according to N2844 is valid.\nTryCastResult TryLValueToRValueCast(Sema &Self, Expr *SrcExpr, QualType DestType, bool CStyle, CastKind &Kind, CXXCastPath &BasePath, unsigned &msg) {\n if (RefResult != Sema::Ref_Compatible) {\n msg = SrcExpr->isLValue() ? diag::err_bad_lvalue_to_rvalue_cast : diag::err_bad_rvalue_to_rvalue_cast;"}}, | [k]={{x,1554,"/// Tests whether a conversion according to N2844 is valid.\nTryCastResult TryLValueToRValueCast(Sema &Self, Expr *SrcExpr, QualType DestType, bool CStyle, CastKind &Kind, CXXCastPath &BasePath, unsigned &msg) {\n if (RefResult != Sema::Ref_Compatible) {\n msg = SrcExpr->isLValue() ? diag::err_bad_lvalue_to_rvalue_cast : diag::err_bad_rvalue_to_rvalue_cast;"}}, | ||
[o]={ | [o]={ | ||
Line 6,233: | Line 6,253: | ||
}, | }, | ||
["err_bad_static_cast_member_pointer_nonmp"]={ | ["err_bad_static_cast_member_pointer_nonmp"]={ | ||
[ | [e]="cannot cast from type A to member pointer type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot cast from type %1 to member pointer type %2", | ||
[ | [b]=n, | ||
[ | [j]="cannot cast from type (.*?) to member pointer type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"9f831dbbcdfa",1248536498,"Implement C++ semantics for C-style and functional-style casts. This regresses Clang extension conve...","Implement C++ semantics for C-style and functional-style casts. This regresses Clang extension conversions, like vectors, but allows conversions via constructors and conversion operators."}, | ||
[k]={{x,1783,"/// 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 if (!SrcMemPtr) {\n msg = diag::err_bad_static_cast_member_pointer_nonmp;"}}, | [k]={{x,1783,"/// 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 if (!SrcMemPtr) {\n msg = diag::err_bad_static_cast_member_pointer_nonmp;"}}, | ||
[o]={ | [o]={ | ||
Line 6,248: | Line 6,268: | ||
}, | }, | ||
["err_bad_static_cast_overload"]={ | ["err_bad_static_cast_overload"]={ | ||
[ | [e]="address of overloaded function A cannot be static_cast to type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="address of overloaded function %0 cannot be static_cast to type %1", | ||
[ | [b]=n, | ||
[ | [j]="address of overloaded function (.*?) cannot be static_cast to type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e81f58e18011",1289187648,"Properly diagnose invalid casts to function references. Patch by","Properly diagnose invalid casts to function references. Patch by"}, | ||
[k]={{x,1249,"/// CheckStaticCast - Check that a static_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.9 for details. Static casts are mostly used for making\n/// implicit conversions explicit and getting rid of data loss warnings.\nvoid CastOperation::CheckStaticCast() {\n // This test is outside everything else because it\'s the only case where\n // a non-lvalue-reference target type does not lead to decay.\n // C++ 5.2.9p4: Any expression can be explicitly converted to type \"cv void\".\n if (DestType->isVoidType()) {\n if (claimPlaceholder(BuiltinType::Overload)) {\n Self.ResolveAndFixSingleFunctionTemplateSpecialization(SrcExpr,\n OpRange, DestType, diag::err_bad_static_cast_overload);"},{x,1274,"/// CheckStaticCast - Check that a static_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.9 for details. Static casts are mostly used for making\n/// implicit conversions explicit and getting rid of data loss warnings.\nvoid CastOperation::CheckStaticCast() {\n if (tcr != TC_Success && msg != 0) {\n if (SrcExpr.get()->getType() == Self.Context.OverloadTy) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_static_cast_overload) << oe->getName() << DestType << OpRange << oe->getQualifierLoc().getSourceRange();"}}, | [k]={{x,1249,"/// CheckStaticCast - Check that a static_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.9 for details. Static casts are mostly used for making\n/// implicit conversions explicit and getting rid of data loss warnings.\nvoid CastOperation::CheckStaticCast() {\n // This test is outside everything else because it\'s the only case where\n // a non-lvalue-reference target type does not lead to decay.\n // C++ 5.2.9p4: Any expression can be explicitly converted to type \"cv void\".\n if (DestType->isVoidType()) {\n if (claimPlaceholder(BuiltinType::Overload)) {\n Self.ResolveAndFixSingleFunctionTemplateSpecialization(SrcExpr,\n OpRange, DestType, diag::err_bad_static_cast_overload);"},{x,1274,"/// CheckStaticCast - Check that a static_cast\\<DestType\\>(SrcExpr) is valid.\n/// Refer to C++ 5.2.9 for details. Static casts are mostly used for making\n/// implicit conversions explicit and getting rid of data loss warnings.\nvoid CastOperation::CheckStaticCast() {\n if (tcr != TC_Success && msg != 0) {\n if (SrcExpr.get()->getType() == Self.Context.OverloadTy) {\n Self.Diag(OpRange.getBegin(), diag::err_bad_static_cast_overload) << oe->getName() << DestType << OpRange << oe->getQualifierLoc().getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 6,263: | Line 6,283: | ||
}, | }, | ||
["err_bad_static_cast_pointer_nonpointer"]={ | ["err_bad_static_cast_pointer_nonpointer"]={ | ||
[ | [e]="cannot cast from type A to pointer type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot cast from type %1 to pointer type %2", | ||
[ | [b]=n, | ||
[ | [j]="cannot cast from type (.*?) to pointer type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"9f831dbbcdfa",1248536498,"Implement C++ semantics for C-style and functional-style casts. This regresses Clang extension conve...","Implement C++ semantics for C-style and functional-style casts. This regresses Clang extension conversions, like vectors, but allows conversions via constructors and conversion operators."}, | ||
[k]={{x,1632,"/// Tests whether a conversion according to C++ 5.2.9p8 is valid.\nTryCastResult TryStaticPointerDowncast(Sema &Self, QualType SrcType, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath) {\n if (!SrcPointer) {\n msg = diag::err_bad_static_cast_pointer_nonpointer;"}}, | [k]={{x,1632,"/// Tests whether a conversion according to C++ 5.2.9p8 is valid.\nTryCastResult TryStaticPointerDowncast(Sema &Self, QualType SrcType, QualType DestType, bool CStyle, SourceRange OpRange, unsigned &msg, CastKind &Kind, CXXCastPath &BasePath) {\n if (!SrcPointer) {\n msg = diag::err_bad_static_cast_pointer_nonpointer;"}}, | ||
[o]={ | [o]={ | ||
Line 6,278: | Line 6,298: | ||
}, | }, | ||
["err_bad_string_encoding"]={ | ["err_bad_string_encoding"]={ | ||
[e]="illegal character encoding in string literal", | |||
[d]=l, | |||
[f]=m, | |||
[h]="illegal character encoding in string literal", | [h]="illegal character encoding in string literal", | ||
[ | [b]=n, | ||
[ | [j]="illegal character encoding in string literal", | ||
[c]=a, | |||
[ | [i]=rb, | ||
[g]={"703e7153af87",1320113690,"Perform proper conversion for strings encoded in the source file as UTF-8. (For now, we are assumin...","Perform proper conversion for strings encoded in the source file as UTF-8. (For now, we are assuming the source character set is always UTF-8; this can be easily extended if necessary.)"}, | |||
[ | |||
[ | |||
[k]={{"clang/lib/Lex/LiteralSupport.cpp",2265,"/// This function copies from Fragment, which is a sequence of bytes\n/// within Tok\'s contents (which begin at TokBegin) into ResultPtr.\n/// Performs widening for multi-byte characters.\nbool StringLiteralParser::CopyStringFragment(const Token &Tok, const char *TokBegin, StringRef Fragment) {\n if (Diags) {\n const DiagnosticBuilder &Builder = Diag(Diags, Features, SourceLoc, TokBegin, ErrorPtr, resyncUTF8(ErrorPtr, Fragment.end()), NoErrorOnBadEncoding ? diag::warn_bad_string_encoding : diag::err_bad_string_encoding);"}}, | [k]={{"clang/lib/Lex/LiteralSupport.cpp",2265,"/// This function copies from Fragment, which is a sequence of bytes\n/// within Tok\'s contents (which begin at TokBegin) into ResultPtr.\n/// Performs widening for multi-byte characters.\nbool StringLiteralParser::CopyStringFragment(const Token &Tok, const char *TokBegin, StringRef Fragment) {\n if (Diags) {\n const DiagnosticBuilder &Builder = Diag(Diags, Features, SourceLoc, TokBegin, ErrorPtr, resyncUTF8(ErrorPtr, Fragment.end()), NoErrorOnBadEncoding ? diag::warn_bad_string_encoding : diag::err_bad_string_encoding);"}}, | ||
[o]={ | [o]={ | ||
Line 6,293: | Line 6,313: | ||
}, | }, | ||
["err_bad_variable_name"]={ | ["err_bad_variable_name"]={ | ||
[ | [e]="A cannot be the name of a variable or data member", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 cannot be the name of a variable or data member", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) cannot be the name of a variable or data member", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{s,7462,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n if (D.isDecompositionDeclarator()) {\n } else if (!II) {\n Diag(D.getIdentifierLoc(), diag::err_bad_variable_name) << Name;"},{w,3545,"/// ActOnCXXMemberDeclarator - This is invoked when a C++ class member\n/// declarator is parsed. \'AS\' is the access specifier, \'BW\' specifies the\n/// bitfield width if there is one, \'InitExpr\' specifies the initializer if\n/// one has been parsed, and \'InitStyle\' is set if an in-class initializer is\n/// present (but parsing it has been deferred).\nNamedDecl *Sema::ActOnCXXMemberDeclarator(Scope *S, AccessSpecifier AS, Declarator &D, MultiTemplateParamsArg TemplateParameterLists, Expr *BW, const VirtSpecifiers &VS, InClassInitStyle InitStyle) {\n if (isInstField) {\n // Data members must have identifiers for names.\n if (!Name.isIdentifier()) {\n Diag(Loc, diag::err_bad_variable_name) << Name;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/overloaded-operator-decl.cpp"]={"clang/test/SemaCXX/overloaded-operator-decl.cpp:39:5: error: \'operator+\' cannot be the name of a variable or data member","clang/test/SemaCXX/overloaded-operator-decl.cpp:48:3: error: \'operator int\' cannot be the name of a variable or data member","clang/test/SemaCXX/overloaded-operator-decl.cpp:49:7: error: \'operator+\' cannot be the name of a variable or data member"} | ["clang/test/SemaCXX/overloaded-operator-decl.cpp"]={"clang/test/SemaCXX/overloaded-operator-decl.cpp:39:5: error: \'operator+\' cannot be the name of a variable or data member","clang/test/SemaCXX/overloaded-operator-decl.cpp:48:3: error: \'operator int\' cannot be the name of a variable or data member","clang/test/SemaCXX/overloaded-operator-decl.cpp:49:7: error: \'operator+\' cannot be the name of a variable or data member"} | ||
Line 6,308: | Line 6,328: | ||
}, | }, | ||
["err_base_class_has_flexible_array_member"]={ | ["err_base_class_has_flexible_array_member"]={ | ||
[ | [e]="base class A has a flexible array member", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="base class %0 has a flexible array member", | ||
[ | [b]=n, | ||
[ | [j]="base class (.*?) has a flexible array member", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"9b1754d05840",1383393636,"Sema: Disallow inheriting from classes with flexible array members","Sema: Disallow inheriting from classes with flexible array members"}, | ||
[k]={{w,2771,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n // A class which contains a flexible array member is not suitable for use as a\n // base class:\n // - If the layout determines that a base comes before another base,\n // the flexible array member would index into the subsequent base.\n // - If the layout determines that base comes before the derived class,\n // the flexible array member would index into the derived class.\n if (CXXBaseDecl->hasFlexibleArrayMember()) {\n Diag(BaseLoc, diag::err_base_class_has_flexible_array_member) << CXXBaseDecl->getDeclName();"}}, | [k]={{w,2771,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n // A class which contains a flexible array member is not suitable for use as a\n // base class:\n // - If the layout determines that a base comes before another base,\n // the flexible array member would index into the subsequent base.\n // - If the layout determines that base comes before the derived class,\n // the flexible array member would index into the derived class.\n if (CXXBaseDecl->hasFlexibleArrayMember()) {\n Diag(BaseLoc, diag::err_base_class_has_flexible_array_member) << CXXBaseDecl->getDeclName();"}}, | ||
[o]={ | [o]={ | ||
Line 6,323: | Line 6,343: | ||
}, | }, | ||
["err_base_clause_on_union"]={ | ["err_base_clause_on_union"]={ | ||
[e]="unions cannot have base classes", | |||
[d]=l, | |||
[f]=m, | |||
[h]="unions cannot have base classes", | [h]="unions cannot have base classes", | ||
[ | [b]=n, | ||
[ | [j]="unions cannot have base classes", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[ | |||
[ | |||
[k]={{w,2663,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n // C++ [class.union]p1:\n // A union shall not have base classes.\n if (Class->isUnion()) {\n Diag(Class->getLocation(), diag::err_base_clause_on_union) << SpecifierRange;"}}, | [k]={{w,2663,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n // C++ [class.union]p1:\n // A union shall not have base classes.\n if (Class->isUnion()) {\n Diag(Class->getLocation(), diag::err_base_clause_on_union) << SpecifierRange;"}}, | ||
[o]={ | [o]={ | ||
Line 6,338: | Line 6,358: | ||
}, | }, | ||
["err_base_init_direct_and_virtual"]={ | ["err_base_init_direct_and_virtual"]={ | ||
[ | [e]="base class initializer A names both a direct base class and an inherited virtual base class", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="base class initializer %0 names both a direct base class and an inherited virtual base class", | ||
[ | [b]=n, | ||
[ | [j]="base class initializer (.*?) names both a direct base class and an inherited virtual base class", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{w,4763,"MemInitResult Sema::BuildBaseInitializer(QualType BaseType, TypeSourceInfo *BaseTInfo, Expr *Init, CXXRecordDecl *ClassDecl, SourceLocation EllipsisLoc) {\n // C++ [base.class.init]p2:\n // If a mem-initializer-id is ambiguous because it designates both\n // a direct non-virtual base class and an inherited virtual base\n // class, the mem-initializer is ill-formed.\n if (DirectBaseSpec && VirtualBaseSpec)\n return Diag(BaseLoc, diag::err_base_init_direct_and_virtual) << BaseType << BaseTInfo->getTypeLoc().getLocalSourceRange();"}}, | [k]={{w,4763,"MemInitResult Sema::BuildBaseInitializer(QualType BaseType, TypeSourceInfo *BaseTInfo, Expr *Init, CXXRecordDecl *ClassDecl, SourceLocation EllipsisLoc) {\n // C++ [base.class.init]p2:\n // If a mem-initializer-id is ambiguous because it designates both\n // a direct non-virtual base class and an inherited virtual base\n // class, the mem-initializer is ill-formed.\n if (DirectBaseSpec && VirtualBaseSpec)\n return Diag(BaseLoc, diag::err_base_init_direct_and_virtual) << BaseType << BaseTInfo->getTypeLoc().getLocalSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 6,353: | Line 6,373: | ||
}, | }, | ||
["err_base_init_does_not_name_class"]={ | ["err_base_init_does_not_name_class"]={ | ||
[ | [e]="constructor initializer A does not name a class", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="constructor initializer %0 does not name a class", | ||
[ | [b]=n, | ||
[ | [j]="constructor initializer (.*?) does not name a class", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{w,4685,"MemInitResult Sema::BuildBaseInitializer(QualType BaseType, TypeSourceInfo *BaseTInfo, Expr *Init, CXXRecordDecl *ClassDecl, SourceLocation EllipsisLoc) {\n if (!BaseType->isDependentType() && !BaseType->isRecordType())\n return Diag(BaseLoc, diag::err_base_init_does_not_name_class) << BaseType << BaseTInfo->getTypeLoc().getSourceRange();"}}, | [k]={{w,4685,"MemInitResult Sema::BuildBaseInitializer(QualType BaseType, TypeSourceInfo *BaseTInfo, Expr *Init, CXXRecordDecl *ClassDecl, SourceLocation EllipsisLoc) {\n if (!BaseType->isDependentType() && !BaseType->isRecordType())\n return Diag(BaseLoc, diag::err_base_init_does_not_name_class) << BaseType << BaseTInfo->getTypeLoc().getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 6,368: | Line 6,388: | ||
}, | }, | ||
["err_base_must_be_class"]={ | ["err_base_must_be_class"]={ | ||
[e]="base specifier must name a class", | |||
[d]=l, | |||
[f]=m, | |||
[h]="base specifier must name a class", | [h]="base specifier must name a class", | ||
[ | [b]=n, | ||
[ | [j]="base specifier must name a class", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[ | |||
[ | |||
[k]={{w,2711,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n // Base specifiers must be record types.\n if (!BaseType->isRecordType()) {\n Diag(BaseLoc, diag::err_base_must_be_class) << SpecifierRange;"}}, | [k]={{w,2711,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n // Base specifiers must be record types.\n if (!BaseType->isRecordType()) {\n Diag(BaseLoc, diag::err_base_must_be_class) << SpecifierRange;"}}, | ||
[o]={ | [o]={ | ||
Line 6,383: | Line 6,403: | ||
}, | }, | ||
["err_base_specifier_attribute"]={ | ["err_base_specifier_attribute"]={ | ||
[ | [e]="A... cannot be applied to a base specifier", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0%select{ attribute|}1 cannot be applied to a base specifier", | ||
[ | [b]=n, | ||
[ | [j]="(.*?)(?: attribute|) cannot be applied to a base specifier", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"4c96e99235b3",1361317635,"PR15300: Support C++11 attributes on base-specifiers. We don\'t support any such","PR15300: Support C++11 attributes on base-specifiers. We don\'t support any such"}, | ||
[k]={{w,2827,"/// ActOnBaseSpecifier - Parsed a base specifier. A base specifier is\n/// one entry in the base class list of a class specifier, for\n/// example:\n/// class foo : public bar, virtual private baz {\n/// \'public bar\' and \'virtual private baz\' are each base-specifiers.\nBaseResult Sema::ActOnBaseSpecifier(Decl *classdecl, SourceRange SpecifierRange, const ParsedAttributesView &Attributes, bool Virtual, AccessSpecifier Access, ParsedType basetype, SourceLocation BaseLoc, SourceLocation EllipsisLoc) {\n // We do not support any C++11 attributes on base-specifiers yet.\n // Diagnose any attributes we see.\n for (const ParsedAttr &AL : Attributes) {\n if (AL.getKind() == ParsedAttr::UnknownAttribute)\n else\n Diag(AL.getLoc(), diag::err_base_specifier_attribute) << AL << AL.isRegularKeywordAttribute() << AL.getRange();"}}, | [k]={{w,2827,"/// ActOnBaseSpecifier - Parsed a base specifier. A base specifier is\n/// one entry in the base class list of a class specifier, for\n/// example:\n/// class foo : public bar, virtual private baz {\n/// \'public bar\' and \'virtual private baz\' are each base-specifiers.\nBaseResult Sema::ActOnBaseSpecifier(Decl *classdecl, SourceRange SpecifierRange, const ParsedAttributesView &Attributes, bool Virtual, AccessSpecifier Access, ParsedType basetype, SourceLocation BaseLoc, SourceLocation EllipsisLoc) {\n // We do not support any C++11 attributes on base-specifiers yet.\n // Diagnose any attributes we see.\n for (const ParsedAttr &AL : Attributes) {\n if (AL.getKind() == ParsedAttr::UnknownAttribute)\n else\n Diag(AL.getLoc(), diag::err_base_specifier_attribute) << AL << AL.isRegularKeywordAttribute() << AL.getRange();"}}, | ||
[o]={ | [o]={ | ||
Line 6,398: | Line 6,418: | ||
}, | }, | ||
["err_binding_cannot_appear_in_own_initializer"]={ | ["err_binding_cannot_appear_in_own_initializer"]={ | ||
[ | [e]="binding A cannot appear in the initializer of its own decomposition declaration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="binding %0 cannot appear in the initializer of its own decomposition declaration", | ||
[ | [b]=n, | ||
[ | [j]="binding (.*?) cannot appear in the initializer of its own decomposition declaration", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"bdb84f374cde",1469230619,"P0217R3: Parsing support and framework for AST representation of C++1z","P0217R3: Parsing support and framework for AST representation of C++1z"}, | ||
[k]={{ | [k]={{A,257,"/// Determine whether the use of this declaration is valid, and\n/// emit any corresponding diagnostics.\n///\n/// This routine diagnoses various problems with referencing\n/// declarations that can occur when using a declaration. For example,\n/// it might warn if a deprecated or unavailable declaration is being\n/// used, or produce an error (and return true) if a C++0x deleted\n/// function is being used.\n///\n/// \\returns true if there was an error (this declaration cannot be\n/// referenced), false otherwise.\n///\nbool Sema::DiagnoseUseOfDecl(NamedDecl *D, ArrayRef<SourceLocation> Locs, const ObjCInterfaceDecl *UnknownObjCClass, bool ObjCPropertyAccess, bool AvoidPartialAvailabilityChecks, ObjCInterfaceDecl *ClassReceiver, bool SkipTrailingRequiresClause) {\n // See if this is an auto-typed variable whose initializer we are parsing.\n if (ParsingInitForAutoVars.count(D)) {\n if (isa<BindingDecl>(D)) {\n Diag(Loc, diag::err_binding_cannot_appear_in_own_initializer) << D->getDeclName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/cxx1z-decomposition.cpp"]={"clang/test/SemaCXX/cxx1z-decomposition.cpp:5:14: error: binding \'a\' cannot appear in the initializer of its own decomposition declaration"} | ["clang/test/SemaCXX/cxx1z-decomposition.cpp"]={"clang/test/SemaCXX/cxx1z-decomposition.cpp:5:14: error: binding \'a\' cannot appear in the initializer of its own decomposition declaration"} | ||
Line 6,413: | Line 6,433: | ||
}, | }, | ||
["err_bit_cast_non_trivially_copyable"]={ | ["err_bit_cast_non_trivially_copyable"]={ | ||
[ | [e]="__builtin_bit_cast ... type must be trivially copyable", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="__builtin_bit_cast %select{source|destination}0 type must be trivially copyable", | ||
[ | [b]=n, | ||
[ | [j]="__builtin_bit_cast (?:source|destination) type must be trivially copyable", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"eee944e7f9e6",1562092093,"[C++2a] Add __builtin_bit_cast, used to implement std::bit_cast","[C++2a] Add __builtin_bit_cast, used to implement std::bit_cast"}, | ||
[k]={{x,3278,"void CastOperation::CheckBuiltinBitCast() {\n if (!DestType.isTriviallyCopyableType(Self.Context)) {\n Self.Diag(OpRange.getBegin(), diag::err_bit_cast_non_trivially_copyable) << 1;"},{x,3285,"void CastOperation::CheckBuiltinBitCast() {\n if (!SrcType.isTriviallyCopyableType(Self.Context)) {\n Self.Diag(OpRange.getBegin(), diag::err_bit_cast_non_trivially_copyable) << 0;"}}, | [k]={{x,3278,"void CastOperation::CheckBuiltinBitCast() {\n if (!DestType.isTriviallyCopyableType(Self.Context)) {\n Self.Diag(OpRange.getBegin(), diag::err_bit_cast_non_trivially_copyable) << 1;"},{x,3285,"void CastOperation::CheckBuiltinBitCast() {\n if (!SrcType.isTriviallyCopyableType(Self.Context)) {\n Self.Diag(OpRange.getBegin(), diag::err_bit_cast_non_trivially_copyable) << 0;"}}, | ||
[o]={ | [o]={ | ||
Line 6,428: | Line 6,448: | ||
}, | }, | ||
["err_bit_cast_type_size_mismatch"]={ | ["err_bit_cast_type_size_mismatch"]={ | ||
[ | [e]="__builtin_bit_cast source size does not equal destination size (A vs B)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="__builtin_bit_cast source size does not equal destination size (%0 vs %1)", | ||
[ | [b]=n, | ||
[ | [j]="__builtin_bit_cast source size does not equal destination size \\((.*?) vs (.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"eee944e7f9e6",1562092093,"[C++2a] Add __builtin_bit_cast, used to implement std::bit_cast","[C++2a] Add __builtin_bit_cast, used to implement std::bit_cast"}, | ||
[k]={{x,3271,"void CastOperation::CheckBuiltinBitCast() {\n if (DestSize != SourceSize) {\n Self.Diag(OpRange.getBegin(), diag::err_bit_cast_type_size_mismatch) << (int)SourceSize.getQuantity() << (int)DestSize.getQuantity();"}}, | [k]={{x,3271,"void CastOperation::CheckBuiltinBitCast() {\n if (DestSize != SourceSize) {\n Self.Diag(OpRange.getBegin(), diag::err_bit_cast_type_size_mismatch) << (int)SourceSize.getQuantity() << (int)DestSize.getQuantity();"}}, | ||
[o]={ | [o]={ | ||
Line 6,443: | Line 6,463: | ||
}, | }, | ||
["err_bit_int_bad_size"]={ | ["err_bit_int_bad_size"]={ | ||
[ | [e]="... _BitInt must have a bit size of at least ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{signed|unsigned}0 _BitInt must have a bit size of at least %select{2|1}0", | ||
[ | [b]=n, | ||
[ | [j]="(?:signed|unsigned) _BitInt must have a bit size of at least (?:2|1)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={yb,1616787805,S,S}, | ||
[k]={{ | [k]={{t,2359,"/// Build a bit-precise integer type.\n///\n/// \\param IsUnsigned Boolean representing the signedness of the type.\n///\n/// \\param BitWidth Size of this int type in bits, or an expression representing\n/// that.\n///\n/// \\param Loc Location of the keyword.\nQualType Sema::BuildBitIntType(bool IsUnsigned, Expr *BitWidth, SourceLocation Loc) {\n if (!IsUnsigned && NumBits < 2) {\n Diag(Loc, diag::err_bit_int_bad_size) << 0;"},{t,2364,"/// Build a bit-precise integer type.\n///\n/// \\param IsUnsigned Boolean representing the signedness of the type.\n///\n/// \\param BitWidth Size of this int type in bits, or an expression representing\n/// that.\n///\n/// \\param Loc Location of the keyword.\nQualType Sema::BuildBitIntType(bool IsUnsigned, Expr *BitWidth, SourceLocation Loc) {\n if (IsUnsigned && NumBits < 1) {\n Diag(Loc, diag::err_bit_int_bad_size) << 1;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/ext-int.cpp"]={"clang/test/SemaCXX/ext-int.cpp:21:3: error: signed _BitInt must have a bit size of at least 2","clang/test/SemaCXX/ext-int.cpp:22:3: error: signed _BitInt must have a bit size of at least 2","clang/test/SemaCXX/ext-int.cpp:24:3: error: unsigned _BitInt must have a bit size of at least 1","clang/test/SemaCXX/ext-int.cpp:26:3: error: signed _BitInt must have a bit size of at least 2","clang/test/SemaCXX/ext-int.cpp:5:3: error: signed _BitInt must have a bit size of at least 2","clang/test/SemaCXX/ext-int.cpp:6:12: error: unsigned _BitInt must have a bit size of at least 1","clang/test/SemaCXX/ext-int.cpp:5:3: error: signed _BitInt must have a bit size of at least 2"} | ["clang/test/SemaCXX/ext-int.cpp"]={"clang/test/SemaCXX/ext-int.cpp:21:3: error: signed _BitInt must have a bit size of at least 2","clang/test/SemaCXX/ext-int.cpp:22:3: error: signed _BitInt must have a bit size of at least 2","clang/test/SemaCXX/ext-int.cpp:24:3: error: unsigned _BitInt must have a bit size of at least 1","clang/test/SemaCXX/ext-int.cpp:26:3: error: signed _BitInt must have a bit size of at least 2","clang/test/SemaCXX/ext-int.cpp:5:3: error: signed _BitInt must have a bit size of at least 2","clang/test/SemaCXX/ext-int.cpp:6:12: error: unsigned _BitInt must have a bit size of at least 1","clang/test/SemaCXX/ext-int.cpp:5:3: error: signed _BitInt must have a bit size of at least 2"} | ||
Line 6,458: | Line 6,478: | ||
}, | }, | ||
["err_bit_int_max_size"]={ | ["err_bit_int_max_size"]={ | ||
[ | [e]="... _BitInt of bit sizes greater than A not supported", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{signed|unsigned}0 _BitInt of bit sizes greater than %1 not supported", | ||
[ | [b]=n, | ||
[ | [j]="(?:signed|unsigned) _BitInt of bit sizes greater than (.*?) not supported", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={yb,1616787805,S,S}, | ||
[k]={{ | [k]={{t,2370,"/// Build a bit-precise integer type.\n///\n/// \\param IsUnsigned Boolean representing the signedness of the type.\n///\n/// \\param BitWidth Size of this int type in bits, or an expression representing\n/// that.\n///\n/// \\param Loc Location of the keyword.\nQualType Sema::BuildBitIntType(bool IsUnsigned, Expr *BitWidth, SourceLocation Loc) {\n if (NumBits > TI.getMaxBitIntWidth()) {\n Diag(Loc, diag::err_bit_int_max_size) << IsUnsigned << static_cast<uint64_t>(TI.getMaxBitIntWidth());"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/large-bit-int.c"]={"clang/test/Sema/large-bit-int.c:9:3: error: signed _BitInt of bit sizes greater than 1024 not supported","clang/test/Sema/large-bit-int.c:10:3: error: unsigned _BitInt of bit sizes greater than 1024 not supported"} | ["clang/test/Sema/large-bit-int.c"]={"clang/test/Sema/large-bit-int.c:9:3: error: signed _BitInt of bit sizes greater than 1024 not supported","clang/test/Sema/large-bit-int.c:10:3: error: unsigned _BitInt of bit sizes greater than 1024 not supported"} | ||
Line 6,473: | Line 6,493: | ||
}, | }, | ||
["err_bitfield_has_negative_width"]={ | ["err_bitfield_has_negative_width"]={ | ||
[ | [e]="bit-field A has negative width (B)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="bit-field %0 has negative width (%1)", | ||
[ | [b]=n, | ||
[ | [j]="bit\\-field (.*?) has negative width \\((.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,17924,"// Note that FieldName may be null for anonymous bitfields.\nExprResult Sema::VerifyBitField(SourceLocation FieldLoc, IdentifierInfo *FieldName, QualType FieldTy, bool IsMsStruct, Expr *BitWidth) {\n if (Value.isSigned() && Value.isNegative()) {\n if (FieldName)\n return Diag(FieldLoc, diag::err_bitfield_has_negative_width) << FieldName << toString(Value, 10);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/class-bitfield.m"]={"clang/test/SemaObjC/class-bitfield.m:5:7: error: bit-field \'a\' has negative width (-1)"} | ["clang/test/SemaObjC/class-bitfield.m"]={"clang/test/SemaObjC/class-bitfield.m:5:7: error: bit-field \'a\' has negative width (-1)"} | ||
Line 6,488: | Line 6,508: | ||
}, | }, | ||
["err_bitfield_has_zero_width"]={ | ["err_bitfield_has_zero_width"]={ | ||
[ | [e]="named bit-field A has zero width", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="named bit-field %0 has zero width", | ||
[ | [b]=n, | ||
[ | [j]="named bit\\-field (.*?) has zero width", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,17920,"// Note that FieldName may be null for anonymous bitfields.\nExprResult Sema::VerifyBitField(SourceLocation FieldLoc, IdentifierInfo *FieldName, QualType FieldTy, bool IsMsStruct, Expr *BitWidth) {\n // Zero-width bitfield is ok for anonymous field.\n if (Value == 0 && FieldName)\n return Diag(FieldLoc, diag::err_bitfield_has_zero_width) << FieldName;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/class-bitfield.m"]={"clang/test/SemaObjC/class-bitfield.m:14:7: error: named bit-field \'e\' has zero width"} | ["clang/test/SemaObjC/class-bitfield.m"]={"clang/test/SemaObjC/class-bitfield.m:14:7: error: named bit-field \'e\' has zero width"} | ||
Line 6,503: | Line 6,523: | ||
}, | }, | ||
["err_bitfield_too_wide"]={ | ["err_bitfield_too_wide"]={ | ||
[ | [e]="... is too wide (A bits)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{bit-field %1|anonymous bit-field}0 is too wide (%2 bits)", | ||
[ | [b]=n, | ||
[ | [j]="(?:bit\\-field (.*?)|anonymous bit\\-field) is too wide \\((.*?) bits\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={sb,1590001902,T,T}, | ||
[k]={{ | [k]={{s,17933,"// Note that FieldName may be null for anonymous bitfields.\nExprResult Sema::VerifyBitField(SourceLocation FieldLoc, IdentifierInfo *FieldName, QualType FieldTy, bool IsMsStruct, Expr *BitWidth) {\n // The size of the bit-field must not exceed our maximum permitted object\n // size.\n if (Value.getActiveBits() > ConstantArrayType::getMaxSizeBits(Context)) {\n return Diag(FieldLoc, diag::err_bitfield_too_wide) << !FieldName << FieldName << toString(Value, 10);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/bitfield-layout.cpp"]={"clang/test/SemaCXX/bitfield-layout.cpp:45:8: error: bit-field \'c\' is too wide (18446744073709551617 bits)"} | ["clang/test/SemaCXX/bitfield-layout.cpp"]={"clang/test/SemaCXX/bitfield-layout.cpp:45:8: error: bit-field \'c\' is too wide (18446744073709551617 bits)"} | ||
Line 6,518: | Line 6,538: | ||
}, | }, | ||
["err_bitfield_width_exceeds_type_width"]={ | ["err_bitfield_width_exceeds_type_width"]={ | ||
[ | [e]="width of... bit-field... (A bits) exceeds the ... of its type (B bitC)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="width of%select{ anonymous|}0 bit-field%select{| %1}0 (%2 bits) exceeds the %select{width|size}3 of its type (%4 bit%s4)", | ||
[ | [b]=n, | ||
[ | [j]="width of(?: anonymous|) bit\\-field(?:| (.*?)) \\((.*?) bits\\) exceeds the (?:width|size) of its type \\((.*?) bit(.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"022bdc7d7361",1442266056,"C11 _Bool bitfield diagnostic","C11 _Bool bitfield diagnostic"}, | ||
[k]={{ | [k]={{s,17952,"// Note that FieldName may be null for anonymous bitfields.\nExprResult Sema::VerifyBitField(SourceLocation FieldLoc, IdentifierInfo *FieldName, QualType FieldTy, bool IsMsStruct, Expr *BitWidth) {\n if (!FieldTy->isDependentType()) {\n if (CStdConstraintViolation || MSBitfieldViolation) {\n return Diag(FieldLoc, diag::err_bitfield_width_exceeds_type_width) << (bool)FieldName << FieldName << toString(Value, 10) << !CStdConstraintViolation << DiagWidth;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/ext-int.c"]={"clang/test/Sema/ext-int.c:15:14: error: width of bit-field \'A\' (8 bits) exceeds the width of its type (4 bits)"} | ["clang/test/Sema/ext-int.c"]={"clang/test/Sema/ext-int.c:15:14: error: width of bit-field \'A\' (8 bits) exceeds the width of its type (4 bits)"} | ||
Line 6,533: | Line 6,553: | ||
}, | }, | ||
["err_block_decl_ref_not_modifiable_lvalue"]={ | ["err_block_decl_ref_not_modifiable_lvalue"]={ | ||
[e]="variable is not assignable (missing __block type specifier)", | |||
[d]=l, | |||
[f]=m, | |||
[h]="variable is not assignable (missing __block type specifier)", | [h]="variable is not assignable (missing __block type specifier)", | ||
[ | [b]=n, | ||
[ | [j]="variable is not assignable \\(missing __block type specifier\\)", | ||
[c]=a, | |||
[i]=p, | |||
[g]={v,1237025389,r,r}, | |||
[ | [k]={{A,14282,"/// CheckForModifiableLvalue - Verify that E is a modifiable lvalue. If not,\n/// emit an error and return true. If so, return false.\nstatic bool CheckForModifiableLvalue(Expr *E, SourceLocation Loc, Sema &S) {\n case Expr::MLV_ConstQualified:\n // Use a specialized diagnostic when we\'re assigning to an object\n // from an enclosing function or block.\n if (NonConstCaptureKind NCCK = isReferenceToNonConstCapture(S, E)) {\n if (NCCK == NCCK_Block)\n DiagID = diag::err_block_decl_ref_not_modifiable_lvalue;"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/instantiate-blocks.cpp"]={"clang/test/SemaCXX/instantiate-blocks.cpp:11:20: error: variable is not assignable (missing __block type specifier)"} | ["clang/test/SemaCXX/instantiate-blocks.cpp"]={"clang/test/SemaCXX/instantiate-blocks.cpp:11:20: error: variable is not assignable (missing __block type specifier)"} | ||
Line 6,548: | Line 6,568: | ||
}, | }, | ||
["err_block_extern_cant_init"]={ | ["err_block_extern_cant_init"]={ | ||
[e]="declaration of block scope identifier with linkage cannot have an initializer", | |||
[d]=l, | |||
[f]=m, | |||
[h]="declaration of block scope identifier with linkage cannot have an initializer", | [h]="declaration of block scope identifier with linkage cannot have an initializer", | ||
[ | [b]=n, | ||
[ | [j]="declaration of block scope identifier with linkage cannot have an initializer", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{s,13189,"/// 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 // C99 6.7.8p5. If the declaration of an identifier has block scope, and\n // the identifier has external or internal linkage, the declaration shall\n // have no initializer for the identifier.\n // C++14 [dcl.init]p5 is the same restriction for C++.\n if (VDecl->isLocalVarDecl() && VDecl->hasExternalStorage()) {\n Diag(VDecl->getLocation(), diag::err_block_extern_cant_init);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/err-decl-block-extern-no-init.c"]={"clang/test/Sema/err-decl-block-extern-no-init.c:6:16: error: declaration of block scope identifier with linkage cannot have an initializer","clang/test/Sema/err-decl-block-extern-no-init.c:13:16: error: declaration of block scope identifier with linkage cannot have an initializer"} | ["clang/test/Sema/err-decl-block-extern-no-init.c"]={"clang/test/Sema/err-decl-block-extern-no-init.c:6:16: error: declaration of block scope identifier with linkage cannot have an initializer","clang/test/Sema/err-decl-block-extern-no-init.c:13:16: error: declaration of block scope identifier with linkage cannot have an initializer"} | ||
Line 6,563: | Line 6,583: | ||
}, | }, | ||
["err_block_on_nonlocal"]={ | ["err_block_on_nonlocal"]={ | ||
[e]="__block attribute not allowed, only allowed on local variables", | |||
[d]=l, | |||
[f]=m, | |||
[h]="__block attribute not allowed, only allowed on local variables", | [h]="__block attribute not allowed, only allowed on local variables", | ||
[ | [b]=n, | ||
[ | [j]="__block attribute not allowed, only allowed on local variables", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"e9efa80c003e",1241050780,"Sema checking for incorrect placement of __block. Radar 6441502","Sema checking for incorrect placement of __block. Radar 6441502"}, | |||
[k]={{s,8742,"void Sema::CheckVariableDeclarationType(VarDecl *NewVD) {\n if (!NewVD->hasLocalStorage() && NewVD->hasAttr<BlocksAttr>()) {\n Diag(NewVD->getLocation(), diag::err_block_on_nonlocal);"},{s,14821,"/// ActOnParamDeclarator - Called from Parser::ParseFunctionDeclarator()\n/// to introduce parameters into function prototype scope.\nDecl *Sema::ActOnParamDeclarator(Scope *S, Declarator &D) {\n if (New->hasAttr<BlocksAttr>()) {\n Diag(New->getLocation(), diag::err_block_on_nonlocal);"},{O,4813,"Decl *Sema::ActOnMethodDeclaration(Scope *S, SourceLocation MethodLoc, SourceLocation EndLoc, tok::TokenKind MethodType, ObjCDeclSpec &ReturnQT, ParsedType ReturnType, ArrayRef<SourceLocation> SelectorLocs, Selector Sel,\n for (unsigned i = 0, e = Sel.getNumArgs(); i != e; ++i) {\n if (Param->hasAttr<BlocksAttr>()) {\n Diag(Param->getLocation(), diag::err_block_on_nonlocal);"},{O,5239,"Decl *Sema::ActOnObjCExceptionDecl(Scope *S, Declarator &D) {\n if (New->hasAttr<BlocksAttr>())\n Diag(New->getLocation(), diag::err_block_on_nonlocal);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/block-misc.c"]={"clang/test/Sema/block-misc.c:150:13: error: __block attribute not allowed, only allowed on local variables","clang/test/Sema/block-misc.c:152:25: error: __block attribute not allowed, only allowed on local variables","clang/test/Sema/block-misc.c:154:25: error: __block attribute not allowed, only allowed on local variables","clang/test/Sema/block-misc.c:155:25: error: __block attribute not allowed, only allowed on local variables"} | ["clang/test/Sema/block-misc.c"]={"clang/test/Sema/block-misc.c:150:13: error: __block attribute not allowed, only allowed on local variables","clang/test/Sema/block-misc.c:152:25: error: __block attribute not allowed, only allowed on local variables","clang/test/Sema/block-misc.c:154:25: error: __block attribute not allowed, only allowed on local variables","clang/test/Sema/block-misc.c:155:25: error: __block attribute not allowed, only allowed on local variables"} | ||
Line 6,578: | Line 6,598: | ||
}, | }, | ||
["err_block_on_vm"]={ | ["err_block_on_vm"]={ | ||
[e]="__block attribute not allowed on declaration with a variably modified type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="__block attribute not allowed on declaration with a variably modified type", | [h]="__block attribute not allowed on declaration with a variably modified type", | ||
[ | [b]=n, | ||
[ | [j]="__block attribute not allowed on declaration with a variably modified type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"a71286315f9d",1241221307,"Add Sema checking for __block on vm declarations. Radar 6441502","Add Sema checking for __block on vm declarations. Radar 6441502"}, | |||
[k]={{s,8755,"void Sema::CheckVariableDeclarationType(VarDecl *NewVD) {\n if (isVM && NewVD->hasAttr<BlocksAttr>()) {\n Diag(NewVD->getLocation(), diag::err_block_on_vm);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/block-misc.c"]={"clang/test/Sema/block-misc.c:156:15: error: __block attribute not allowed on declaration with a variably modified type","clang/test/Sema/block-misc.c:157:17: error: __block attribute not allowed on declaration with a variably modified type"} | ["clang/test/Sema/block-misc.c"]={"clang/test/Sema/block-misc.c:156:15: error: __block attribute not allowed on declaration with a variably modified type","clang/test/Sema/block-misc.c:157:17: error: __block attribute not allowed on declaration with a variably modified type"} | ||
Line 6,593: | Line 6,613: | ||
}, | }, | ||
["err_block_return_missing_expr"]={ | ["err_block_return_missing_expr"]={ | ||
[e]="non-void block should return a value", | |||
[d]=l, | |||
[f]=m, | |||
[h]="non-void block should return a value", | [h]="non-void block should return a value", | ||
[ | [b]=n, | ||
[ | [j]="non\\-void block should return a value", | ||
[c]=a, | |||
[i]=p, | |||
[g]={v,1237025389,r,r}, | |||
[ | [k]={{bb,3693,"/// ActOnCapScopeReturnStmt - Utility routine to type-check return statements\n/// for capturing scopes.\n///\nStmtResult Sema::ActOnCapScopeReturnStmt(SourceLocation ReturnLoc, Expr *RetValExp, NamedReturnInfo &NRInfo, bool SupressSimplerImplicitMoves) {\n // Otherwise, verify that this result type matches the previous one. We are\n // pickier with blocks than for normal functions because we don\'t have GCC\n // compatibility to worry about here.\n if (FnRetType->isDependentType()) {\n } else if (FnRetType->isVoidType()) {\n } else if (!RetValExp) {\n return StmtError(Diag(ReturnLoc, diag::err_block_return_missing_expr));"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_block_returning_array_function"]={ | ["err_block_returning_array_function"]={ | ||
[ | [e]="block cannot return ... type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="block cannot return %select{array|function}0 type %1", | ||
[ | [b]=n, | ||
[ | [j]="block cannot return (?:array|function) type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"20ad245e3e22",1295997393,"Change error \"function cannot return array type\" -> \"blocks cannot return array type\" when blocks ar...","Change error \"function cannot return array type\" -> \"blocks cannot return array type\" when blocks are involved."}, | ||
[k]={{ | [k]={{A,21269,"/// Rebuilds a call expression which yielded __unknown_anytype.\nExprResult RebuildUnknownAnyExpr::VisitCallExpr(CallExpr *E) {\n // Verify that this is a legal result type of a function.\n if (DestType->isArrayType() || DestType->isFunctionType()) {\n if (Kind == FK_BlockPointer)\n diagID = diag::err_block_returning_array_function;"},{t,5272,"static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, QualType declSpecType, TypeSourceInfo *TInfo) {\n for (unsigned i = 0, e = D.getNumTypeObjects(); i != e; ++i) {\n case DeclaratorChunk::Function: {\n // C99 6.7.5.3p1: The return type may not be a function or array type.\n // For conversion functions, we\'ll diagnose this particular error later.\n if (!D.isInvalidType() && (T->isArrayType() || T->isFunctionType()) && (D.getName().getKind() != UnqualifiedIdKind::IK_ConversionFunctionId)) {\n // Last processing chunk in block context means this function chunk\n // represents the block.\n if (chunkIndex == 0 && D.getContext() == DeclaratorContext::BlockLiteral)\n diagID = diag::err_block_returning_array_function;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/block-return.c"]={"clang/test/Sema/block-return.c:101:19: error: block cannot return array type \'int (*[5])(long)\'"} | ["clang/test/Sema/block-return.c"]={"clang/test/Sema/block-return.c:101:19: error: block cannot return array type \'int (*[5])(long)\'"} | ||
Line 6,620: | Line 6,640: | ||
}, | }, | ||
["err_blocks_disable"]={ | ["err_blocks_disable"]={ | ||
[ | [e]="blocks support disabled - compile with -fblocks or ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="blocks support disabled - compile with -fblocks or %select{pick a deployment target that supports them|for OpenCL C 2.0 or OpenCL C 3.0 with __opencl_c_device_enqueue feature}0", | ||
[ | [b]=n, | ||
[ | [j]="blocks support disabled \\- compile with \\-fblocks or (?:pick a deployment target that supports them|for OpenCL C 2\\.0 or OpenCL C 3\\.0 with __opencl_c_device_enqueue feature)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"9eac931b5f29",1238127486,"Fix rdar://6719156 - clang should emit a better error when blocks are disabled but are used anyway","Fix rdar://6719156 - clang should emit a better error when blocks are disabled but are used anyway"}, | ||
[k]={{ | [k]={{A,17158,"/// ActOnBlockStmtExpr - This is called when the body of a block statement\n/// literal was successfully completed. ^(int x){...}\nExprResult Sema::ActOnBlockStmtExpr(SourceLocation CaretLoc, Stmt *Body, Scope *CurScope) {\n // If blocks are disabled, emit an error.\n if (!LangOpts.Blocks)\n Diag(CaretLoc, diag::err_blocks_disable) << LangOpts.OpenCL;"},{t,5034,"static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state, QualType declSpecType, TypeSourceInfo *TInfo) {\n for (unsigned i = 0, e = D.getNumTypeObjects(); i != e; ++i) {\n case DeclaratorChunk::BlockPointer:\n // If blocks are disabled, emit an error.\n if (!LangOpts.Blocks)\n S.Diag(DeclType.Loc, diag::err_blocks_disable) << LangOpts.OpenCL;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/exprs.c"]={"clang/test/Sema/exprs.c:131:19: error: blocks support disabled - compile with -fblocks or pick a deployment target that supports them","clang/test/Sema/exprs.c:133:7: error: blocks support disabled - compile with -fblocks or pick a deployment target that supports them"} | ["clang/test/Sema/exprs.c"]={"clang/test/Sema/exprs.c:131:19: error: blocks support disabled - compile with -fblocks or pick a deployment target that supports them","clang/test/Sema/exprs.c:133:7: error: blocks support disabled - compile with -fblocks or pick a deployment target that supports them"} | ||
Line 6,635: | Line 6,655: | ||
}, | }, | ||
["err_bool_redeclaration"]={ | ["err_bool_redeclaration"]={ | ||
[e]="redeclaration of C++ built-in type \'bool\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="redeclaration of C++ built-in type \'bool\'", | [h]="redeclaration of C++ built-in type \'bool\'", | ||
[ | [b]=n, | ||
[ | [j]="redeclaration of C\\+\\+ built\\-in type \'bool\'", | ||
[c]=a, | |||
[i]=D, | |||
[g]={"20ee5ae8710a",1289931493,"Emit a specific diagnostic when typedefing C++ bool, mirroring gcc.","Emit a specific diagnostic when typedefing C++ bool, mirroring gcc."}, | |||
[ | [k]={{H,4255,"/// 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 while (true) {\n case tok::kw__Bool:\n if (Tok.is(tok::kw_bool) && DS.getTypeSpecType() != DeclSpec::TST_unspecified && DS.getStorageClassSpec() == DeclSpec::SCS_typedef) {\n DiagID = diag::err_bool_redeclaration;"},{H,4500,"#include \"clang/Basic/TransformTypeTraits.def\"\n if (DiagID != diag::err_bool_redeclaration && ConsumedEnd.isInvalid())"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/cxx-decl.cpp"]={"clang/test/Parser/cxx-decl.cpp:17:14: error: redeclaration of C++ built-in type \'bool\'"} | ["clang/test/Parser/cxx-decl.cpp"]={"clang/test/Parser/cxx-decl.cpp:17:14: error: redeclaration of C++ built-in type \'bool\'"} | ||
Line 6,650: | Line 6,670: | ||
}, | }, | ||
["err_bound_member_function"]={ | ["err_bound_member_function"]={ | ||
[ | [e]="reference to non-static member function must be called...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="reference to non-static member function must be called%select{|; did you mean to call it with no arguments?}0", | ||
[ | [b]=n, | ||
[ | [j]="reference to non\\-static member function must be called(?:|; did you mean to call it with no arguments\\?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"50a2c2c19de5",1318374870,"Catch placeholder types in DefaultLvalueConversion","Catch placeholder types in DefaultLvalueConversion"}, | ||
[k]={{ | [k]={{A,21549,"/// Check for operands with placeholder types and complain if found.\n/// Returns ExprError() if there was an error and no recovery was possible.\nExprResult Sema::CheckPlaceholderExpr(Expr *E) {\n // Bound member functions.\n case BuiltinType::BoundMember: {\n PartialDiagnostic PD = PDiag(diag::err_bound_member_function);"},{ab,12958,"// Resolve and fix an overloaded expression that can be resolved\n// because it identifies a single function template specialization.\n//\n// Last three arguments should only be supplied if Complain = true\n//\n// Return true if it was logically possible to so resolve the\n// expression, regardless of whether or not it succeeded. Always\n// returns true if \'complain\' is set.\nbool Sema::ResolveAndFixSingleFunctionTemplateSpecialization(ExprResult &SrcExpr, bool doFunctionPointerConversion, bool complain, SourceRange OpRangeForComplaining, QualType DestTypeForComplaining, unsigned DiagIDForComplaining) {\n if (FunctionDecl *fn = ResolveSingleFunctionTemplateSpecialization(ovl.Expression, /*complain*/ false, &found)) {\n // It is only correct to resolve to an instance method if we\'re\n // resolving a form that\'s permitted to be a pointer to member.\n // Otherwise we\'ll end up making a bound member expression, which\n // is illegal in all the contexts we resolve like this.\n if (!ovl.HasFormOfMemberPointer && isa<CXXMethodDecl>(fn) && cast<CXXMethodDecl>(fn)->isInstance()) {\n Diag(ovl.Expression->getExprLoc(), diag::err_bound_member_function) << 0 << ovl.Expression->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/overloaded-name.cpp"]={"clang/test/SemaCXX/overloaded-name.cpp:25:9: error: reference to non-static member function must be called; did you mean to call it with no arguments?","clang/test/SemaCXX/overloaded-name.cpp:27:9: error: reference to non-static member function must be called; did you mean to call it with no arguments?"} | ["clang/test/SemaCXX/overloaded-name.cpp"]={"clang/test/SemaCXX/overloaded-name.cpp:25:9: error: reference to non-static member function must be called; did you mean to call it with no arguments?","clang/test/SemaCXX/overloaded-name.cpp:27:9: error: reference to non-static member function must be called; did you mean to call it with no arguments?"} | ||
Line 6,665: | Line 6,685: | ||
}, | }, | ||
["err_box_literal_collection"]={ | ["err_box_literal_collection"]={ | ||
[ | [e]="... literal must be prefixed by \'@\' in a collection", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{string|character|boolean|numeric}0 literal must be prefixed by \'@\' in a collection", | ||
[ | [b]=n, | ||
[ | [j]="(?:string|character|boolean|numeric) literal must be prefixed by \'@\' in a collection", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e65b086e07a6",1331064356,"Add clang support for new Objective-C literal syntax for NSDictionary, NSArray,","Add clang support for new Objective-C literal syntax for NSDictionary, NSArray,"}, | ||
[k]={{ | [k]={{M,438,"/// Check that the given expression is a valid element of an Objective-C\n/// collection literal.\nstatic ExprResult CheckObjCCollectionLiteralElement(Sema &S, Expr *Element, QualType T, bool ArrayLiteral = false) {\n // Make sure that we have an Objective-C pointer type or block.\n if (!Element->getType()->isObjCObjectPointerType() && !Element->getType()->isBlockPointerType()) {\n // If this is potentially an Objective-C numeric literal, add the \'@\'.\n if (isa<IntegerLiteral>(OrigElement) || isa<CharacterLiteral>(OrigElement) || isa<FloatingLiteral>(OrigElement) || isa<ObjCBoolLiteralExpr>(OrigElement) || isa<CXXBoolLiteralExpr>(OrigElement)) {\n if (S.NSAPIObj->getNSNumberFactoryMethodKind(OrigElement->getType())) {\n S.Diag(OrigElement->getBeginLoc(), diag::err_box_literal_collection) << Which << OrigElement->getSourceRange() << FixItHint::CreateInsertion(OrigElement->getBeginLoc(), \"@\");"},{M,454,"/// Check that the given expression is a valid element of an Objective-C\n/// collection literal.\nstatic ExprResult CheckObjCCollectionLiteralElement(Sema &S, Expr *Element, QualType T, bool ArrayLiteral = false) {\n // Make sure that we have an Objective-C pointer type or block.\n if (!Element->getType()->isObjCObjectPointerType() && !Element->getType()->isBlockPointerType()) {\n }\n // If this is potentially an Objective-C string literal, add the \'@\'.\n else if (StringLiteral *String = dyn_cast<StringLiteral>(OrigElement)) {\n if (String->isOrdinary()) {\n S.Diag(OrigElement->getBeginLoc(), diag::err_box_literal_collection) << 0 << OrigElement->getSourceRange() << FixItHint::CreateInsertion(OrigElement->getBeginLoc(), \"@\");"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/objc-array-literal.m"]={"clang/test/SemaObjC/objc-array-literal.m:51:23: error: string literal must be prefixed by \'@\' in a collection"} | ["clang/test/SemaObjC/objc-array-literal.m"]={"clang/test/SemaObjC/objc-array-literal.m:51:23: error: string literal must be prefixed by \'@\' in a collection"} | ||
Line 6,680: | Line 6,700: | ||
}, | }, | ||
["err_bracket_depth_exceeded"]={ | ["err_bracket_depth_exceeded"]={ | ||
[ | [e]="bracket nesting level exceeded maximum of A", | ||
[ | [d]=kc, | ||
[ | [f]=mc, | ||
[ | [h]="bracket nesting level exceeded maximum of %0", | ||
[ | [b]=jc, | ||
[ | [j]="bracket nesting level exceeded maximum of (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"b3a145293dc8",1361498391,"Add -fbracket-depth=N, analogous to -ftemplate-depth= and -fconstexpr-depth=,","Add -fbracket-depth=N, analogous to -ftemplate-depth= and -fconstexpr-depth=,"}, | ||
[k]={{ | [k]={{lc,2696,"bool BalancedDelimiterTracker::diagnoseOverflow() {\n P.Diag(P.Tok, diag::err_bracket_depth_exceeded) << P.getLangOpts().BracketDepth;"}} | ||
}, | }, | ||
["err_brackets_go_after_unqualified_id"]={ | ["err_brackets_go_after_unqualified_id"]={ | ||
[ | [e]="brackets are not allowed here; to declare an array, place the brackets after the ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="brackets are not allowed here; to declare an array, place the brackets after the %select{identifier|name}0", | ||
[ | [b]=n, | ||
[ | [j]="brackets are not allowed here; to declare an array, place the brackets after the (?:identifier|name)", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"f4b81d002965",1403651664,"Provide a better diagnostic when braces are put before the identifier.","Provide a better diagnostic when braces are put before the identifier."}, | ||
[k]={{ | [k]={{H,7725,"/// Diagnose brackets before an identifier.\nvoid Parser::ParseMisplacedBracketDeclarator(Declarator &D) {\n if (NeedParens) {\n Diag(EndLoc, diag::err_brackets_go_after_unqualified_id) << getLangOpts().CPlusPlus << FixItHint::CreateInsertion(SuggestParenLoc, \"(\") << FixItHint::CreateInsertion(EndLoc, \")\") << FixItHint::CreateInsertionFromRange(EndLoc, CharSourceRange(BracketRange, true)) << FixItHint::CreateRemoval(BracketRange);"},{H,7733,"/// Diagnose brackets before an identifier.\nvoid Parser::ParseMisplacedBracketDeclarator(Declarator &D) {\n if (NeedParens) {\n } else {\n Diag(EndLoc, diag::err_brackets_go_after_unqualified_id) << getLangOpts().CPlusPlus << FixItHint::CreateInsertionFromRange(EndLoc, CharSourceRange(BracketRange, true)) << FixItHint::CreateRemoval(BracketRange);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Parser/cxx1z-decomposition.cpp"]={"clang/test/Parser/cxx1z-decomposition.cpp:109:16: error: brackets are not allowed here; to declare an array, place the brackets after the name"} | ["clang/test/Parser/cxx1z-decomposition.cpp"]={"clang/test/Parser/cxx1z-decomposition.cpp:109:16: error: brackets are not allowed here; to declare an array, place the brackets after the name"} | ||
Line 6,707: | Line 6,727: | ||
}, | }, | ||
["err_break_not_in_loop_or_switch"]={ | ["err_break_not_in_loop_or_switch"]={ | ||
[e]="\'break\' statement not in loop or switch statement", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'break\' statement not in loop or switch statement", | [h]="\'break\' statement not in loop or switch statement", | ||
[ | [b]=n, | ||
[ | [j]="\'break\' statement not in loop or switch statement", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{bb,3349,"StmtResult Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope *CurScope) {\n if (!S) {\n return StmtError(Diag(BreakLoc, diag::err_break_not_in_loop_or_switch));"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/block-misc.c"]={"clang/test/Sema/block-misc.c:108:8: error: \'break\' statement not in loop or switch statement","clang/test/Sema/block-misc.c:112:8: error: \'break\' statement not in loop or switch statement"} | ["clang/test/Sema/block-misc.c"]={"clang/test/Sema/block-misc.c:108:8: error: \'break\' statement not in loop or switch statement","clang/test/Sema/block-misc.c:112:8: error: \'break\' statement not in loop or switch statement"} | ||
Line 6,722: | Line 6,742: | ||
}, | }, | ||
["err_btf_type_id_not_const"]={ | ["err_btf_type_id_not_const"]={ | ||
[ | [e]="__builtin_btf_type_id argument A not a constant", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="__builtin_btf_type_id argument %0 not a constant", | ||
[ | [b]=n, | ||
[ | [j]="__builtin_btf_type_id argument (.*?) not a constant", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={ib,1576908663,K,K}, | ||
[k]={{ | [k]={{u,3514,"bool Sema::CheckBPFBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) {\n if (!Value) {\n if (BuiltinID == BPF::BI__builtin_preserve_field_info)\n else if (BuiltinID == BPF::BI__builtin_btf_type_id)\n kind = diag::err_btf_type_id_not_const;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/builtin-bpf-btf-type-id.c"]={"clang/test/Sema/builtin-bpf-btf-type-id.c:8:59: error: __builtin_btf_type_id argument 2 not a constant"} | ["clang/test/Sema/builtin-bpf-btf-type-id.c"]={"clang/test/Sema/builtin-bpf-btf-type-id.c:8:59: error: __builtin_btf_type_id argument 2 not a constant"} | ||
Line 6,737: | Line 6,757: | ||
}, | }, | ||
["err_builtin_annotation_first_arg"]={ | ["err_builtin_annotation_first_arg"]={ | ||
[e]="first argument to __builtin_annotation must be an integer", | |||
[d]=l, | |||
[f]=m, | |||
[h]="first argument to __builtin_annotation must be an integer", | [h]="first argument to __builtin_annotation must be an integer", | ||
[ | [b]=n, | ||
[ | [j]="first argument to __builtin_annotation must be an integer", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"4a5b4443711e",1335634756,"Currently __builtin_annotation() only annotates an i32.","Currently __builtin_annotation() only annotates an i32."}, | |||
[k]={{u,198,"/// Check that the first argument to __builtin_annotation is an integer\n/// and the second argument is a non-wide string literal.\nstatic bool SemaBuiltinAnnotation(Sema &S, CallExpr *TheCall) {\n if (!Ty->isIntegerType()) {\n S.Diag(ValArg->getBeginLoc(), diag::err_builtin_annotation_first_arg) << ValArg->getSourceRange();"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/annotate.c"]={"clang/test/Sema/annotate.c:14:34: error: first argument to __builtin_annotation must be an integer"} | ["clang/test/Sema/annotate.c"]={"clang/test/Sema/annotate.c:14:34: error: first argument to __builtin_annotation must be an integer"} | ||
Line 6,752: | Line 6,772: | ||
}, | }, | ||
["err_builtin_annotation_second_arg"]={ | ["err_builtin_annotation_second_arg"]={ | ||
[e]="second argument to __builtin_annotation must be a non-wide string constant", | |||
[d]=l, | |||
[f]=m, | |||
[h]="second argument to __builtin_annotation must be a non-wide string constant", | [h]="second argument to __builtin_annotation must be a non-wide string constant", | ||
[ | [b]=n, | ||
[ | [j]="second argument to __builtin_annotation must be a non\\-wide string constant", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"4a5b4443711e",1335634756,"Currently __builtin_annotation() only annotates an i32.","Currently __builtin_annotation() only annotates an i32."}, | |||
[ | [k]={{u,207,"/// Check that the first argument to __builtin_annotation is an integer\n/// and the second argument is a non-wide string literal.\nstatic bool SemaBuiltinAnnotation(Sema &S, CallExpr *TheCall) {\n if (!Literal || !Literal->isOrdinary()) {\n S.Diag(StrArg->getBeginLoc(), diag::err_builtin_annotation_second_arg) << StrArg->getSourceRange();"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/annotate.c"]={"clang/test/Sema/annotate.c:11:43: error: second argument to __builtin_annotation must be a non-wide string constant","clang/test/Sema/annotate.c:12:43: error: second argument to __builtin_annotation must be a non-wide string constant"} | ["clang/test/Sema/annotate.c"]={"clang/test/Sema/annotate.c:11:43: error: second argument to __builtin_annotation must be a non-wide string constant","clang/test/Sema/annotate.c:12:43: error: second argument to __builtin_annotation must be a non-wide string constant"} | ||
Line 6,767: | Line 6,787: | ||
}, | }, | ||
["err_builtin_definition"]={ | ["err_builtin_definition"]={ | ||
[ | [e]="definition of builtin function A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="definition of builtin function %0", | ||
[ | [b]=n, | ||
[ | [j]="definition of builtin function (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{s,15334,"Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D, SkipBodyInfo *SkipBody, FnBodyKind BodyKind) {\n // Builtin functions cannot be defined.\n if (unsigned BuiltinID = FD->getBuiltinID()) {\n if (!Context.BuiltinInfo.isPredefinedLibFunction(BuiltinID) && !Context.BuiltinInfo.isPredefinedRuntimeFunction(BuiltinID)) {\n Diag(FD->getLocation(), diag::err_builtin_definition) << FD;"}} | ||
}, | }, | ||
["err_builtin_fn_use"]={ | ["err_builtin_fn_use"]={ | ||
[e]="builtin functions must be directly called", | |||
[d]=l, | |||
[f]=m, | |||
[h]="builtin functions must be directly called", | [h]="builtin functions must be directly called", | ||
[ | [b]=n, | ||
[ | [j]="builtin functions must be directly called", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"34866c7719f8",1346372047,"Change the representation of builtin functions in the AST","Change the representation of builtin functions in the AST"}, | |||
[k]={{A,21629,"/// Check for operands with placeholder types and complain if found.\n/// Returns ExprError() if there was an error and no recovery was possible.\nExprResult Sema::CheckPlaceholderExpr(Expr *E) {\n case BuiltinType::BuiltinFn: {\n Diag(E->getBeginLoc(), diag::err_builtin_fn_use);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/builtin_classify_type.c"]={"clang/test/Parser/builtin_classify_type.c:13:21: error: builtin functions must be directly called"} | ["clang/test/Parser/builtin_classify_type.c"]={"clang/test/Parser/builtin_classify_type.c:13:21: error: builtin functions must be directly called"} | ||
Line 6,794: | Line 6,814: | ||
}, | }, | ||
["err_builtin_func_cast_more_than_one_arg"]={ | ["err_builtin_func_cast_more_than_one_arg"]={ | ||
[e]="function-style cast to a builtin type can only take one argument", | |||
[d]=l, | |||
[f]=m, | |||
[h]="function-style cast to a builtin type can only take one argument", | [h]="function-style cast to a builtin type can only take one argument", | ||
[ | [b]=n, | ||
[ | [j]="function\\-style cast to a builtin type can only take one argument", | ||
[c]=a, | |||
[i]=p, | |||
[g]={v,1237025389,r,r}, | |||
[ | [k]={{L,9814,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n case FK_TooManyInitsForScalar: {\n if (Kind.isCStyleOrFunctionalCast())\n S.Diag(Kind.getLocation(), diag::err_builtin_func_cast_more_than_one_arg) << R;"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_builtin_invalid_arg_type"]={ | ["err_builtin_invalid_arg_type"]={ | ||
[ | [e]="A argument must be a ... (was B)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%ordinal0 argument must be a %select{vector, integer or floating point type|matrix|pointer to a valid matrix element type|signed integer or floating point type|vector type|floating point type|vector of integers}1 (was %2)", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) argument must be a (?:vector, integer or floating point type|matrix|pointer to a valid matrix element type|signed integer or floating point type|vector type|floating point type|vector of integers) \\(was (.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={yb,1616787805,S,S}, | ||
[k]={{ | [k]={{u,2045,"// Check if \\p Ty is a valid type for the elementwise math builtins. If it is\n// not a valid type, emit an error message and return true. Otherwise return\n// false.\nstatic bool checkMathBuiltinElementType(Sema &S, SourceLocation Loc, QualType Ty) {\n if (!Ty->getAs<VectorType>() && !ConstantMatrixType::isValidElementType(Ty)) {\n return S.Diag(Loc, diag::err_builtin_invalid_arg_type) << 1 << /* vector, integer or float ty*/ 0 << Ty;"},{u,2059,"static bool checkFPMathBuiltinElementType(Sema &S, SourceLocation Loc, QualType ArgTy, int ArgIndex) {\n if (!EltTy->isRealFloatingType()) {\n return S.Diag(Loc, diag::err_builtin_invalid_arg_type) << ArgIndex << /* vector or float ty*/ 5 << ArgTy;"},{u,2623,"#include \"clang/Basic/Builtins.def\"\n // __builtin_elementwise_abs restricts the element type to signed integers or\n // floating point types only.\n case Builtin::BI__builtin_elementwise_abs: {\n if (EltTy->isUnsignedIntegerType()) {\n Diag(TheCall->getArg(0)->getBeginLoc(), diag::err_builtin_invalid_arg_type) << 1 << /* signed integer or float ty*/ 3 << ArgTy;"},{u,2692,"#include \"clang/Basic/Builtins.def\"\n case Builtin::BI__builtin_elementwise_sub_sat: {\n if (!EltTy->isIntegerType()) {\n Diag(Arg->getBeginLoc(), diag::err_builtin_invalid_arg_type) << 1 << /* integer ty */ 6 << ArgTy;"},{u,2741,"#include \"clang/Basic/Builtins.def\"\n case Builtin::BI__builtin_reduce_min: {\n if (!TyA) {\n Diag(Arg->getBeginLoc(), diag::err_builtin_invalid_arg_type) << 1 << /* vector ty*/ 4 << Arg->getType();"},{u,2763,"#include \"clang/Basic/Builtins.def\"\n case Builtin::BI__builtin_reduce_and: {\n if (!TyA || !TyA->getElementType()->isIntegerType()) {\n Diag(Arg->getBeginLoc(), diag::err_builtin_invalid_arg_type) << 1 << /* vector of integers */ 6 << Arg->getType();"},{u,18725,"bool Sema::SemaBuiltinNonDeterministicValue(CallExpr *TheCall) {\n if (!TyArg->isBuiltinType() && !TyArg->isVectorType())\n return Diag(TheCall->getArg(0)->getBeginLoc(), diag::err_builtin_invalid_arg_type) << 1 << /*vector, integer or floating point ty*/ 0 << TyArg;"},{u,18744,"ExprResult Sema::SemaBuiltinMatrixTranspose(CallExpr *TheCall, ExprResult CallResult) {\n if (!MType) {\n Diag(Matrix->getBeginLoc(), diag::err_builtin_invalid_arg_type) << 1 << /* matrix ty*/ 1 << Matrix->getType();"},{u,18816,"ExprResult Sema::SemaBuiltinMatrixColumnMajorLoad(CallExpr *TheCall, ExprResult CallResult) {\n if (!PtrTy) {\n Diag(PtrExpr->getBeginLoc(), diag::err_builtin_invalid_arg_type) << PtrArgIdx + 1 << /*pointer to element ty*/ 2 << PtrExpr->getType();"},{u,18823,"ExprResult Sema::SemaBuiltinMatrixColumnMajorLoad(CallExpr *TheCall, ExprResult CallResult) {\n if (!PtrTy) {\n } else {\n if (!ConstantMatrixType::isValidElementType(ElementTy)) {\n Diag(PtrExpr->getBeginLoc(), diag::err_builtin_invalid_arg_type) << PtrArgIdx + 1 << /* pointer to element ty*/ 2 << PtrExpr->getType();"},{u,18924,"ExprResult Sema::SemaBuiltinMatrixColumnMajorStore(CallExpr *TheCall, ExprResult CallResult) {\n if (!MatrixTy) {\n Diag(MatrixExpr->getBeginLoc(), diag::err_builtin_invalid_arg_type) << 1 << /*matrix ty */ 1 << MatrixExpr->getType();"},{u,18944,"ExprResult Sema::SemaBuiltinMatrixColumnMajorStore(CallExpr *TheCall, ExprResult CallResult) {\n if (!PtrTy) {\n Diag(PtrExpr->getBeginLoc(), diag::err_builtin_invalid_arg_type) << PtrArgIdx + 1 << /*pointer to element ty*/ 2 << PtrExpr->getType();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/matrix-type-builtins.m"]={"clang/test/SemaObjC/matrix-type-builtins.m:28:49: error: 2nd argument must be a pointer to a valid matrix element type (was \'double4x4\' (aka \'double __attribute__((matrix_type(4, 4)))\'))"} | ["clang/test/SemaObjC/matrix-type-builtins.m"]={"clang/test/SemaObjC/matrix-type-builtins.m:28:49: error: 2nd argument must be a pointer to a valid matrix element type (was \'double4x4\' (aka \'double __attribute__((matrix_type(4, 4)))\'))"} | ||
Line 6,821: | Line 6,841: | ||
}, | }, | ||
["err_builtin_launder_invalid_arg"]={ | ["err_builtin_launder_invalid_arg"]={ | ||
[ | [e]="... argument to \'__builtin_launder\' is not allowed", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{non-pointer|function pointer|void pointer}0 argument to \'__builtin_launder\' is not allowed", | ||
[ | [b]=n, | ||
[ | [j]="(?:non\\-pointer|function pointer|void pointer) argument to \'__builtin_launder\' is not allowed", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"261875054e5e",1544821888,"[Clang] Add __builtin_launder","[Clang] Add __builtin_launder"}, | ||
[k]={{ | [k]={{u,1925,"static ExprResult SemaBuiltinLaunder(Sema &S, CallExpr *TheCall) {\n if (DiagSelect) {\n S.Diag(TheCall->getBeginLoc(), diag::err_builtin_launder_invalid_arg) << *DiagSelect << TheCall->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Hb]={"clang/test/Sema/builtins.c:269:3: error: non-pointer argument to \'__builtin_launder\' is not allowed","clang/test/Sema/builtins.c:271:3: error: void pointer argument to \'__builtin_launder\' is not allowed","clang/test/Sema/builtins.c:272:3: error: void pointer argument to \'__builtin_launder\' is not allowed","clang/test/Sema/builtins.c:276:3: error: function pointer argument to \'__builtin_launder\' is not allowed"} | ||
} | } | ||
}, | }, | ||
["err_builtin_longjmp_invalid_val"]={ | ["err_builtin_longjmp_invalid_val"]={ | ||
[e]="argument to __builtin_longjmp must be a constant 1", | |||
[d]=l, | |||
[f]=m, | |||
[h]="argument to __builtin_longjmp must be a constant 1", | [h]="argument to __builtin_longjmp must be a constant 1", | ||
[ | [b]=n, | ||
[ | [j]="argument to __builtin_longjmp must be a constant 1", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"7903ca0993a4",1241326928,"Add diagnostic for r70658.","Add diagnostic for r70658."}, | |||
[k]={{u,9321,"/// SemaBuiltinLongjmp - Handle __builtin_longjmp(void *env[5], int val).\n/// This checks that the target supports __builtin_longjmp and\n/// that val is a constant 1.\nbool Sema::SemaBuiltinLongjmp(CallExpr *TheCall) {\n if (Result != 1)\n return Diag(TheCall->getBeginLoc(), diag::err_builtin_longjmp_invalid_val) << SourceRange(Arg->getBeginLoc(), Arg->getEndLoc());"}} | |||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_builtin_longjmp_unsupported"]={ | ["err_builtin_longjmp_unsupported"]={ | ||
[e]="__builtin_longjmp is not supported for the current target", | |||
[d]=l, | |||
[f]=m, | |||
[h]="__builtin_longjmp is not supported for the current target", | [h]="__builtin_longjmp is not supported for the current target", | ||
[ | [b]=n, | ||
[ | [j]="__builtin_longjmp is not supported for the current target", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"27173288c296",1426117592,"Under duress, move check for target support of __builtin_setjmp/","Under duress, move check for target support of __builtin_setjmp/"}, | |||
[k]={{u,9310,"/// SemaBuiltinLongjmp - Handle __builtin_longjmp(void *env[5], int val).\n/// This checks that the target supports __builtin_longjmp and\n/// that val is a constant 1.\nbool Sema::SemaBuiltinLongjmp(CallExpr *TheCall) {\n if (!Context.getTargetInfo().hasSjLjLowering())\n return Diag(TheCall->getBeginLoc(), diag::err_builtin_longjmp_unsupported) << SourceRange(TheCall->getBeginLoc(), TheCall->getEndLoc());"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/builtin-longjmp.c"]={"clang/test/Sema/builtin-longjmp.c:27:3: error: __builtin_longjmp is not supported for the current target"} | ["clang/test/Sema/builtin-longjmp.c"]={"clang/test/Sema/builtin-longjmp.c:27:3: error: __builtin_longjmp is not supported for the current target"} | ||
Line 6,863: | Line 6,883: | ||
}, | }, | ||
["err_builtin_matrix_disabled"]={ | ["err_builtin_matrix_disabled"]={ | ||
[e]="matrix types extension is disabled. Pass -fenable-matrix to enable it", | |||
[d]=l, | |||
[f]=m, | |||
[h]="matrix types extension is disabled. Pass -fenable-matrix to enable it", | [h]="matrix types extension is disabled. Pass -fenable-matrix to enable it", | ||
[ | [b]=n, | ||
[ | [j]="matrix types extension is disabled\\. Pass \\-fenable\\-matrix to enable it", | ||
[c]=a, | |||
[i]=a, | |||
[g]={ib,1576908663,K,K}, | |||
[ | [k]={{u,18785,"ExprResult Sema::SemaBuiltinMatrixColumnMajorLoad(CallExpr *TheCall, ExprResult CallResult) {\n if (!getLangOpts().MatrixTypes) {\n Diag(TheCall->getBeginLoc(), diag::err_builtin_matrix_disabled);"},{t,8456,"/// HandleMatrixTypeAttr - \"matrix_type\" attribute, like ext_vector_type\nstatic void HandleMatrixTypeAttr(QualType &CurType, const ParsedAttr &Attr, Sema &S) {\n if (!S.getLangOpts().MatrixTypes) {\n S.Diag(Attr.getLoc(), diag::err_builtin_matrix_disabled);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/matrix-type-disabled.c"]={"clang/test/Parser/matrix-type-disabled.c:9:39: error: matrix types extension is disabled. Pass -fenable-matrix to enable it"} | ["clang/test/Parser/matrix-type-disabled.c"]={"clang/test/Parser/matrix-type-disabled.c:9:39: error: matrix types extension is disabled. Pass -fenable-matrix to enable it"} | ||
Line 6,878: | Line 6,898: | ||
}, | }, | ||
["err_builtin_matrix_invalid_dimension"]={ | ["err_builtin_matrix_invalid_dimension"]={ | ||
[ | [e]="A dimension is outside the allowed range [1, B]", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 dimension is outside the allowed range [1, %1]", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) dimension is outside the allowed range \\[1, (.*?)\\]", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={cb,1582847864,I,I}, | ||
[k]={{ | [k]={{u,18775,"// Get and verify the matrix dimensions.\nstatic std::optional<unsigned> getAndVerifyMatrixDimension(Expr *Expr, StringRef Name, Sema &S) {\n if (!ConstantMatrixType::isDimensionValid(Dim)) {\n S.Diag(Expr->getBeginLoc(), diag::err_builtin_matrix_invalid_dimension) << Name << ConstantMatrixType::getMaxElementsPerDimension();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/matrix-type-builtins.c"]={"clang/test/Sema/matrix-type-builtins.c:67:57: error: row dimension is outside the allowed range [1, 1048575]","clang/test/Sema/matrix-type-builtins.c:69:61: error: column dimension is outside the allowed range [1, 1048575]","clang/test/Sema/matrix-type-builtins.c:74:7: error: row dimension is outside the allowed range [1, 1048575]","clang/test/Sema/matrix-type-builtins.c:75:7: error: column dimension is outside the allowed range [1, 1048575]"} | ["clang/test/Sema/matrix-type-builtins.c"]={"clang/test/Sema/matrix-type-builtins.c:67:57: error: row dimension is outside the allowed range [1, 1048575]","clang/test/Sema/matrix-type-builtins.c:69:61: error: column dimension is outside the allowed range [1, 1048575]","clang/test/Sema/matrix-type-builtins.c:74:7: error: row dimension is outside the allowed range [1, 1048575]","clang/test/Sema/matrix-type-builtins.c:75:7: error: column dimension is outside the allowed range [1, 1048575]"} | ||
Line 6,893: | Line 6,913: | ||
}, | }, | ||
["err_builtin_matrix_pointer_arg_mismatch"]={ | ["err_builtin_matrix_pointer_arg_mismatch"]={ | ||
[ | [e]="the pointee of the 2nd argument must match the element type of the 1st argument (A != B)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="the pointee of the 2nd argument must match the element type of the 1st argument (%0 != %1)", | ||
[ | [b]=n, | ||
[ | [j]="the pointee of the 2nd argument must match the element type of the 1st argument \\((.*?) \\!\\= (.*?)\\)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={cb,1582847864,I,I}, | ||
[k]={{ | [k]={{u,18957,"ExprResult Sema::SemaBuiltinMatrixColumnMajorStore(CallExpr *TheCall, ExprResult CallResult) {\n if (!PtrTy) {\n } else {\n if (MatrixTy && !Context.hasSameType(ElementTy, MatrixTy->getElementType())) {\n Diag(PtrExpr->getBeginLoc(), diag::err_builtin_matrix_pointer_arg_mismatch) << ElementTy << MatrixTy->getElementType();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/matrix-type-builtins.m"]={"clang/test/SemaObjC/matrix-type-builtins.m:24:49: error: the pointee of the 2nd argument must match the element type of the 1st argument (\'float\' != \'double\')"} | ["clang/test/SemaObjC/matrix-type-builtins.m"]={"clang/test/SemaObjC/matrix-type-builtins.m:24:49: error: the pointee of the 2nd argument must match the element type of the 1st argument (\'float\' != \'double\')"} | ||
Line 6,908: | Line 6,928: | ||
}, | }, | ||
["err_builtin_matrix_scalar_unsigned_arg"]={ | ["err_builtin_matrix_scalar_unsigned_arg"]={ | ||
[ | [e]="A argument must be a constant unsigned integer expression", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 argument must be a constant unsigned integer expression", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) argument must be a constant unsigned integer expression", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={cb,1582847864,I,I}, | ||
[k]={{ | [k]={{u,18769,"// Get and verify the matrix dimensions.\nstatic std::optional<unsigned> getAndVerifyMatrixDimension(Expr *Expr, StringRef Name, Sema &S) {\n if (!Value) {\n S.Diag(Expr->getBeginLoc(), diag::err_builtin_matrix_scalar_unsigned_arg) << Name;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/matrix-type-builtins.c"]={"clang/test/Sema/matrix-type-builtins.c:81:7: error: column argument must be a constant unsigned integer expression"} | ["clang/test/Sema/matrix-type-builtins.c"]={"clang/test/Sema/matrix-type-builtins.c:81:7: error: column argument must be a constant unsigned integer expression"} | ||
Line 6,923: | Line 6,943: | ||
}, | }, | ||
["err_builtin_matrix_store_to_const"]={ | ["err_builtin_matrix_store_to_const"]={ | ||
[e]="cannot store matrix to read-only pointer", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot store matrix to read-only pointer", | [h]="cannot store matrix to read-only pointer", | ||
[ | [b]=n, | ||
[ | [j]="cannot store matrix to read\\-only pointer", | ||
[c]=a, | |||
[i]=a, | |||
[g]={cb,1582847864,I,I}, | |||
[ | [k]={{u,18950,"ExprResult Sema::SemaBuiltinMatrixColumnMajorStore(CallExpr *TheCall, ExprResult CallResult) {\n if (!PtrTy) {\n } else {\n if (ElementTy.isConstQualified()) {\n Diag(PtrExpr->getBeginLoc(), diag::err_builtin_matrix_store_to_const);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/matrix-type-builtins.c"]={"clang/test/Sema/matrix-type-builtins.c:112:44: error: cannot store matrix to read-only pointer"} | ["clang/test/Sema/matrix-type-builtins.c"]={"clang/test/Sema/matrix-type-builtins.c:112:44: error: cannot store matrix to read-only pointer"} | ||
Line 6,938: | Line 6,958: | ||
}, | }, | ||
["err_builtin_matrix_stride_too_small"]={ | ["err_builtin_matrix_stride_too_small"]={ | ||
[e]="stride must be greater or equal to the number of rows", | |||
[d]=l, | |||
[f]=m, | |||
[h]="stride must be greater or equal to the number of rows", | [h]="stride must be greater or equal to the number of rows", | ||
[ | [b]=n, | ||
[ | [j]="stride must be greater or equal to the number of rows", | ||
[c]=a, | |||
[ | [i]=a, | ||
[g]={cb,1582847864,I,I}, | |||
[k]={{u,18884,"ExprResult Sema::SemaBuiltinMatrixColumnMajorLoad(CallExpr *TheCall, ExprResult CallResult) {\n if (MaybeRows) {\n if (std::optional<llvm::APSInt> Value = StrideExpr->getIntegerConstantExpr(Context)) {\n if (Stride < *MaybeRows) {\n Diag(StrideExpr->getBeginLoc(), diag::err_builtin_matrix_stride_too_small);"},{u,18984,"ExprResult Sema::SemaBuiltinMatrixColumnMajorStore(CallExpr *TheCall, ExprResult CallResult) {\n // Check stride argument.\n if (MatrixTy) {\n if (std::optional<llvm::APSInt> Value = StrideExpr->getIntegerConstantExpr(Context)) {\n if (Stride < MatrixTy->getNumRows()) {\n Diag(StrideExpr->getBeginLoc(), diag::err_builtin_matrix_stride_too_small);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/matrix-type-builtins.m"]={"clang/test/SemaObjC/matrix-type-builtins.m:24:54: error: stride must be greater or equal to the number of rows"} | ["clang/test/SemaObjC/matrix-type-builtins.m"]={"clang/test/SemaObjC/matrix-type-builtins.m:24:54: error: stride must be greater or equal to the number of rows"} | ||
Line 6,953: | Line 6,973: | ||
}, | }, | ||
["err_builtin_move_forward_unsupported"]={ | ["err_builtin_move_forward_unsupported"]={ | ||
[ | [e]="unsupported signature for A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="unsupported signature for %q0", | ||
[ | [b]=n, | ||
[ | [j]="unsupported signature for (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"cb08f4aa4467",1620530452,Yb,Yb}, | ||
[k]={{ | [k]={{u,2512,"#include \"clang/Basic/Builtins.def\"\n case Builtin::BIas_const: {\n if (!(Param->isReferenceType() && (ReturnsPointer ? Result->isAnyPointerType() : Result->isReferenceType()) && Context.hasSameUnqualifiedType(Param->getPointeeType(), Result->getPointeeType()))) {\n Diag(TheCall->getBeginLoc(), diag::err_builtin_move_forward_unsupported) << FDecl;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/builtin-std-move.cpp"]={"clang/test/SemaCXX/builtin-std-move.cpp:169:21: error: unsupported signature for \'std::move<int>\'"} | ["clang/test/SemaCXX/builtin-std-move.cpp"]={"clang/test/SemaCXX/builtin-std-move.cpp:169:21: error: unsupported signature for \'std::move<int>\'"} | ||
Line 6,968: | Line 6,988: | ||
}, | }, | ||
["err_builtin_needs_feature"]={ | ["err_builtin_needs_feature"]={ | ||
[ | [e]="A needs target feature B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 needs target feature %1", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) needs target feature (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"15709991d09d",1444952831,"Add an error when calling a builtin that requires features that don\'t","Add an error when calling a builtin that requires features that don\'t"}, | ||
[k]={{"clang/lib/CodeGen/CodeGenFunction.cpp",2603,"// Emits an error if we don\'t have a valid set of target features for the\n// called function.\nvoid CodeGenFunction::checkTargetFeatures(SourceLocation Loc, const FunctionDecl *TargetDecl) {\n if (BuiltinID) {\n if (!Builtin::evaluateRequiredTargetFeatures(FeatureList, CallerFeatureMap)) {\n CGM.getDiags().Report(Loc, diag::err_builtin_needs_feature) << TargetDecl->getDeclName() << FeatureList;"}}, | [k]={{"clang/lib/CodeGen/CodeGenFunction.cpp",2603,"// Emits an error if we don\'t have a valid set of target features for the\n// called function.\nvoid CodeGenFunction::checkTargetFeatures(SourceLocation Loc, const FunctionDecl *TargetDecl) {\n if (BuiltinID) {\n if (!Builtin::evaluateRequiredTargetFeatures(FeatureList, CallerFeatureMap)) {\n CGM.getDiags().Report(Loc, diag::err_builtin_needs_feature) << TargetDecl->getDeclName() << FeatureList;"}}, | ||
[o]={ | [o]={ | ||
Line 6,983: | Line 7,003: | ||
}, | }, | ||
["err_builtin_operator_new_delete_not_usual"]={ | ["err_builtin_operator_new_delete_not_usual"]={ | ||
[ | [e]="call to \'...\' selects non-usual ... function", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="call to \'%select{__builtin_operator_new|__builtin_operator_delete}0\' selects non-usual %select{allocation|deallocation}0 function", | ||
[ | [b]=n, | ||
[ | [j]="call to \'(?:__builtin_operator_new|__builtin_operator_delete)\' selects non\\-usual (?:allocation|deallocation) function", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"fa752f23cc20",1521659988,"[Builtins] Overload __builtin_operator_new/delete to allow forwarding to usual allocation/deallocati...","[Builtins] Overload __builtin_operator_new/delete to allow forwarding to usual allocation/deallocation functions."}, | ||
[k]={{y,3859,"static bool resolveBuiltinNewDeleteOverload(Sema &S, CallExpr *TheCall, bool IsDelete, FunctionDecl *&Operator) {\n case OR_Success: {\n if (!FnDecl->isReplaceableGlobalAllocationFunction()) {\n S.Diag(R.getNameLoc(), diag::err_builtin_operator_new_delete_not_usual) << (IsDelete ? 1 : 0) << Range;"}}, | [k]={{y,3859,"static bool resolveBuiltinNewDeleteOverload(Sema &S, CallExpr *TheCall, bool IsDelete, FunctionDecl *&Operator) {\n case OR_Success: {\n if (!FnDecl->isReplaceableGlobalAllocationFunction()) {\n S.Diag(R.getNameLoc(), diag::err_builtin_operator_new_delete_not_usual) << (IsDelete ? 1 : 0) << Range;"}}, | ||
[o]={ | [o]={ | ||
Line 6,998: | Line 7,018: | ||
}, | }, | ||
["err_builtin_pass_in_regs_non_class"]={ | ["err_builtin_pass_in_regs_non_class"]={ | ||
[ | [e]="argument A is not an unqualified class type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="argument %0 is not an unqualified class type", | ||
[ | [b]=n, | ||
[ | [j]="argument (.*?) is not an unqualified class type", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{y,5393,"static bool EvaluateUnaryTypeTrait(Sema &Self, TypeTrait UTT, SourceLocation KeyLoc, QualType T) {\n case UTT_CanPassInRegs:\n Self.Diag(KeyLoc, diag::err_builtin_pass_in_regs_non_class) << T;"}}, | [k]={{y,5393,"static bool EvaluateUnaryTypeTrait(Sema &Self, TypeTrait UTT, SourceLocation KeyLoc, QualType T) {\n case UTT_CanPassInRegs:\n Self.Diag(KeyLoc, diag::err_builtin_pass_in_regs_non_class) << T;"}}, | ||
[o]={ | [o]={ | ||
Line 7,013: | Line 7,033: | ||
}, | }, | ||
["err_builtin_redeclare"]={ | ["err_builtin_redeclare"]={ | ||
[ | [e]="cannot redeclare builtin function A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot redeclare builtin function %0", | ||
[ | [b]=n, | ||
[ | [j]="cannot redeclare builtin function (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"41af97137572",1523914208,"Limit types of builtins that can be redeclared.","Limit types of builtins that can be redeclared."}, | ||
[k]={{ | [k]={{s,3678,"/// 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 // Disallow redeclaration of some builtins.\n if (!getASTContext().canBuiltinBeRedeclared(Old)) {\n Diag(New->getLocation(), diag::err_builtin_redeclare) << Old->getDeclName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/crash-invalid-builtin.c"]={"clang/test/Sema/crash-invalid-builtin.c:4:1: error: cannot redeclare builtin function \'__builtin_isinf\'"} | ["clang/test/Sema/crash-invalid-builtin.c"]={"clang/test/Sema/crash-invalid-builtin.c:4:1: error: cannot redeclare builtin function \'__builtin_isinf\'"} | ||
Line 7,028: | Line 7,048: | ||
}, | }, | ||
["err_builtin_requires_language"]={ | ["err_builtin_requires_language"]={ | ||
[ | [e]="\'A\' is only available in B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'%0\' is only available in %1", | ||
[ | [b]=n, | ||
[ | [j]="\'(.*?)\' is only available in (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"760520bcb78d",1401838064,"Add __builtin_operator_new and __builtin_operator_delete, which act like calls","Add __builtin_operator_new and __builtin_operator_delete, which act like calls"}, | ||
[k]={{y,3902,"ExprResult Sema::SemaBuiltinOperatorNewDeleteOverloaded(ExprResult TheCallResult, bool IsDelete) {\n if (!getLangOpts().CPlusPlus) {\n Diag(TheCall->getExprLoc(), diag::err_builtin_requires_language) << (IsDelete ? \"__builtin_operator_delete\" : \"__builtin_operator_new\") << \"C++\";"}}, | [k]={{y,3902,"ExprResult Sema::SemaBuiltinOperatorNewDeleteOverloaded(ExprResult TheCallResult, bool IsDelete) {\n if (!getLangOpts().CPlusPlus) {\n Diag(TheCall->getExprLoc(), diag::err_builtin_requires_language) << (IsDelete ? \"__builtin_operator_delete\" : \"__builtin_operator_new\") << \"C++\";"}}, | ||
[o]={ | [o]={ | ||
[ | [Hb]={"clang/test/Sema/builtins.c:216:3: error: \'__builtin_operator_new\' is only available in C++","clang/test/Sema/builtins.c:217:3: error: \'__builtin_operator_delete\' is only available in C++"} | ||
} | } | ||
}, | }, | ||
["err_builtin_setjmp_unsupported"]={ | ["err_builtin_setjmp_unsupported"]={ | ||
[e]="__builtin_setjmp is not supported for the current target", | |||
[d]=l, | |||
[f]=m, | |||
[h]="__builtin_setjmp is not supported for the current target", | [h]="__builtin_setjmp is not supported for the current target", | ||
[ | [b]=n, | ||
[ | [j]="__builtin_setjmp is not supported for the current target", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"27173288c296",1426117592,"Under duress, move check for target support of __builtin_setjmp/","Under duress, move check for target support of __builtin_setjmp/"}, | |||
[k]={{u,9331,"/// SemaBuiltinSetjmp - Handle __builtin_setjmp(void *env[5]).\n/// This checks that the target supports __builtin_setjmp.\nbool Sema::SemaBuiltinSetjmp(CallExpr *TheCall) {\n if (!Context.getTargetInfo().hasSjLjLowering())\n return Diag(TheCall->getBeginLoc(), diag::err_builtin_setjmp_unsupported) << SourceRange(TheCall->getBeginLoc(), TheCall->getEndLoc());"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/builtin-longjmp.c"]={"clang/test/Sema/builtin-longjmp.c:33:8: error: __builtin_setjmp is not supported for the current target"} | ["clang/test/Sema/builtin-longjmp.c"]={"clang/test/Sema/builtin-longjmp.c:33:8: error: __builtin_setjmp is not supported for the current target"} | ||
Line 7,058: | Line 7,078: | ||
}, | }, | ||
["err_builtin_target_unsupported"]={ | ["err_builtin_target_unsupported"]={ | ||
[e]="builtin is not supported on this target", | |||
[d]=l, | |||
[f]=m, | |||
[h]="builtin is not supported on this target", | [h]="builtin is not supported on this target", | ||
[ | [b]=n, | ||
[ | [j]="builtin is not supported on this target", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"aa46ed927860",1528407544,"[MS] Re-add support for the ARM interlocked bittest intrinscs","[MS] Re-add support for the ARM interlocked bittest intrinscs"}, | |||
[k]={{u,1962,"// Emit an error and return true if the current object format type is in the\n// list of unsupported types.\nstatic bool CheckBuiltinTargetNotInUnsupported(Sema &S, unsigned BuiltinID, CallExpr *TheCall, ArrayRef<llvm::Triple::ObjectFormatType> UnsupportedObjectFormatTypes) {\n if (llvm::is_contained(UnsupportedObjectFormatTypes, CurObjFormat)) {\n S.Diag(TheCall->getBeginLoc(), diag::err_builtin_target_unsupported) << TheCall->getSourceRange();"},{u,1978,"// Emit an error and return true if the current architecture is not in the list\n// of supported architectures.\nstatic bool CheckBuiltinTargetInSupported(Sema &S, unsigned BuiltinID, CallExpr *TheCall, ArrayRef<llvm::Triple::ArchType> SupportedArchs) {\n S.Diag(TheCall->getBeginLoc(), diag::err_builtin_target_unsupported) << TheCall->getSourceRange();"},{u,8577,"/// SemaBuiltinArithmeticFence - Handle __arithmetic_fence.\nbool Sema::SemaBuiltinArithmeticFence(CallExpr *TheCall) {\n if (!Context.getTargetInfo().checkArithmeticFenceSupported())\n return Diag(TheCall->getBeginLoc(), diag::err_builtin_target_unsupported) << SourceRange(TheCall->getBeginLoc(), TheCall->getEndLoc());"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/builtin_set_flt_rounds.c"]={"clang/test/Sema/builtin_set_flt_rounds.c:5:3: error: builtin is not supported on this target"} | ["clang/test/Sema/builtin_set_flt_rounds.c"]={"clang/test/Sema/builtin_set_flt_rounds.c:5:3: error: builtin is not supported on this target"} | ||
Line 7,073: | Line 7,093: | ||
}, | }, | ||
["err_builtin_x64_aarch64_only"]={ | ["err_builtin_x64_aarch64_only"]={ | ||
[e]="this builtin is only available on x86-64 and aarch64 targets", | |||
[d]=l, | |||
[f]=m, | |||
[h]="this builtin is only available on x86-64 and aarch64 targets", | [h]="this builtin is only available on x86-64 and aarch64 targets", | ||
[ | [b]=n, | ||
[ | [j]="this builtin is only available on x86\\-64 and aarch64 targets", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"022e782e7576",1500324585,"[AArch64] Add support for __builtin_ms_va_list on aarch64","[AArch64] Add support for __builtin_ms_va_list on aarch64"}, | |||
[ | [k]={{u,8059,"/// Check that the user is calling the appropriate va_start builtin for the\n/// target and calling convention.\nstatic bool checkVAStartABI(Sema &S, unsigned BuiltinID, Expr *Fn) {\n if (IsMSVAStart)\n return S.Diag(Fn->getBeginLoc(), diag::err_builtin_x64_aarch64_only);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/varargs-x86-32.c"]={"clang/test/Sema/varargs-x86-32.c:4:3: error: this builtin is only available on x86-64 and aarch64 targets"} | ["clang/test/Sema/varargs-x86-32.c"]={"clang/test/Sema/varargs-x86-32.c:4:3: error: this builtin is only available on x86-64 and aarch64 targets"} | ||
Line 7,088: | Line 7,108: | ||
}, | }, | ||
["err_c11_noreturn_misplaced"]={ | ["err_c11_noreturn_misplaced"]={ | ||
[e]="\'_Noreturn\' keyword must precede function declarator", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'_Noreturn\' keyword must precede function declarator", | [h]="\'_Noreturn\' keyword must precede function declarator", | ||
[ | [b]=n, | ||
[ | [j]="\'_Noreturn\' keyword must precede function declarator", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={"99c464c3f377",1415653832,"Improve diagnostics if _Noreturn is placed after a function declarator. (This sometimes happens when...","Improve diagnostics if _Noreturn is placed after a function declarator. (This sometimes happens when a macro is used that expands to either the GNU noreturn attribute or _Noreturn.)"}, | |||
[k]={{H,2155,"/// ParseDeclGroup - Having concluded that this is either a function\n/// definition or a group of object declarations, actually parse the\n/// result.\nParser::DeclGroupPtrTy Parser::ParseDeclGroup(ParsingDeclSpec &DS, DeclaratorContext Context, ParsedAttributes &Attrs, SourceLocation *DeclEnd, ForRangeInit *FRI) {\n if (D.isFunctionDeclarator()) {\n // The _Noreturn keyword can\'t appear here, unlike the GNU noreturn\n // attribute. If we find the keyword here, tell the user to put it\n // at the start instead.\n if (Tok.is(tok::kw__Noreturn)) {\n Diag(Loc, diag::err_c11_noreturn_misplaced) << (Fixit ? FixItHint::CreateRemoval(Loc) : FixItHint()) << (Fixit ? FixItHint::CreateInsertion(D.getBeginLoc(), \"_Noreturn \") : FixItHint());"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/c11-noreturn.c"]={"clang/test/Parser/c11-noreturn.c:7:13: error: \'_Noreturn\' keyword must precede function declarator"} | ["clang/test/Parser/c11-noreturn.c"]={"clang/test/Parser/c11-noreturn.c:7:13: error: \'_Noreturn\' keyword must precede function declarator"} | ||
Line 7,103: | Line 7,123: | ||
}, | }, | ||
["err_c99_array_usage_cxx"]={ | ["err_c99_array_usage_cxx"]={ | ||
[ | [e]="...array size ...is a C99 feature, not permitted in C++", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{qualifier in |static |}0array size %select{||\'[*] \'}0is a C99 feature, not permitted in C++", | ||
[ | [b]=n, | ||
[ | [j]="(?:qualifier in |static |)array size (?:||\'\\[\\*\\] \')is a C99 feature, not permitted in C\\+\\+", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"73341c4e6319",1252628338,"Diagnose VLAs as an error in C++.","Diagnose VLAs as an error in C++."}, | ||
[k]={{ | [k]={{t,2680,"/// 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 // If this is not C99, diagnose array size modifiers on non-VLAs.\n if (!getLangOpts().C99 && !T->isVariableArrayType() && (ASM != ArrayType::Normal || Quals != 0)) {\n Diag(Loc, getLangOpts().CPlusPlus ? diag::err_c99_array_usage_cxx : diag::ext_c99_array_usage) << ASM;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/attr-gnu.cpp"]={"clang/test/SemaCXX/attr-gnu.cpp:13:13: error: static array size is a C99 feature, not permitted in C++"} | ["clang/test/SemaCXX/attr-gnu.cpp"]={"clang/test/SemaCXX/attr-gnu.cpp:13:13: error: static array size is a C99 feature, not permitted in C++"} | ||
Line 7,118: | Line 7,138: | ||
}, | }, | ||
["err_call_function_incomplete_return"]={ | ["err_call_function_incomplete_return"]={ | ||
[ | [e]="calling A with incomplete return type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="calling %0 with incomplete return type %1", | ||
[ | [b]=n, | ||
[ | [j]="calling (.*?) with incomplete return type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"7f84ed928721",1255132315,"Add CheckCallReturnType and start using it for regular call expressions. This will improve error mes...","Add CheckCallReturnType and start using it for regular call expressions. This will improve error messages. For "}, | ||
[k]={{ | [k]={{A,20821,"bool Sema::CheckCallReturnType(QualType ReturnType, SourceLocation Loc, CallExpr *CE, FunctionDecl *FD) {\n class CallReturnIncompleteDiagnoser : public TypeDiagnoser {\n void diagnose(Sema &S, SourceLocation Loc, QualType T) override {\n S.Diag(Loc, diag::err_call_function_incomplete_return) << CE->getSourceRange() << FD << T;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/incomplete-call.c"]={"clang/test/Sema/incomplete-call.c:10:3: error: calling \'a\' with incomplete return type \'struct foo\'"} | ["clang/test/Sema/incomplete-call.c"]={"clang/test/Sema/incomplete-call.c:10:3: error: calling \'a\' with incomplete return type \'struct foo\'"} | ||
Line 7,133: | Line 7,153: | ||
}, | }, | ||
["err_call_incomplete_argument"]={ | ["err_call_incomplete_argument"]={ | ||
[ | [e]="argument type A is incomplete", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="argument type %0 is incomplete", | ||
[ | [b]=n, | ||
[ | [j]="argument type (.*?) is incomplete", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3164fb15e286",1237759250,"Check that the return/argument types of calls are complete.","Check that the return/argument types of calls are complete."}, | ||
[k]={{ | [k]={{A,1092,"/// DefaultVariadicArgumentPromotion - Like DefaultArgumentPromotion, but\n/// will create a trap if the resulting type is not a POD type.\nExprResult Sema::DefaultVariadicArgumentPromotion(Expr *E, VariadicCallType CT, FunctionDecl *FDecl) {\n if (!getLangOpts().CPlusPlus && RequireCompleteType(E->getExprLoc(), E->getType(), diag::err_call_incomplete_argument))"},{A,6655,"bool Sema::GatherArgumentsForCall(SourceLocation CallLoc, FunctionDecl *FDecl, const FunctionProtoType *Proto, unsigned FirstParam, ArrayRef<Expr *> Args, SmallVectorImpl<Expr *> &AllArgs, VariadicCallType CallType, bool AllowExplicit, bool IsListInitialization) {\n // Continue to check argument types (even if we have too few/many args).\n for (unsigned i = FirstParam; i < NumParams; i++) {\n if (ArgIx < Args.size()) {\n if (RequireCompleteType(Arg->getBeginLoc(), ProtoArgType, diag::err_call_incomplete_argument, Arg))"},{A,7594,"/// 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 if (Proto) {\n } else {\n // Promote the arguments (C99 6.5.2.2p6).\n for (unsigned i = 0, e = Args.size(); i != e; i++) {\n if (RequireCompleteType(Arg->getBeginLoc(), Arg->getType(), diag::err_call_incomplete_argument, Arg))"},{M,1861,"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 for (unsigned i = 0; i < NumNamedArgs; i++) {\n if (RequireCompleteType(argExpr->getSourceRange().getBegin(), paramType, diag::err_call_incomplete_argument, argExpr))"},{L,6837,"/// Make a (potentially elidable) temporary copy of the object\n/// provided by the given initializer by calling the appropriate copy\n/// constructor.\n///\n/// \\param S The Sema object used for type-checking.\n///\n/// \\param T The type of the temporary object, which must either be\n/// the type of the initializer expression or a superclass thereof.\n///\n/// \\param Entity The entity being initialized.\n///\n/// \\param CurInit The initializer expression.\n///\n/// \\param IsExtraneousCopy Whether this is an \"extraneous\" copy that\n/// is permitted in C++03 (but not C++0x) when binding a reference to\n/// an rvalue.\n///\n/// \\returns An expression that copies the initializer expression into\n/// a temporary object, or an error expression if a copy could not be\n/// created.\nstatic ExprResult CopyObject(Sema &S, QualType T, const InitializedEntity &Entity, ExprResult CurInit, bool IsExtraneousCopy) {\n if (IsExtraneousCopy) {\n // Instantiate the default arguments of any extra parameters in\n // the selected copy constructor, as if we were going to create a\n // proper call to the copy constructor.\n for (unsigned I = 1, N = Constructor->getNumParams(); I != N; ++I) {\n if (S.RequireCompleteType(Loc, Parm->getType(), diag::err_call_incomplete_argument))"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/incomplete-call.c"]={"clang/test/Sema/incomplete-call.c:11:5: error: argument type \'struct foo\' is incomplete","clang/test/Sema/incomplete-call.c:12:5: error: argument type \'struct foo\' is incomplete"} | ["clang/test/Sema/incomplete-call.c"]={"clang/test/Sema/incomplete-call.c:11:5: error: argument type \'struct foo\' is incomplete","clang/test/Sema/incomplete-call.c:12:5: error: argument type \'struct foo\' is incomplete"} | ||
Line 7,148: | Line 7,168: | ||
}, | }, | ||
["err_call_incomplete_return"]={ | ["err_call_incomplete_return"]={ | ||
[ | [e]="calling function with incomplete return type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="calling function with incomplete return type %0", | ||
[ | [b]=n, | ||
[ | [j]="calling function with incomplete return type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3164fb15e286",1237759250,"Check that the return/argument types of calls are complete.","Check that the return/argument types of calls are complete."}, | ||
[k]={{ | [k]={{A,20819,"bool Sema::CheckCallReturnType(QualType ReturnType, SourceLocation Loc, CallExpr *CE, FunctionDecl *FD) {\n class CallReturnIncompleteDiagnoser : public TypeDiagnoser {\n void diagnose(Sema &S, SourceLocation Loc, QualType T) override {\n if (!FD) {\n S.Diag(Loc, diag::err_call_incomplete_return) << T << CE->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/incomplete-call.cpp"]={"clang/test/SemaCXX/incomplete-call.cpp:23:3: error: calling function with incomplete return type \'A\'","clang/test/SemaCXX/incomplete-call.cpp:24:3: error: calling function with incomplete return type \'A\'","clang/test/SemaCXX/incomplete-call.cpp:41:7: error: calling function with incomplete return type \'A\'"} | ["clang/test/SemaCXX/incomplete-call.cpp"]={"clang/test/SemaCXX/incomplete-call.cpp:23:3: error: calling function with incomplete return type \'A\'","clang/test/SemaCXX/incomplete-call.cpp:24:3: error: calling function with incomplete return type \'A\'","clang/test/SemaCXX/incomplete-call.cpp:41:7: error: calling function with incomplete return type \'A\'"} | ||
Line 7,163: | Line 7,183: | ||
}, | }, | ||
["err_callback_attribute_argument_unknown"]={ | ["err_callback_attribute_argument_unknown"]={ | ||
[ | [e]="\'callback\' attribute argument A is not a known function parameter", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'callback\' attribute argument %0 is not a known function parameter", | ||
[ | [b]=n, | ||
[ | [j]="\'callback\' attribute argument (.*?) is not a known function parameter", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Bb,1547876214,Z,Z}, | ||
[k]={{q,4084,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n if (AL.isArgIdent(I)) {\n if (It == UnknownName) {\n S.Diag(AL.getLoc(), diag::err_callback_attribute_argument_unknown) << IdLoc->Ident << IdLoc->Loc;"}}, | [k]={{q,4084,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n if (AL.isArgIdent(I)) {\n if (It == UnknownName) {\n S.Diag(AL.getLoc(), diag::err_callback_attribute_argument_unknown) << IdLoc->Ident << IdLoc->Loc;"}}, | ||
[o]={ | [o]={ | ||
[ | [Kb]={"clang/test/Sema/attr-callback-broken.c:42:16: error: \'callback\' attribute argument \'cb\' is not a known function parameter","clang/test/Sema/attr-callback-broken.c:43:16: error: \'callback\' attribute argument \'ab\' is not a known function parameter"} | ||
} | } | ||
}, | }, | ||
["err_callback_attribute_invalid_callee"]={ | ["err_callback_attribute_invalid_callee"]={ | ||
[e]="\'callback\' attribute specifies invalid callback callee", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'callback\' attribute specifies invalid callback callee", | [h]="\'callback\' attribute specifies invalid callback callee", | ||
[ | [b]=n, | ||
[ | [j]="\'callback\' attribute specifies invalid callback callee", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={Bb,1547876214,Z,Z}, | |||
[ | |||
[ | |||
[k]={{q,4133,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Check if the callee index is proper, thus not \"this\" and not \"unknown\".\n // This means the \"CalleeIdx\" has to be non-negative if \"HasImplicitThisParam\"\n // is false and positive if \"HasImplicitThisParam\" is true.\n if (CalleeIdx < (int)HasImplicitThisParam) {\n S.Diag(AL.getLoc(), diag::err_callback_attribute_invalid_callee) << AL.getRange();"}}, | [k]={{q,4133,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Check if the callee index is proper, thus not \"this\" and not \"unknown\".\n // This means the \"CalleeIdx\" has to be non-negative if \"HasImplicitThisParam\"\n // is false and positive if \"HasImplicitThisParam\" is true.\n if (CalleeIdx < (int)HasImplicitThisParam) {\n S.Diag(AL.getLoc(), diag::err_callback_attribute_invalid_callee) << AL.getRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Kb]={"clang/test/Sema/attr-callback-broken.c:13:16: error: \'callback\' attribute specifies invalid callback callee","clang/test/Sema/attr-callback-broken.c:53:16: error: \'callback\' attribute specifies invalid callback callee"} | ||
} | } | ||
}, | }, | ||
["err_callback_attribute_multiple"]={ | ["err_callback_attribute_multiple"]={ | ||
[e]="multiple \'callback\' attributes specified", | |||
[d]=l, | |||
[f]=m, | |||
[h]="multiple \'callback\' attributes specified", | [h]="multiple \'callback\' attributes specified", | ||
[ | [b]=n, | ||
[ | [j]="multiple \'callback\' attributes specified", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={Bb,1547876214,Z,Z}, | |||
[ | |||
[ | |||
[k]={{q,4180,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Do not allow multiple callback attributes.\n if (D->hasAttr<CallbackAttr>()) {\n S.Diag(AL.getLoc(), diag::err_callback_attribute_multiple) << AL.getRange();"}}, | [k]={{q,4180,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // Do not allow multiple callback attributes.\n if (D->hasAttr<CallbackAttr>()) {\n S.Diag(AL.getLoc(), diag::err_callback_attribute_multiple) << AL.getRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Kb]={"clang/test/Sema/attr-callback-broken.c:20:45: error: multiple \'callback\' attributes specified","clang/test/Sema/attr-callback-broken.c:21:45: error: multiple \'callback\' attributes specified","clang/test/Sema/attr-callback-broken.c:55:52: error: multiple \'callback\' attributes specified","clang/test/Sema/attr-callback-broken.c:56:45: error: multiple \'callback\' attributes specified"} | ||
} | } | ||
}, | }, | ||
["err_callback_attribute_no_callee"]={ | ["err_callback_attribute_no_callee"]={ | ||
[e]="\'callback\' attribute specifies no callback callee", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'callback\' attribute specifies no callback callee", | [h]="\'callback\' attribute specifies no callback callee", | ||
[ | [b]=n, | ||
[ | [j]="\'callback\' attribute specifies no callback callee", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={Bb,1547876214,Z,Z}, | |||
[ | |||
[ | |||
[k]={{q,4053,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // The index that identifies the callback callee is mandatory.\n if (AL.getNumArgs() == 0) {\n S.Diag(AL.getLoc(), diag::err_callback_attribute_no_callee) << AL.getRange();"}}, | [k]={{q,4053,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n // The index that identifies the callback callee is mandatory.\n if (AL.getNumArgs() == 0) {\n S.Diag(AL.getLoc(), diag::err_callback_attribute_no_callee) << AL.getRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Kb]={"clang/test/Sema/attr-callback-broken.c:3:16: error: \'callback\' attribute specifies no callback callee"} | ||
} | } | ||
}, | }, | ||
["err_callback_callee_is_variadic"]={ | ["err_callback_callee_is_variadic"]={ | ||
[e]="\'callback\' attribute callee may not be variadic", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'callback\' attribute callee may not be variadic", | [h]="\'callback\' attribute callee may not be variadic", | ||
[ | [b]=n, | ||
[ | [j]="\'callback\' attribute callee may not be variadic", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={Bb,1547876214,Z,Z}, | |||
[ | |||
[ | |||
[k]={{q,4174,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (CalleeFnProtoType->isVariadic()) {\n S.Diag(AL.getLoc(), diag::err_callback_callee_is_variadic) << AL.getRange();"}}, | [k]={{q,4174,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (CalleeFnProtoType->isVariadic()) {\n S.Diag(AL.getLoc(), diag::err_callback_callee_is_variadic) << AL.getRange();"}}, | ||
[o]={ | [o]={ | ||
[ | [Kb]={"clang/test/Sema/attr-callback-broken.c:33:16: error: \'callback\' attribute callee may not be variadic","clang/test/Sema/attr-callback-broken.c:34:16: error: \'callback\' attribute callee may not be variadic","clang/test/Sema/attr-callback-broken.c:68:16: error: \'callback\' attribute callee may not be variadic","clang/test/Sema/attr-callback-broken.c:69:16: error: \'callback\' attribute callee may not be variadic"} | ||
} | } | ||
}, | }, | ||
["err_callback_callee_no_function_type"]={ | ["err_callback_callee_no_function_type"]={ | ||
[e]="\'callback\' attribute callee does not have function type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'callback\' attribute callee does not have function type", | [h]="\'callback\' attribute callee does not have function type", | ||
[ | [b]=n, | ||
[ | [j]="\'callback\' attribute callee does not have function type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={Bb,1547876214,Z,Z}, | |||
[ | |||
[ | |||
[k]={{q,4144,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!CalleeType || !CalleeType->isFunctionPointerType()) {\n S.Diag(AL.getLoc(), diag::err_callback_callee_no_function_type) << AL.getRange();"},{q,4156,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!CalleeFnProtoType) {\n S.Diag(AL.getLoc(), diag::err_callback_callee_no_function_type) << AL.getRange();"}} | [k]={{q,4144,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!CalleeType || !CalleeType->isFunctionPointerType()) {\n S.Diag(AL.getLoc(), diag::err_callback_callee_no_function_type) << AL.getRange();"},{q,4156,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!CalleeFnProtoType) {\n S.Diag(AL.getLoc(), diag::err_callback_callee_no_function_type) << AL.getRange();"}} | ||
}, | }, | ||
["err_callback_implicit_this_not_available"]={ | ["err_callback_implicit_this_not_available"]={ | ||
[ | [e]="\'callback\' argument at position A references unavailable implicit \'this\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'callback\' argument at position %0 references unavailable implicit \'this\'", | ||
[ | [b]=n, | ||
[ | [j]="\'callback\' argument at position (.*?) references unavailable implicit \'this\'", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Bb,1547876214,Z,Z}, | ||
[k]={{q,4115,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n if (ArgIdx == 0 && !HasImplicitThisParam) {\n S.Diag(AL.getLoc(), diag::err_callback_implicit_this_not_available) << (I + 1) << SR;"}}, | [k]={{q,4115,"/// Handle __attribute__((callback(CalleeIdx, PayloadIdx0, ...))) attributes.\nstatic void handleCallbackAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n for (unsigned I = 0, E = AL.getNumArgs(); I < E; ++I) {\n if (ArgIdx == 0 && !HasImplicitThisParam) {\n S.Diag(AL.getLoc(), diag::err_callback_implicit_this_not_available) << (I + 1) << SR;"}}, | ||
[o]={ | [o]={ | ||
[ | [Kb]={"clang/test/Sema/attr-callback-broken.c:26:16: error: \'callback\' argument at position 1 references unavailable implicit \'this\'","clang/test/Sema/attr-callback-broken.c:27:16: error: \'callback\' argument at position 2 references unavailable implicit \'this\'","clang/test/Sema/attr-callback-broken.c:28:16: error: \'callback\' argument at position 2 references unavailable implicit \'this\'","clang/test/Sema/attr-callback-broken.c:61:16: error: \'callback\' argument at position 1 references unavailable implicit \'this\'","clang/test/Sema/attr-callback-broken.c:62:16: error: \'callback\' argument at position 2 references unavailable implicit \'this\'","clang/test/Sema/attr-callback-broken.c:63:16: error: \'callback\' argument at position 2 references unavailable implicit \'this\'"} | ||
} | } | ||
}, | }, | ||
["err_called_once_attribute_wrong_type"]={ | ["err_called_once_attribute_wrong_type"]={ | ||
[e]="\'called_once\' attribute only applies to function-like parameters", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'called_once\' attribute only applies to function-like parameters", | [h]="\'called_once\' attribute only applies to function-like parameters", | ||
[ | [b]=n, | ||
[ | [j]="\'called_once\' attribute only applies to function\\-like parameters", | ||
[c]=a, | |||
[i]=p, | |||
[g]={sb,1590001902,T,T}, | |||
[ | |||
[ | |||
[ | |||
[k]={{q,4201,"/// Handle \'called_once\' attribute.\nstatic void handleCalledOnceAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!isFunctionLike(*T)) {\n S.Diag(AL.getLoc(), diag::err_called_once_attribute_wrong_type);"}}, | [k]={{q,4201,"/// Handle \'called_once\' attribute.\nstatic void handleCalledOnceAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (!isFunctionLike(*T)) {\n S.Diag(AL.getLoc(), diag::err_called_once_attribute_wrong_type);"}}, | ||
[o]={ | [o]={ | ||
Line 7,280: | Line 7,300: | ||
}, | }, | ||
["err_cannot_find_suitable_accessor"]={ | ["err_cannot_find_suitable_accessor"]={ | ||
[ | [e]="cannot find suitable ... for property A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot find suitable %select{getter|setter}0 for property %1", | ||
[ | [b]=n, | ||
[ | [j]="cannot find suitable (?:getter|setter) for property (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Xb,1480718311,gb,gb}, | ||
[k]={{"clang/lib/Sema/SemaPseudoObject.cpp",1487,"ExprResult MSPropertyOpBuilder::buildGet() {\n if (GetterExpr.isInvalid()) {\n S.Diag(RefExpr->getMemberLoc(), diag::err_cannot_find_suitable_accessor) << 0 /* getter */"},{"clang/lib/Sema/SemaPseudoObject.cpp",1516,"ExprResult MSPropertyOpBuilder::buildSet(Expr *op, SourceLocation sl, bool captureSetValueAsResult) {\n if (SetterExpr.isInvalid()) {\n S.Diag(RefExpr->getMemberLoc(), diag::err_cannot_find_suitable_accessor) << 1 /* setter */"}}, | [k]={{"clang/lib/Sema/SemaPseudoObject.cpp",1487,"ExprResult MSPropertyOpBuilder::buildGet() {\n if (GetterExpr.isInvalid()) {\n S.Diag(RefExpr->getMemberLoc(), diag::err_cannot_find_suitable_accessor) << 0 /* getter */"},{"clang/lib/Sema/SemaPseudoObject.cpp",1516,"ExprResult MSPropertyOpBuilder::buildSet(Expr *op, SourceLocation sl, bool captureSetValueAsResult) {\n if (SetterExpr.isInvalid()) {\n S.Diag(RefExpr->getMemberLoc(), diag::err_cannot_find_suitable_accessor) << 1 /* setter */"}}, | ||
[o]={ | [o]={ | ||
Line 7,295: | Line 7,315: | ||
}, | }, | ||
["err_cannot_form_pointer_to_member_of_reference_type"]={ | ["err_cannot_form_pointer_to_member_of_reference_type"]={ | ||
[ | [e]="cannot form a pointer-to-member to member A of reference type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot form a pointer-to-member to member %0 of reference type %1", | ||
[ | [b]=n, | ||
[ | [j]="cannot form a pointer\\-to\\-member to member (.*?) of reference type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"0b675f5ad5b6",1247089558,"It\'s not allowed to form member pointers to members that have reference type. Add a test for this an...","It\'s not allowed to form member pointers to members that have reference type. Add a test for this and the rest of [dcl.mptr]p3."}, | ||
[k]={{ | [k]={{A,15062,"/// CheckAddressOfOperand - The operand of & must be either a function\n/// designator or an lvalue designating an object. If it is an lvalue, the\n/// object cannot be declared with storage class register or be a bit field.\n/// Note: The usual conversions are *not* applied to the operand of the &\n/// operator (C99 6.3.2.1p[2-4]), and its result is never an lvalue.\n/// In C++, the operand might be an overloaded function name, in which case\n/// we allow the \'&\' but retain the overloaded-function type.\nQualType Sema::CheckAddressOfOperand(ExprResult &OrigOp, SourceLocation OpLoc) {\n if (lval == Expr::LV_ClassTemporary || lval == Expr::LV_ArrayTemporary) {\n } else if (isa<ObjCSelectorExpr>(op)) {\n } else if (lval == Expr::LV_MemberFunction) {\n } else if (lval != Expr::LV_Valid && lval != Expr::LV_IncompleteVoidType) {\n } else if (op->getObjectKind() == OK_BitField) { // C99 6.5.3.2p1\n } else if (op->getObjectKind() == OK_VectorComponent) {\n } else if (op->getObjectKind() == OK_MatrixComponent) {\n } else if (dcl) { // C99 6.5.3.2p1\n // We have an lvalue with a decl. Make sure the decl is not declared\n // with the register storage-class specifier.\n if (const VarDecl *vd = dyn_cast<VarDecl>(dcl)) {\n } else if (isa<MSPropertyDecl>(dcl)) {\n } else if (isa<FunctionTemplateDecl>(dcl)) {\n } else if (isa<FieldDecl>(dcl) || isa<IndirectFieldDecl>(dcl)) {\n // Okay: we can take the address of a field.\n // Could be a pointer to member, though, if there is an explicit\n // scope qualifier for the class.\n if (isa<DeclRefExpr>(op) && cast<DeclRefExpr>(op)->getQualifier()) {\n if (Ctx && Ctx->isRecord()) {\n if (dcl->getType()->isReferenceType()) {\n Diag(OpLoc, diag::err_cannot_form_pointer_to_member_of_reference_type) << dcl->getDeclName() << dcl->getType();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl.decl/dcl.meaning/dcl.mptr/p3.cpp"]={"clang/test/CXX/dcl.decl/dcl.meaning/dcl.mptr/p3.cpp:22:6: error: cannot form a pointer-to-member to member \'i\' of reference type \'int &\'","clang/test/CXX/dcl.decl/dcl.meaning/dcl.mptr/p3.cpp:12:6: error: cannot form a pointer-to-member to member \'i\' of reference type \'int &\'"} | ["clang/test/CXX/dcl.decl/dcl.meaning/dcl.mptr/p3.cpp"]={"clang/test/CXX/dcl.decl/dcl.meaning/dcl.mptr/p3.cpp:22:6: error: cannot form a pointer-to-member to member \'i\' of reference type \'int &\'","clang/test/CXX/dcl.decl/dcl.meaning/dcl.mptr/p3.cpp:12:6: error: cannot form a pointer-to-member to member \'i\' of reference type \'int &\'"} | ||
Line 7,310: | Line 7,330: | ||
}, | }, | ||
["err_cannot_open_file"]={ | ["err_cannot_open_file"]={ | ||
[ | [e]="cannot open file \'A\': B", | ||
[ | [d]=kc, | ||
[ | [f]=mc, | ||
[ | [h]="cannot open file \'%0\': %1", | ||
[ | [b]=jc, | ||
[ | [j]="cannot open file \'(.*?)\'\\: (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"802b77601e50",1268693692,"Introduce a new BufferResult class to act as the return type of","Introduce a new BufferResult class to act as the return type of"}, | ||
[k]={{"clang/lib/Basic/SourceManager.cpp",127,"std::optional<llvm::MemoryBufferRef> ContentCache::getBufferOrNone(DiagnosticsEngine &Diag, FileManager &FM, SourceLocation Loc) const {\n // If we were unable to open the file, then we are in an inconsistent\n // situation where the content cache referenced a file which no longer\n // exists. Most likely, we were using a stat cache with an invalid entry but\n // the file could also have been removed during processing. Since we can\'t\n // really deal with this situation, just create an empty buffer.\n if (!BufferOrError) {\n if (Diag.isDiagnosticInFlight())\n Diag.SetDelayedDiagnostic(diag::err_cannot_open_file, ContentsEntry->getName(), BufferOrError.getError().message());"},{"clang/lib/Basic/SourceManager.cpp",131,"std::optional<llvm::MemoryBufferRef> ContentCache::getBufferOrNone(DiagnosticsEngine &Diag, FileManager &FM, SourceLocation Loc) const {\n // If we were unable to open the file, then we are in an inconsistent\n // situation where the content cache referenced a file which no longer\n // exists. Most likely, we were using a stat cache with an invalid entry but\n // the file could also have been removed during processing. Since we can\'t\n // really deal with this situation, just create an empty buffer.\n if (!BufferOrError) {\n if (Diag.isDiagnosticInFlight())\n else\n Diag.Report(Loc, diag::err_cannot_open_file) << ContentsEntry->getName() << BufferOrError.getError().message();"},{"clang/lib/CodeGen/CGCUDANV.cpp",735,"/// Creates a global constructor function for the module:\n///\n/// For CUDA:\n/// \\code\n/// void __cuda_module_ctor() {\n/// Handle = __cudaRegisterFatBinary(GpuBinaryBlob);\n/// __cuda_register_globals(Handle);\n/// }\n/// \\endcode\n///\n/// For HIP:\n/// \\code\n/// void __hip_module_ctor() {\n/// if (__hip_gpubin_handle == 0) {\n/// __hip_gpubin_handle = __hipRegisterFatBinary(GpuBinaryBlob);\n/// __hip_register_globals(__hip_gpubin_handle);\n/// }\n/// }\n/// \\endcode\nllvm::Function *CGNVCUDARuntime::makeModuleCtorFunction() {\n if (!CudaGpuBinaryFileName.empty()) {\n if (std::error_code EC = CudaGpuBinaryOrErr.getError()) {\n CGM.getDiags().Report(diag::err_cannot_open_file) << CudaGpuBinaryFileName << EC.message();"},{"clang/lib/CodeGen/CodeGenAction.cpp",95,"static void reportOptRecordError(Error E, DiagnosticsEngine &Diags, const CodeGenOptions &CodeGenOpts) {\n handleAllErrors(\n std::move(E), [&](const LLVMRemarkSetupFileError &E) { Diags.Report(diag::err_cannot_open_file) << CodeGenOpts.OptRecordFile << E.message(); }, [&](const LLVMRemarkSetupPatternError &E) { Diags.Report(diag::err_drv_optimization_remark_pattern) << E.message() << CodeGenOpts.OptRecordPasses; }, [&](const LLVMRemarkSetupFormatError &E) { Diags.Report(diag::err_drv_optimization_remark_format) << CodeGenOpts.OptRecordFormat; });"},{"clang/lib/CodeGen/CodeGenAction.cpp",1005,"bool CodeGenAction::loadLinkModules(CompilerInstance &CI) {\n for (const CodeGenOptions::BitcodeFileToLink &F : CI.getCodeGenOpts().LinkBitcodeFiles) {\n if (!BCBuf) {\n CI.getDiagnostics().Report(diag::err_cannot_open_file) << F.Filename << BCBuf.getError().message();"},{"clang/lib/CodeGen/CodeGenAction.cpp",1015,"bool CodeGenAction::loadLinkModules(CompilerInstance &CI) {\n for (const CodeGenOptions::BitcodeFileToLink &F : CI.getCodeGenOpts().LinkBitcodeFiles) {\n if (!ModuleOrErr) {\n handleAllErrors(ModuleOrErr.takeError(), [&](ErrorInfoBase &EIB) { CI.getDiagnostics().Report(diag::err_cannot_open_file) << F.Filename << EIB.message(); });"},{"clang/lib/CodeGen/CodeGenModule.cpp",7440,"void CodeGenModule::printPostfixForExternalizedDecl(llvm::raw_ostream &OS, const Decl *D) const {\n // If the CUID is not specified we try to generate a unique postfix.\n if (getLangOpts().CUID.empty()) {\n if (auto EC = llvm::sys::fs::getUniqueID(PLoc.getFilename(), ID)) {\n if (auto EC = llvm::sys::fs::getUniqueID(PLoc.getFilename(), ID))\n SM.getDiagnostics().Report(diag::err_cannot_open_file) << PLoc.getFilename() << EC.message();"},{"clang/lib/Lex/HeaderSearch.cpp",432,"OptionalFileEntryRef HeaderSearch::getFileAndSuggestModule(StringRef FileName, SourceLocation IncludeLoc, const DirectoryEntry *Dir, bool IsSystemHeaderDir, Module *RequestingModule, ModuleMap::KnownHeader *SuggestedModule, bool OpenFile /*=true*/, bool CacheFailures /*=true*/) {\n if (!File) {\n if (EC != llvm::errc::no_such_file_or_directory && EC != llvm::errc::invalid_argument && EC != llvm::errc::is_a_directory && EC != llvm::errc::not_a_directory) {\n Diags.Report(IncludeLoc, diag::err_cannot_open_file) << FileName << EC.message();"},{"clang/unittests/Basic/DiagnosticTest.cpp",45,"// Check that DiagnosticErrorTrap works with SuppressAllDiagnostics.\nTEST(DiagnosticTest, suppressAndTrap) {\n {\n Diags.Report(diag::err_cannot_open_file) << \"file\""},{"clang/unittests/Basic/DiagnosticTest.cpp",70,"// Check that FatalsAsError works as intended\nTEST(DiagnosticTest, fatalsAsError) {\n for (unsigned FatalsAsError = 0; FatalsAsError != 2; ++FatalsAsError) {\n Diags.Report(diag::err_cannot_open_file) << \"file\""},{"clang/unittests/Basic/DiagnosticTest.cpp",117,"TEST(DiagnosticTest, diagnosticError) {\n llvm::Expected<std::pair<int, int>> Value = DiagnosticError::create(SourceLocation(), PartialDiagnostic(diag::err_cannot_open_file, Alloc) << \"file\""},{"clang/unittests/Basic/DiagnosticTest.cpp",126,"TEST(DiagnosticTest, diagnosticError) {\n EXPECT_EQ(ErrDiag->second.getDiagID(), diag::err_cannot_open_file);"}}, | [k]={{"clang/lib/Basic/SourceManager.cpp",127,"std::optional<llvm::MemoryBufferRef> ContentCache::getBufferOrNone(DiagnosticsEngine &Diag, FileManager &FM, SourceLocation Loc) const {\n // If we were unable to open the file, then we are in an inconsistent\n // situation where the content cache referenced a file which no longer\n // exists. Most likely, we were using a stat cache with an invalid entry but\n // the file could also have been removed during processing. Since we can\'t\n // really deal with this situation, just create an empty buffer.\n if (!BufferOrError) {\n if (Diag.isDiagnosticInFlight())\n Diag.SetDelayedDiagnostic(diag::err_cannot_open_file, ContentsEntry->getName(), BufferOrError.getError().message());"},{"clang/lib/Basic/SourceManager.cpp",131,"std::optional<llvm::MemoryBufferRef> ContentCache::getBufferOrNone(DiagnosticsEngine &Diag, FileManager &FM, SourceLocation Loc) const {\n // If we were unable to open the file, then we are in an inconsistent\n // situation where the content cache referenced a file which no longer\n // exists. Most likely, we were using a stat cache with an invalid entry but\n // the file could also have been removed during processing. Since we can\'t\n // really deal with this situation, just create an empty buffer.\n if (!BufferOrError) {\n if (Diag.isDiagnosticInFlight())\n else\n Diag.Report(Loc, diag::err_cannot_open_file) << ContentsEntry->getName() << BufferOrError.getError().message();"},{"clang/lib/CodeGen/CGCUDANV.cpp",735,"/// Creates a global constructor function for the module:\n///\n/// For CUDA:\n/// \\code\n/// void __cuda_module_ctor() {\n/// Handle = __cudaRegisterFatBinary(GpuBinaryBlob);\n/// __cuda_register_globals(Handle);\n/// }\n/// \\endcode\n///\n/// For HIP:\n/// \\code\n/// void __hip_module_ctor() {\n/// if (__hip_gpubin_handle == 0) {\n/// __hip_gpubin_handle = __hipRegisterFatBinary(GpuBinaryBlob);\n/// __hip_register_globals(__hip_gpubin_handle);\n/// }\n/// }\n/// \\endcode\nllvm::Function *CGNVCUDARuntime::makeModuleCtorFunction() {\n if (!CudaGpuBinaryFileName.empty()) {\n if (std::error_code EC = CudaGpuBinaryOrErr.getError()) {\n CGM.getDiags().Report(diag::err_cannot_open_file) << CudaGpuBinaryFileName << EC.message();"},{"clang/lib/CodeGen/CodeGenAction.cpp",95,"static void reportOptRecordError(Error E, DiagnosticsEngine &Diags, const CodeGenOptions &CodeGenOpts) {\n handleAllErrors(\n std::move(E), [&](const LLVMRemarkSetupFileError &E) { Diags.Report(diag::err_cannot_open_file) << CodeGenOpts.OptRecordFile << E.message(); }, [&](const LLVMRemarkSetupPatternError &E) { Diags.Report(diag::err_drv_optimization_remark_pattern) << E.message() << CodeGenOpts.OptRecordPasses; }, [&](const LLVMRemarkSetupFormatError &E) { Diags.Report(diag::err_drv_optimization_remark_format) << CodeGenOpts.OptRecordFormat; });"},{"clang/lib/CodeGen/CodeGenAction.cpp",1005,"bool CodeGenAction::loadLinkModules(CompilerInstance &CI) {\n for (const CodeGenOptions::BitcodeFileToLink &F : CI.getCodeGenOpts().LinkBitcodeFiles) {\n if (!BCBuf) {\n CI.getDiagnostics().Report(diag::err_cannot_open_file) << F.Filename << BCBuf.getError().message();"},{"clang/lib/CodeGen/CodeGenAction.cpp",1015,"bool CodeGenAction::loadLinkModules(CompilerInstance &CI) {\n for (const CodeGenOptions::BitcodeFileToLink &F : CI.getCodeGenOpts().LinkBitcodeFiles) {\n if (!ModuleOrErr) {\n handleAllErrors(ModuleOrErr.takeError(), [&](ErrorInfoBase &EIB) { CI.getDiagnostics().Report(diag::err_cannot_open_file) << F.Filename << EIB.message(); });"},{"clang/lib/CodeGen/CodeGenModule.cpp",7440,"void CodeGenModule::printPostfixForExternalizedDecl(llvm::raw_ostream &OS, const Decl *D) const {\n // If the CUID is not specified we try to generate a unique postfix.\n if (getLangOpts().CUID.empty()) {\n if (auto EC = llvm::sys::fs::getUniqueID(PLoc.getFilename(), ID)) {\n if (auto EC = llvm::sys::fs::getUniqueID(PLoc.getFilename(), ID))\n SM.getDiagnostics().Report(diag::err_cannot_open_file) << PLoc.getFilename() << EC.message();"},{"clang/lib/Lex/HeaderSearch.cpp",432,"OptionalFileEntryRef HeaderSearch::getFileAndSuggestModule(StringRef FileName, SourceLocation IncludeLoc, const DirectoryEntry *Dir, bool IsSystemHeaderDir, Module *RequestingModule, ModuleMap::KnownHeader *SuggestedModule, bool OpenFile /*=true*/, bool CacheFailures /*=true*/) {\n if (!File) {\n if (EC != llvm::errc::no_such_file_or_directory && EC != llvm::errc::invalid_argument && EC != llvm::errc::is_a_directory && EC != llvm::errc::not_a_directory) {\n Diags.Report(IncludeLoc, diag::err_cannot_open_file) << FileName << EC.message();"},{"clang/unittests/Basic/DiagnosticTest.cpp",45,"// Check that DiagnosticErrorTrap works with SuppressAllDiagnostics.\nTEST(DiagnosticTest, suppressAndTrap) {\n {\n Diags.Report(diag::err_cannot_open_file) << \"file\""},{"clang/unittests/Basic/DiagnosticTest.cpp",70,"// Check that FatalsAsError works as intended\nTEST(DiagnosticTest, fatalsAsError) {\n for (unsigned FatalsAsError = 0; FatalsAsError != 2; ++FatalsAsError) {\n Diags.Report(diag::err_cannot_open_file) << \"file\""},{"clang/unittests/Basic/DiagnosticTest.cpp",117,"TEST(DiagnosticTest, diagnosticError) {\n llvm::Expected<std::pair<int, int>> Value = DiagnosticError::create(SourceLocation(), PartialDiagnostic(diag::err_cannot_open_file, Alloc) << \"file\""},{"clang/unittests/Basic/DiagnosticTest.cpp",126,"TEST(DiagnosticTest, diagnosticError) {\n EXPECT_EQ(ErrDiag->second.getDiagID(), diag::err_cannot_open_file);"}}, | ||
[o]={ | [o]={ | ||
Line 7,325: | Line 7,345: | ||
}, | }, | ||
["err_cannot_pass_non_trivial_c_struct_to_vararg"]={ | ["err_cannot_pass_non_trivial_c_struct_to_vararg"]={ | ||
[ | [e]="cannot pass non-trivial C object of type A by value to variadic ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot pass non-trivial C object of type %0 by value to variadic %select{function|block|method|constructor}1", | ||
[ | [b]=n, | ||
[ | [j]="cannot pass non\\-trivial C object of type (.*?) by value to variadic (?:function|block|method|constructor)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"7275da0f2ee2",1519802155,"[ObjC] Allow declaring __strong pointer fields in structs in Objective-C","[ObjC] Allow declaring __strong pointer fields in structs in Objective-C"}, | ||
[k]={{ | [k]={{A,1020,"void Sema::checkVariadicArgument(const Expr *E, VariadicCallType CT) {\n case VAK_Invalid:\n if (Ty.isDestructedType() == QualType::DK_nontrivial_c_struct)\n Diag(E->getBeginLoc(), diag::err_cannot_pass_non_trivial_c_struct_to_vararg) << Ty << CT;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/strong-in-c-struct.m"]={"clang/test/SemaObjC/strong-in-c-struct.m:11:24: error: cannot pass non-trivial C object of type \'Strong\' by value to variadic function"} | ["clang/test/SemaObjC/strong-in-c-struct.m"]={"clang/test/SemaObjC/strong-in-c-struct.m:11:24: error: cannot pass non-trivial C object of type \'Strong\' by value to variadic function"} | ||
Line 7,340: | Line 7,360: | ||
}, | }, | ||
["err_cannot_pass_objc_interface_to_vararg"]={ | ["err_cannot_pass_objc_interface_to_vararg"]={ | ||
[ | [e]="cannot pass object with interface type A by value through variadic ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot pass object with interface type %0 by value through variadic %select{function|block|method|constructor}1", | ||
[ | [b]=n, | ||
[ | [j]="cannot pass object with interface type (.*?) by value through variadic (?:function|block|method|constructor)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"a8a7d0f37161",1239523880,"implement rdar://6780761, making sema reject some code that otherwise","implement rdar://6780761, making sema reject some code that otherwise"}, | ||
[k]={{ | [k]={{A,1024,"void Sema::checkVariadicArgument(const Expr *E, VariadicCallType CT) {\n case VAK_Invalid:\n if (Ty.isDestructedType() == QualType::DK_nontrivial_c_struct)\n else if (Ty->isObjCObjectType())\n DiagRuntimeBehavior(E->getBeginLoc(), nullptr, PDiag(diag::err_cannot_pass_objc_interface_to_vararg) << Ty << CT);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/method-bad-param.m"]={"clang/test/SemaObjC/method-bad-param.m:35:9: error: cannot pass object with interface type \'foo\' by value through variadic function"} | ["clang/test/SemaObjC/method-bad-param.m"]={"clang/test/SemaObjC/method-bad-param.m:35:9: error: cannot pass object with interface type \'foo\' by value through variadic function"} | ||
Line 7,355: | Line 7,375: | ||
}, | }, | ||
["err_cannot_pass_objc_interface_to_vararg_format"]={ | ["err_cannot_pass_objc_interface_to_vararg_format"]={ | ||
[ | [e]="cannot pass object with interface type A by value to variadic ...; expected type from format string was B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot pass object with interface type %1 by value to variadic %select{function|block|method|constructor}2; expected type from format string was %3", | ||
[ | [b]=n, | ||
[ | [j]="cannot pass object with interface type (.*?) by value to variadic (?:function|block|method|constructor); expected type from format string was (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3e0ec58c09eb",1342721423,"For varargs, diagnose passing ObjC objects by value like other non-POD types.","For varargs, diagnose passing ObjC objects by value like other non-POD types."}, | ||
[k]={{ | [k]={{u,11399,"bool CheckPrintfHandler::checkFormatExpr(const analyze_printf::PrintfSpecifier &FS, const char *StartSpecifier, unsigned SpecifierLen, const Expr *E) {\n if (Success) {\n } else {\n case Sema::VAK_Invalid:\n if (CallType == Sema::VariadicDoesNotApply)\n else if (ExprTy->isObjCObjectType())\n EmitFormatDiagnostic(S.PDiag(diag::err_cannot_pass_objc_interface_to_vararg_format) << S.getLangOpts().CPlusPlus11 << ExprTy << CallType << AT.getRepresentativeTypeName(S.Context) << CSR << E->getSourceRange(), E->getBeginLoc(), /*IsStringLocation*/ false, CSR);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/format-strings-objc.m"]={"clang/test/SemaObjC/format-strings-objc.m:262:26: error: cannot pass object with interface type \'Foo\' by value to variadic function; expected type from format string was \'int\'","clang/test/SemaObjC/format-strings-objc.m:266:20: error: cannot pass object with interface type \'Foo\' by value to variadic method; expected type from format string was \'int\'"} | ["clang/test/SemaObjC/format-strings-objc.m"]={"clang/test/SemaObjC/format-strings-objc.m:262:26: error: cannot pass object with interface type \'Foo\' by value to variadic function; expected type from format string was \'int\'","clang/test/SemaObjC/format-strings-objc.m:266:20: error: cannot pass object with interface type \'Foo\' by value to variadic method; expected type from format string was \'int\'"} | ||
Line 7,370: | Line 7,390: | ||
}, | }, | ||
["err_cannot_pass_to_vararg"]={ | ["err_cannot_pass_to_vararg"]={ | ||
[ | [e]="cannot pass ... to variadic ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot pass %select{expression of type %1|initializer list}0 to variadic %select{function|block|method|constructor}2", | ||
[ | [b]=n, | ||
[ | [j]="cannot pass (?:expression of type (.*?)|initializer list) to variadic (?:function|block|method|constructor)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"d7293d7fcb60",1375728583,"Implement C++\'s restrictions on the type of an expression passed to a vararg","Implement C++\'s restrictions on the type of an expression passed to a vararg"}, | ||
[k]={{ | [k]={{A,1027,"void Sema::checkVariadicArgument(const Expr *E, VariadicCallType CT) {\n case VAK_Invalid:\n if (Ty.isDestructedType() == QualType::DK_nontrivial_c_struct)\n else if (Ty->isObjCObjectType())\n else\n Diag(E->getBeginLoc(), diag::err_cannot_pass_to_vararg) << isa<InitListExpr>(E) << Ty << CT;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/format-strings-0x.cpp"]={"clang/test/SemaCXX/format-strings-0x.cpp:34:13: error: cannot pass initializer list to variadic function"} | ["clang/test/SemaCXX/format-strings-0x.cpp"]={"clang/test/SemaCXX/format-strings-0x.cpp:34:13: error: cannot pass initializer list to variadic function"} | ||
Line 7,385: | Line 7,405: | ||
}, | }, | ||
["err_cannot_pass_to_vararg_format"]={ | ["err_cannot_pass_to_vararg_format"]={ | ||
[ | [e]="cannot pass ... to variadic ...; expected type from format string was A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot pass %select{expression of type %1|initializer list}0 to variadic %select{function|block|method|constructor}2; expected type from format string was %3", | ||
[ | [b]=n, | ||
[ | [j]="cannot pass (?:expression of type (.*?)|initializer list) to variadic (?:function|block|method|constructor); expected type from format string was (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"d7293d7fcb60",1375728583,"Implement C++\'s restrictions on the type of an expression passed to a vararg","Implement C++\'s restrictions on the type of an expression passed to a vararg"}, | ||
[k]={{ | [k]={{u,11407,"bool CheckPrintfHandler::checkFormatExpr(const analyze_printf::PrintfSpecifier &FS, const char *StartSpecifier, unsigned SpecifierLen, const Expr *E) {\n if (Success) {\n } else {\n case Sema::VAK_Invalid:\n if (CallType == Sema::VariadicDoesNotApply)\n else if (ExprTy->isObjCObjectType())\n else\n S.Diag(E->getBeginLoc(), diag::err_cannot_pass_to_vararg_format) << isa<InitListExpr>(E) << ExprTy << CallType << AT.getRepresentativeTypeName(S.Context) << E->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/format-strings-0x.cpp"]={"clang/test/SemaCXX/format-strings-0x.cpp:32:27: error: cannot pass initializer list to variadic function; expected type from format string was \'int\'","clang/test/SemaCXX/format-strings-0x.cpp:33:22: error: cannot pass expression of type \'void\' to variadic function; expected type from format string was \'int\'"} | ["clang/test/SemaCXX/format-strings-0x.cpp"]={"clang/test/SemaCXX/format-strings-0x.cpp:32:27: error: cannot pass initializer list to variadic function; expected type from format string was \'int\'","clang/test/SemaCXX/format-strings-0x.cpp:33:22: error: cannot pass expression of type \'void\' to variadic function; expected type from format string was \'int\'"} | ||
Line 7,400: | Line 7,420: | ||
}, | }, | ||
["err_capture_bad_target"]={ | ["err_capture_bad_target"]={ | ||
[ | [e]="capture host variable A by reference in device or host device lambda function", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="capture host variable %0 by reference in device or host device lambda function", | ||
[ | [b]=n, | ||
[ | [j]="capture host variable (.*?) by reference in device or host device lambda function", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={cb,1582847864,I,I}, | ||
[k]={{"clang/lib/Sema/SemaCUDA.cpp",883,"// Check the wrong-sided reference capture of lambda for CUDA/HIP.\n// A lambda function may capture a stack variable by reference when it is\n// defined and uses the capture by reference when the lambda is called. When\n// the capture and use happen on different sides, the capture is invalid and\n// should be diagnosed.\nvoid Sema::CUDACheckLambdaCapture(CXXMethodDecl *Callee, const sema::Capture &Capture) {\n if (Capture.isVariableCapture()) {\n SemaDiagnosticBuilder(DiagKind, Capture.getLocation(), diag::err_capture_bad_target, Callee, *this) << Capture.getVariable();"}}, | [k]={{"clang/lib/Sema/SemaCUDA.cpp",883,"// Check the wrong-sided reference capture of lambda for CUDA/HIP.\n// A lambda function may capture a stack variable by reference when it is\n// defined and uses the capture by reference when the lambda is called. When\n// the capture and use happen on different sides, the capture is invalid and\n// should be diagnosed.\nvoid Sema::CUDACheckLambdaCapture(CXXMethodDecl *Callee, const sema::Capture &Capture) {\n if (Capture.isVariableCapture()) {\n SemaDiagnosticBuilder(DiagKind, Capture.getLocation(), diag::err_capture_bad_target, Callee, *this) << Capture.getVariable();"}}, | ||
[o]={ | [o]={ | ||
Line 7,415: | Line 7,435: | ||
}, | }, | ||
["err_capture_binding_openmp"]={ | ["err_capture_binding_openmp"]={ | ||
[e]="capturing a structured binding is not yet supported in OpenMP", | |||
[d]=l, | |||
[f]=m, | |||
[h]="capturing a structured binding is not yet supported in OpenMP", | [h]="capturing a structured binding is not yet supported in OpenMP", | ||
[ | [b]=n, | ||
[ | [j]="capturing a structured binding is not yet supported in OpenMP", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={R,1625925174,B,B}, | |||
[ | [k]={{A,19347,"/// 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 // FIXME: We should support capturing structured bindings in OpenMP.\n if (!Invalid && BD && S.LangOpts.OpenMP) {\n if (BuildAndDiagnose) {\n S.Diag(Loc, diag::err_capture_binding_openmp) << Var;"}}, | ||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/decomposition-openmp.cpp"]={"clang/test/SemaCXX/decomposition-openmp.cpp:8:15: error: capturing a structured binding is not yet supported in OpenMP","clang/test/SemaCXX/decomposition-openmp.cpp:10:16: error: capturing a structured binding is not yet supported in OpenMP"} | ["clang/test/SemaCXX/decomposition-openmp.cpp"]={"clang/test/SemaCXX/decomposition-openmp.cpp:8:15: error: capturing a structured binding is not yet supported in OpenMP","clang/test/SemaCXX/decomposition-openmp.cpp:10:16: error: capturing a structured binding is not yet supported in OpenMP"} | ||
Line 7,430: | Line 7,450: | ||
}, | }, | ||
["err_capture_block_variable"]={ | ["err_capture_block_variable"]={ | ||
[ | [e]="__block variable A cannot be captured in a ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="__block variable %0 cannot be captured in a %select{lambda expression|captured statement}1", | ||
[ | [b]=n, | ||
[ | [j]="__block variable (.*?) cannot be captured in a (?:lambda expression|captured statement)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3b4c30b7e77e",1368127031,"CodeGen for CapturedStmts","CodeGen for CapturedStmts"}, | ||
[k]={{ | [k]={{A,19189,"// Certain capturing entities (lambdas, blocks etc.) are not allowed to capture\n// certain types of variables (unnamed, variably modified types etc.)\n// so check for eligibility.\nstatic bool isVariableCapturable(CapturingScopeInfo *CSI, ValueDecl *Var, SourceLocation Loc, const bool Diagnose, Sema &S) {\n // Lambdas and captured statements are not allowed to capture __block\n // variables; they don\'t support the expected semantics.\n if (HasBlocksAttr && (IsLambda || isa<CapturedRegionScopeInfo>(CSI))) {\n if (Diagnose) {\n S.Diag(Loc, diag::err_capture_block_variable) << Var << !IsLambda;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/captured-statements.c"]={"clang/test/Sema/captured-statements.c:58:7: error: __block variable \'x\' cannot be captured in a captured statement","clang/test/Sema/captured-statements.c:70:7: error: __block variable \'a\' cannot be captured in a captured statement","clang/test/Sema/captured-statements.c:80:11: error: __block variable \'a\' cannot be captured in a captured statement"} | ["clang/test/Sema/captured-statements.c"]={"clang/test/Sema/captured-statements.c:58:7: error: __block variable \'x\' cannot be captured in a captured statement","clang/test/Sema/captured-statements.c:70:7: error: __block variable \'a\' cannot be captured in a captured statement","clang/test/Sema/captured-statements.c:80:11: error: __block variable \'a\' cannot be captured in a captured statement"} | ||
Line 7,445: | Line 7,465: | ||
}, | }, | ||
["err_capture_default_first"]={ | ["err_capture_default_first"]={ | ||
[e]="capture default must be first", | |||
[d]=l, | |||
[f]=m, | |||
[h]="capture default must be first", | [h]="capture default must be first", | ||
[ | [b]=n, | ||
[ | [j]="capture default must be first", | ||
[c]=a, | |||
[ | [i]=D, | ||
[g]={"ee05167cc42b",1594102083,"[OpenMP] Allow traits for the OpenMP context selector `isa`","[OpenMP] Allow traits for the OpenMP context selector `isa`"}, | |||
[ | |||
[ | |||
[k]={{"clang/lib/Parse/ParseExprCXX.cpp",945,"/// Parse a lambda introducer.\n/// \\param Intro A LambdaIntroducer filled in with information about the\n/// contents of the lambda-introducer.\n/// \\param Tentative If non-null, we are disambiguating between a\n/// lambda-introducer and some other construct. In this mode, we do not\n/// produce any diagnostics or take any other irreversible action unless\n/// we\'re sure that this is a lambda-expression.\n/// \\return \\c true if parsing (or disambiguation) failed with a diagnostic and\n/// the caller should bail out / recover.\nbool Parser::ParseLambdaIntroducer(LambdaIntroducer &Intro, LambdaIntroducerTentativeParse *Tentative) {\n while (Tok.isNot(tok::r_square)) {\n if (Tok.is(tok::star)) {\n } else if (Tok.is(tok::kw_this)) {\n } else if (Tok.isOneOf(tok::amp, tok::equal) && NextToken().isOneOf(tok::comma, tok::r_square) && Intro.Default == LCD_None) {\n return Invalid([&] { Diag(Tok.getLocation(), diag::err_capture_default_first); });"}}, | [k]={{"clang/lib/Parse/ParseExprCXX.cpp",945,"/// Parse a lambda introducer.\n/// \\param Intro A LambdaIntroducer filled in with information about the\n/// contents of the lambda-introducer.\n/// \\param Tentative If non-null, we are disambiguating between a\n/// lambda-introducer and some other construct. In this mode, we do not\n/// produce any diagnostics or take any other irreversible action unless\n/// we\'re sure that this is a lambda-expression.\n/// \\return \\c true if parsing (or disambiguation) failed with a diagnostic and\n/// the caller should bail out / recover.\nbool Parser::ParseLambdaIntroducer(LambdaIntroducer &Intro, LambdaIntroducerTentativeParse *Tentative) {\n while (Tok.isNot(tok::r_square)) {\n if (Tok.is(tok::star)) {\n } else if (Tok.is(tok::kw_this)) {\n } else if (Tok.isOneOf(tok::amp, tok::equal) && NextToken().isOneOf(tok::comma, tok::r_square) && Intro.Default == LCD_None) {\n return Invalid([&] { Diag(Tok.getLocation(), diag::err_capture_default_first); });"}}, | ||
[o]={ | [o]={ | ||
Line 7,460: | Line 7,480: | ||
}, | }, | ||
["err_capture_default_non_local"]={ | ["err_capture_default_non_local"]={ | ||
[e]="non-local lambda expression cannot have a capture-default", | |||
[d]=l, | |||
[f]=m, | |||
[h]="non-local lambda expression cannot have a capture-default", | [h]="non-local lambda expression cannot have a capture-default", | ||
[ | [b]=n, | ||
[ | [j]="non\\-local lambda expression cannot have a capture\\-default", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"3d584b0ced40",1391723348,"PR18128: a lambda capture-default is not permitted for a non-local lambda","PR18128: a lambda capture-default is not permitted for a non-local lambda"}, | |||
[ | [k]={{Fb,1247,"void Sema::ActOnLambdaClosureQualifiers(LambdaIntroducer &Intro, SourceLocation MutableLoc) {\n // C++11 [expr.prim.lambda]p9:\n // A lambda-expression whose smallest enclosing scope is a block scope is a\n // local lambda expression; any other lambda expression shall not have a\n // capture-default or simple-capture in its lambda-introducer.\n //\n // For simple-captures, this is covered by the check below that any named\n // entity is a variable that can be captured.\n //\n // For DR1632, we also allow a capture-default in any context where we can\n // odr-use \'this\' (in particular, in a default initializer for a non-static\n // data member).\n if (Intro.Default != LCD_None && !LSI->Lambda->getParent()->isFunctionOrMethod() &&\n Diag(Intro.DefaultLoc, diag::err_capture_default_non_local);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/lambda-expressions.cpp"]={"clang/test/SemaCXX/lambda-expressions.cpp:330:13: error: non-local lambda expression cannot have a capture-default","clang/test/SemaCXX/lambda-expressions.cpp:365:13: error: non-local lambda expression cannot have a capture-default","clang/test/SemaCXX/lambda-expressions.cpp:369:29: error: non-local lambda expression cannot have a capture-default","clang/test/SemaCXX/lambda-expressions.cpp:373:21: error: non-local lambda expression cannot have a capture-default"} | ["clang/test/SemaCXX/lambda-expressions.cpp"]={"clang/test/SemaCXX/lambda-expressions.cpp:330:13: error: non-local lambda expression cannot have a capture-default","clang/test/SemaCXX/lambda-expressions.cpp:365:13: error: non-local lambda expression cannot have a capture-default","clang/test/SemaCXX/lambda-expressions.cpp:369:29: error: non-local lambda expression cannot have a capture-default","clang/test/SemaCXX/lambda-expressions.cpp:373:21: error: non-local lambda expression cannot have a capture-default"} | ||
Line 7,475: | Line 7,495: | ||
}, | }, | ||
["err_capture_does_not_name_variable"]={ | ["err_capture_does_not_name_variable"]={ | ||
[ | [e]="A in capture list does not name a variable", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 in capture list does not name a variable", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) in capture list does not name a variable", | ||
[ | [c]=a, | ||
[ | [i]="Lambda Issue", | ||
[ | [g]={"44803326d4e8",1325898497,Pb,Pb}, | ||
[k]={{ | [k]={{Fb,1157,"void Sema::ActOnLambdaExpressionAfterIntroducer(LambdaIntroducer &Intro, Scope *CurrentScope) {\n for (auto C = Intro.Captures.begin(), E = Intro.Captures.end(); C != E; PrevCaptureLoc = C->Loc, ++C) {\n // C++11 [expr.prim.lambda]p10:\n // [...] each such lookup shall find a variable with automatic storage\n // duration declared in the reaching scope of the local lambda expression.\n // Note that the \'reaching scope\' check happens in tryCaptureVariable().\n if (!Var) {\n Diag(C->Loc, diag::err_capture_does_not_name_variable) << C->Id;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp:20:13: error: \'Overload\' in capture list does not name a variable"} | ["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp:20:13: error: \'Overload\' in capture list does not name a variable"} | ||
Line 7,490: | Line 7,510: | ||
}, | }, | ||
["err_capture_more_than_once"]={ | ["err_capture_more_than_once"]={ | ||
[ | [e]="A can appear only once in a capture list", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 can appear only once in a capture list", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) can appear only once in a capture list", | ||
[ | [c]=a, | ||
[ | [i]="Lambda Issue", | ||
[ | [g]={"44803326d4e8",1325898497,Pb,Pb}, | ||
[k]={{ | [k]={{Fb,1029,"void Sema::ActOnLambdaExpressionAfterIntroducer(LambdaIntroducer &Intro, Scope *CurrentScope) {\n for (auto C = Intro.Captures.begin(), E = Intro.Captures.end(); C != E; PrevCaptureLoc = C->Loc, ++C) {\n if (C->Kind == LCK_This || C->Kind == LCK_StarThis) {\n // C++11 [expr.prim.lambda]p8:\n // An identifier or this shall not appear more than once in a\n // lambda-capture.\n if (LSI->isCXXThisCaptured()) {\n Diag(C->Loc, diag::err_capture_more_than_once) << \"\'this\'\" << SourceRange(LSI->getCXXThisCapture().getLocation()) << FixItHint::CreateRemoval(SourceRange(getLocForEndOfToken(PrevCaptureLoc), C->Loc));"},{Fb,1168,"void Sema::ActOnLambdaExpressionAfterIntroducer(LambdaIntroducer &Intro, Scope *CurrentScope) {\n for (auto C = Intro.Captures.begin(), E = Intro.Captures.end(); C != E; PrevCaptureLoc = C->Loc, ++C) {\n // C++11 [expr.prim.lambda]p8:\n // An identifier or this shall not appear more than once in a\n // lambda-capture.\n if (auto [It, Inserted] = CaptureNames.insert(std::pair{C->Id, Var}); !Inserted) {\n if (C->InitKind == LambdaCaptureInitKind::NoInit && !Var->isInitCapture()) {\n Diag(C->Loc, diag::err_capture_more_than_once) << C->Id << It->second->getBeginLoc() << FixItHint::CreateRemoval(SourceRange(getLocForEndOfToken(PrevCaptureLoc), C->Loc));"},{Fb,1175,"void Sema::ActOnLambdaExpressionAfterIntroducer(LambdaIntroducer &Intro, Scope *CurrentScope) {\n for (auto C = Intro.Captures.begin(), E = Intro.Captures.end(); C != E; PrevCaptureLoc = C->Loc, ++C) {\n // C++11 [expr.prim.lambda]p8:\n // An identifier or this shall not appear more than once in a\n // lambda-capture.\n if (auto [It, Inserted] = CaptureNames.insert(std::pair{C->Id, Var}); !Inserted) {\n if (C->InitKind == LambdaCaptureInitKind::NoInit && !Var->isInitCapture()) {\n } else\n Diag(C->Loc, diag::err_capture_more_than_once) << C->Id;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:7:17: error: \'foo\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:8:18: error: \'this\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:28:13: error: \'i\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:29:16: error: \'i\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:30:13: error: \'i\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:31:16: error: \'i\' can appear only once in a capture list"} | ["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:7:17: error: \'foo\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:8:18: error: \'this\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:28:13: error: \'i\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:29:16: error: \'i\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:30:13: error: \'i\' can appear only once in a capture list","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp:31:16: error: \'i\' can appear only once in a capture list"} | ||
Line 7,505: | Line 7,525: | ||
}, | }, | ||
["err_capture_non_automatic_variable"]={ | ["err_capture_non_automatic_variable"]={ | ||
[ | [e]="A cannot be captured because it does not have automatic storage duration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 cannot be captured because it does not have automatic storage duration", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) cannot be captured because it does not have automatic storage duration", | ||
[ | [c]=a, | ||
[ | [i]="Lambda Issue", | ||
[ | [g]={"44803326d4e8",1325898497,Pb,Pb}, | ||
[k]={{ | [k]={{Fb,1186,"void Sema::ActOnLambdaExpressionAfterIntroducer(LambdaIntroducer &Intro, Scope *CurrentScope) {\n for (auto C = Intro.Captures.begin(), E = Intro.Captures.end(); C != E; PrevCaptureLoc = C->Loc, ++C) {\n if (!Underlying->hasLocalStorage()) {\n Diag(C->Loc, diag::err_capture_non_automatic_variable) << C->Id;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp:21:13: error: \'GlobalVar\' cannot be captured because it does not have automatic storage duration","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp:34:16: error: \'local_static\' cannot be captured because it does not have automatic storage duration"} | ["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp:21:13: error: \'GlobalVar\' cannot be captured because it does not have automatic storage duration","clang/test/CXX/expr/expr.prim/expr.prim.lambda/p10.cpp:34:16: error: \'local_static\' cannot be captured because it does not have automatic storage duration"} | ||
Line 7,520: | Line 7,540: | ||
}, | }, | ||
["err_capture_of_abstract_type"]={ | ["err_capture_of_abstract_type"]={ | ||
[ | [e]="by-copy capture of value of abstract type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="by-copy capture of value of abstract type %0", | ||
[ | [b]=n, | ||
[ | [j]="by\\-copy capture of value of abstract type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"71fe0e8a832b",1381465521,"Diagnose by-copy captures of abstract classes.","Diagnose by-copy captures of abstract classes."}, | ||
[k]={{ | [k]={{A,19480,"/// 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 // Compute the type of the field that will capture this variable.\n if (ByRef) {\n } else {\n // Make sure that by-copy captures are of a complete and non-abstract type.\n if (!Invalid && BuildAndDiagnose) {\n else if (S.RequireNonAbstractType(Loc, CaptureType, diag::err_capture_of_abstract_type))"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp:100:6: error: by-copy capture of value of abstract type \'X\'"} | ["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp:100:6: error: by-copy capture of value of abstract type \'X\'"} | ||
Line 7,535: | Line 7,555: | ||
}, | }, | ||
["err_capture_of_incomplete_or_sizeless_type"]={ | ["err_capture_of_incomplete_or_sizeless_type"]={ | ||
[ | [e]="by-copy capture of variable A with ... type B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="by-copy capture of variable %0 with %select{incomplete|sizeless}1 type %2", | ||
[ | [b]=n, | ||
[ | [j]="by\\-copy capture of variable (.*?) with (?:incomplete|sizeless) type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={ib,1576908663,K,K}, | ||
[k]={{ | [k]={{A,19411,"/// 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 // Compute the type of the field that will capture this variable.\n if (ByRef) {\n } else {\n // Make sure that by-copy captures are of a complete and non-abstract type.\n if (!Invalid && BuildAndDiagnose) {\n if (!CaptureType->isDependentType() && S.RequireCompleteSizedType(Loc, CaptureType, diag::err_capture_of_incomplete_or_sizeless_type, Var->getDeclName()))"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp:108:19: error: by-copy capture of variable \'param\' with incomplete type \'const X\'"} | ["clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp"]={"clang/test/CXX/expr/expr.prim/expr.prim.lambda/p14.cpp:108:19: error: by-copy capture of variable \'param\' with incomplete type \'const X\'"} | ||
Line 7,550: | Line 7,570: | ||
}, | }, | ||
["err_carries_dependency_missing_on_first_decl"]={ | ["err_carries_dependency_missing_on_first_decl"]={ | ||
[ | [e]="... declared \'[[carries_dependency]]\' after its first declaration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{function|parameter}0 declared \'[[carries_dependency]]\' after its first declaration", | ||
[ | [b]=n, | ||
[ | [j]="(?:function|parameter) declared \'\\[\\[carries_dependency\\]\\]\' after its first declaration", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e233fbfc16fe",1359412965,"Finish semantic analysis for [[carries_dependency]] attribute.","Finish semantic analysis for [[carries_dependency]] attribute."}, | ||
[k]={{ | [k]={{s,3341,"/// mergeParamDeclAttributes - Copy attributes from the old parameter\n/// to the new one.\nstatic void mergeParamDeclAttributes(ParmVarDecl *newDecl, const ParmVarDecl *oldDecl, Sema &S) {\n if (CDA && !oldDecl->hasAttr<CarriesDependencyAttr>()) {\n S.Diag(CDA->getLocation(), diag::err_carries_dependency_missing_on_first_decl) << 1 /*Param*/;"},{s,4055,"/// 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 if (getLangOpts().CPlusPlus) {\n if (CDA && !Old->hasAttr<CarriesDependencyAttr>()) {\n Diag(CDA->getLocation(), diag::err_carries_dependency_missing_on_first_decl) << 0 /*Function*/;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.depend/p2.cpp"]={"clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.depend/p2.cpp:4:3: error: function declared \'[[carries_dependency]]\' after its first declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.depend/p2.cpp:5:15: error: parameter declared \'[[carries_dependency]]\' after its first declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.depend/p2.cpp:9:3: error: function declared \'[[carries_dependency]]\' after its first declaration"} | ["clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.depend/p2.cpp"]={"clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.depend/p2.cpp:4:3: error: function declared \'[[carries_dependency]]\' after its first declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.depend/p2.cpp:5:15: error: parameter declared \'[[carries_dependency]]\' after its first declaration","clang/test/CXX/dcl.dcl/dcl.attr/dcl.attr.depend/p2.cpp:9:3: error: function declared \'[[carries_dependency]]\' after its first declaration"} | ||
Line 7,565: | Line 7,585: | ||
}, | }, | ||
["err_carries_dependency_param_not_function_decl"]={ | ["err_carries_dependency_param_not_function_decl"]={ | ||
[e]="\'[[carries_dependency]]\' attribute only allowed on parameter in a function declaration or lambda", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'[[carries_dependency]]\' attribute only allowed on parameter in a function declaration or lambda", | [h]="\'[[carries_dependency]]\' attribute only allowed on parameter in a function declaration or lambda", | ||
[ | [b]=n, | ||
[ | [j]="\'\\[\\[carries_dependency\\]\\]\' attribute only allowed on parameter in a function declaration or lambda", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"e233fbfc16fe",1359412965,"Finish semantic analysis for [[carries_dependency]] attribute.","Finish semantic analysis for [[carries_dependency]] attribute."}, | |||
[ | |||
[ | |||
[ | |||
[k]={{q,2322,"static void handleDependencyAttr(Sema &S, Scope *Scope, Decl *D, const ParsedAttr &AL) {\n if (isa<ParmVarDecl>(D)) {\n // [[carries_dependency]] can only be applied to a parameter if it is a\n // parameter of a function declaration or lambda.\n if (!(Scope->getFlags() & clang::Scope::FunctionDeclarationScope)) {\n S.Diag(AL.getLoc(), diag::err_carries_dependency_param_not_function_decl);"}}, | [k]={{q,2322,"static void handleDependencyAttr(Sema &S, Scope *Scope, Decl *D, const ParsedAttr &AL) {\n if (isa<ParmVarDecl>(D)) {\n // [[carries_dependency]] can only be applied to a parameter if it is a\n // parameter of a function declaration or lambda.\n if (!(Scope->getFlags() & clang::Scope::FunctionDeclarationScope)) {\n S.Diag(AL.getLoc(), diag::err_carries_dependency_param_not_function_decl);"}}, | ||
[o]={ | [o]={ | ||
Line 7,580: | Line 7,600: | ||
}, | }, | ||
["err_case_not_in_switch"]={ | ["err_case_not_in_switch"]={ | ||
[e]="\'case\' statement not in switch statement", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'case\' statement not in switch statement", | [h]="\'case\' statement not in switch statement", | ||
[ | [b]=n, | ||
[ | [j]="\'case\' statement not in switch statement", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{bb,521,"StmtResult Sema::ActOnCaseStmt(SourceLocation CaseLoc, ExprResult LHSVal, SourceLocation DotDotDotLoc, ExprResult RHSVal, SourceLocation ColonLoc) {\n if (getCurFunction()->SwitchStack.empty()) {\n Diag(CaseLoc, diag::err_case_not_in_switch);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/block-misc.c"]={"clang/test/Sema/block-misc.c:101:6: error: \'case\' statement not in switch statement"} | ["clang/test/Sema/block-misc.c"]={"clang/test/Sema/block-misc.c:101:6: error: \'case\' statement not in switch statement"} | ||
Line 7,595: | Line 7,615: | ||
}, | }, | ||
["err_cast_from_randomized_struct"]={ | ["err_cast_from_randomized_struct"]={ | ||
[ | [e]="casting from randomized structure pointer type A to B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="casting from randomized structure pointer type %0 to %1", | ||
[ | [b]=n, | ||
[ | [j]="casting from randomized structure pointer type (.*?) to (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"cb08f4aa4467",1620530452,Yb,Yb}, | ||
[k]={{x,3235,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n if (isa<PointerType>(SrcType) && isa<PointerType>(DestType)) {\n if (SrcRD && DestRD && SrcRD->hasAttr<RandomizeLayoutAttr>() && SrcRD != DestRD) {\n Self.Diag(OpRange.getBegin(), diag::err_cast_from_randomized_struct) << SrcType << DestType;"}} | [k]={{x,3235,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n if (isa<PointerType>(SrcType) && isa<PointerType>(DestType)) {\n if (SrcRD && DestRD && SrcRD->hasAttr<RandomizeLayoutAttr>() && SrcRD != DestRD) {\n Self.Diag(OpRange.getBegin(), diag::err_cast_from_randomized_struct) << SrcType << DestType;"}} | ||
}, | }, | ||
["err_cast_pointer_from_non_pointer_int"]={ | ["err_cast_pointer_from_non_pointer_int"]={ | ||
[ | [e]="operand of type A cannot be cast to a pointer type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="operand of type %0 cannot be cast to a pointer type", | ||
[ | [b]=n, | ||
[ | [j]="operand of type (.*?) cannot be cast to a pointer type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"f4e3ad6500ca",1241144638,"PR4013 and PR4105: pointer-like types can only be cast to/from integers ","PR4013 and PR4105: pointer-like types can only be cast to/from integers "}, | ||
[k]={{x,3144,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n // If either type is a pointer, the other type has to be either an\n // integer or a pointer.\n if (!DestType->isArithmeticType()) {\n if (!SrcType->isIntegralType(Self.Context) && SrcType->isArithmeticType()) {\n Self.Diag(SrcExpr.get()->getExprLoc(), diag::err_cast_pointer_from_non_pointer_int) << SrcType << SrcExpr.get()->getSourceRange();"}}, | [k]={{x,3144,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n // If either type is a pointer, the other type has to be either an\n // integer or a pointer.\n if (!DestType->isArithmeticType()) {\n if (!SrcType->isIntegralType(Self.Context) && SrcType->isArithmeticType()) {\n Self.Diag(SrcExpr.get()->getExprLoc(), diag::err_cast_pointer_from_non_pointer_int) << SrcType << SrcExpr.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 7,622: | Line 7,642: | ||
}, | }, | ||
["err_cast_pointer_to_non_pointer_int"]={ | ["err_cast_pointer_to_non_pointer_int"]={ | ||
[ | [e]="pointer cannot be cast to type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="pointer cannot be cast to type %0", | ||
[ | [b]=n, | ||
[ | [j]="pointer cannot be cast to type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"f4e3ad6500ca",1241144638,"PR4013 and PR4105: pointer-like types can only be cast to/from integers ","PR4013 and PR4105: pointer-like types can only be cast to/from integers "}, | ||
[k]={{x,3155,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n // If either type is a pointer, the other type has to be either an\n // integer or a pointer.\n if (!DestType->isArithmeticType()) {\n } else if (!SrcType->isArithmeticType()) {\n if (!DestType->isIntegralType(Self.Context) && DestType->isArithmeticType()) {\n Self.Diag(SrcExpr.get()->getBeginLoc(), diag::err_cast_pointer_to_non_pointer_int) << DestType << SrcExpr.get()->getSourceRange();"}}, | [k]={{x,3155,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n // If either type is a pointer, the other type has to be either an\n // integer or a pointer.\n if (!DestType->isArithmeticType()) {\n } else if (!SrcType->isArithmeticType()) {\n if (!DestType->isIntegralType(Self.Context) && DestType->isArithmeticType()) {\n Self.Diag(SrcExpr.get()->getBeginLoc(), diag::err_cast_pointer_to_non_pointer_int) << DestType << SrcExpr.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 7,637: | Line 7,657: | ||
}, | }, | ||
["err_cast_selector_expr"]={ | ["err_cast_selector_expr"]={ | ||
[e]="cannot type cast @selector expression", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot type cast @selector expression", | [h]="cannot type cast @selector expression", | ||
[ | [b]=n, | ||
[ | [j]="cannot type cast @selector expression", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"88fead8c4821",1243028572,"Cannot type cast @selector expressions.","Cannot type cast @selector expressions."}, | |||
[ | |||
[ | |||
[k]={{x,3134,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n if (isa<ObjCSelectorExpr>(SrcExpr.get())) {\n Self.Diag(SrcExpr.get()->getExprLoc(), diag::err_cast_selector_expr);"}}, | [k]={{x,3134,"/// Check the semantics of a C-style cast operation, in C.\nvoid CastOperation::CheckCStyleCast() {\n if (isa<ObjCSelectorExpr>(SrcExpr.get())) {\n Self.Diag(SrcExpr.get()->getExprLoc(), diag::err_cast_selector_expr);"}}, | ||
[o]={ | [o]={ | ||
Line 7,652: | Line 7,672: | ||
}, | }, | ||
["err_catch_incomplete"]={ | ["err_catch_incomplete"]={ | ||
[ | [e]="cannot catch incomplete type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot catch incomplete type %0", | ||
[ | [b]=n, | ||
[ | [j]="cannot catch incomplete type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{w,16634,"/// 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 unsigned DK = diag::err_catch_incomplete;"}}, | [k]={{w,16634,"/// 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 unsigned DK = diag::err_catch_incomplete;"}}, | ||
[o]={ | [o]={ | ||
Line 7,667: | Line 7,687: | ||
}, | }, | ||
["err_catch_incomplete_ptr"]={ | ["err_catch_incomplete_ptr"]={ | ||
[ | [e]="cannot catch pointer to incomplete type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot catch pointer to incomplete type %0", | ||
[ | [b]=n, | ||
[ | [j]="cannot catch pointer to incomplete type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{w,16638,"/// 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 if (const PointerType *Ptr = BaseType->getAs<PointerType>()) {\n DK = diag::err_catch_incomplete_ptr;"}}, | [k]={{w,16638,"/// 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 if (const PointerType *Ptr = BaseType->getAs<PointerType>()) {\n DK = diag::err_catch_incomplete_ptr;"}}, | ||
[o]={ | [o]={ | ||
Line 7,682: | Line 7,702: | ||
}, | }, | ||
["err_catch_incomplete_ref"]={ | ["err_catch_incomplete_ref"]={ | ||
[ | [e]="cannot catch reference to incomplete type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot catch reference to incomplete type %0", | ||
[ | [b]=n, | ||
[ | [j]="cannot catch reference to incomplete type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{w,16643,"/// 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 if (const PointerType *Ptr = BaseType->getAs<PointerType>()) {\n } else if (const ReferenceType *Ref = BaseType->getAs<ReferenceType>()) {\n DK = diag::err_catch_incomplete_ref;"}}, | [k]={{w,16643,"/// 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 if (const PointerType *Ptr = BaseType->getAs<PointerType>()) {\n } else if (const ReferenceType *Ref = BaseType->getAs<ReferenceType>()) {\n DK = diag::err_catch_incomplete_ref;"}}, | ||
[o]={ | [o]={ | ||
Line 7,697: | Line 7,717: | ||
}, | }, | ||
["err_catch_param_not_objc_type"]={ | ["err_catch_param_not_objc_type"]={ | ||
[e]="@catch parameter is not a pointer to an interface type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="@catch parameter is not a pointer to an interface type", | [h]="@catch parameter is not a pointer to an interface type", | ||
[ | [b]=n, | ||
[ | [j]="@catch parameter is not a pointer to an interface type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{O,5168,"/// 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 // An @catch parameter must be an unqualified object pointer type;\n // FIXME: Recover from \"NSObject foo\" by inserting the * in \"NSObject *foo\"?\n if (Invalid) {\n } else if (T->isDependentType()) {\n } else if (T->isObjCQualifiedIdType()) {\n } else if (T->isObjCIdType()) {\n } else if (!T->isObjCObjectPointerType()) {\n Diag(IdLoc, diag::err_catch_param_not_objc_type);"},{O,5171,"/// 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 // An @catch parameter must be an unqualified object pointer type;\n // FIXME: Recover from \"NSObject foo\" by inserting the * in \"NSObject *foo\"?\n if (Invalid) {\n } else if (T->isDependentType()) {\n } else if (T->isObjCQualifiedIdType()) {\n } else if (T->isObjCIdType()) {\n } else if (!T->isObjCObjectPointerType()) {\n } else if (!T->castAs<ObjCObjectPointerType>()->getInterfaceType()) {\n Diag(IdLoc, diag::err_catch_param_not_objc_type);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/catch-invalid.m"]={"clang/test/SemaObjC/catch-invalid.m:7:19: error: @catch parameter is not a pointer to an interface type"} | ["clang/test/SemaObjC/catch-invalid.m"]={"clang/test/SemaObjC/catch-invalid.m:7:19: error: @catch parameter is not a pointer to an interface type"} | ||
Line 7,712: | Line 7,732: | ||
}, | }, | ||
["err_catch_rvalue_ref"]={ | ["err_catch_rvalue_ref"]={ | ||
[e]="cannot catch exceptions by rvalue reference", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot catch exceptions by rvalue reference", | [h]="cannot catch exceptions by rvalue reference", | ||
[ | [b]=n, | ||
[ | [j]="cannot catch exceptions by rvalue reference", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"b28b40712121",1237765767,"Disallow catching exceptions by rvalue reference.","Disallow catching exceptions by rvalue reference."}, | |||
[ | |||
[ | |||
[k]={{w,16623,"/// 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 // C++ 15.3p1: The exception-declaration shall not denote an incomplete type.\n // The exception-declaration shall not denote a pointer or reference to an\n // incomplete type, other than [cv] void*.\n // N2844 forbids rvalue references.\n if (!ExDeclType->isDependentType() && ExDeclType->isRValueReferenceType()) {\n Diag(Loc, diag::err_catch_rvalue_ref);"}}, | [k]={{w,16623,"/// 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 // C++ 15.3p1: The exception-declaration shall not denote an incomplete type.\n // The exception-declaration shall not denote a pointer or reference to an\n // incomplete type, other than [cv] void*.\n // N2844 forbids rvalue references.\n if (!ExDeclType->isDependentType() && ExDeclType->isRValueReferenceType()) {\n Diag(Loc, diag::err_catch_rvalue_ref);"}}, | ||
[o]={ | [o]={ | ||
Line 7,727: | Line 7,747: | ||
}, | }, | ||
["err_catch_sizeless"]={ | ["err_catch_sizeless"]={ | ||
[ | [e]="cannot catch ...sizeless type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot catch %select{|reference to }0sizeless type %1", | ||
[ | [b]=n, | ||
[ | [j]="cannot catch (?:|reference to )sizeless type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={ib,1576908663,K,K}, | ||
[k]={{w,16655,"/// 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 if (!Invalid && Mode != 1 && BaseType->isSizelessType()) {\n Diag(Loc, diag::err_catch_sizeless) << (Mode == 2 ? 1 : 0) << BaseType;"}}, | [k]={{w,16655,"/// 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 if (!Invalid && Mode != 1 && BaseType->isSizelessType()) {\n Diag(Loc, diag::err_catch_sizeless) << (Mode == 2 ? 1 : 0) << BaseType;"}}, | ||
[o]={ | [o]={ | ||
Line 7,742: | Line 7,762: | ||
}, | }, | ||
["err_catch_variably_modified"]={ | ["err_catch_variably_modified"]={ | ||
[ | [e]="cannot catch variably modified type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot catch variably modified type %0", | ||
[ | [b]=n, | ||
[ | [j]="cannot catch variably modified type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e56d1a0d5000",1465401907,"[Sema] Don\'t permit catching variably modified types","[Sema] Don\'t permit catching variably modified types"}, | ||
[k]={{w,16628,"/// 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 if (ExDeclType->isVariablyModifiedType()) {\n Diag(Loc, diag::err_catch_variably_modified) << ExDeclType;"}}, | [k]={{w,16628,"/// 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 if (ExDeclType->isVariablyModifiedType()) {\n Diag(Loc, diag::err_catch_variably_modified) << ExDeclType;"}}, | ||
[o]={ | [o]={ | ||
Line 7,757: | Line 7,777: | ||
}, | }, | ||
["err_category_forward_interface"]={ | ["err_category_forward_interface"]={ | ||
[ | [e]="cannot define ... for undefined class A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot define %select{category|class extension}0 for undefined class %1", | ||
[ | [b]=n, | ||
[ | [j]="cannot define (?:category|class extension) for undefined class (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"4123a86faebb",1321308601,"Use Sema::RequireCompleteType to check for the completeness of","Use Sema::RequireCompleteType to check for the completeness of"}, | ||
[k]={{ | [k]={{O,1833,"ObjCCategoryDecl *Sema::ActOnStartCategoryInterface(SourceLocation AtInterfaceLoc, IdentifierInfo *ClassName, SourceLocation ClassLoc, ObjCTypeParamList *typeParamList, IdentifierInfo *CategoryName, SourceLocation CategoryLoc, Decl *const *ProtoRefs, unsigned NumProtoRefs, const SourceLocation *ProtoLocs, SourceLocation EndProtoLoc, const ParsedAttributesView &AttrList) {\n if (!IDecl || RequireCompleteType(ClassLoc, Context.getObjCInterfaceType(IDecl), diag::err_category_forward_interface, CategoryName == nullptr)) {"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/category-1.m"]={"clang/test/SemaObjC/category-1.m:37:12: error: cannot define category for undefined class \'MyClass2\'"} | ["clang/test/SemaObjC/category-1.m"]={"clang/test/SemaObjC/category-1.m:37:12: error: cannot define category for undefined class \'MyClass2\'"} | ||
Line 7,772: | Line 7,792: | ||
}, | }, | ||
["err_category_property"]={ | ["err_category_property"]={ | ||
[ | [e]="property declared in category A cannot be implemented in class implementation", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="property declared in category %0 cannot be implemented in class implementation", | ||
[ | [b]=n, | ||
[ | [j]="property declared in category (.*?) cannot be implemented in class implementation", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={Xb,1480718311,gb,gb}, | ||
[k]={{ | [k]={{Y,1134,"/// 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 if ((IC = dyn_cast<ObjCImplementationDecl>(ClassImpDecl))) {\n if (const ObjCCategoryDecl *CD = dyn_cast<ObjCCategoryDecl>(property->getDeclContext())) {\n if (!CD->IsClassExtension()) {\n Diag(PropertyLoc, diag::err_category_property) << CD->getDeclName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/property-category-4.m"]={"clang/test/SemaObjC/property-category-4.m:15:13: error: property declared in category \'CAT\' cannot be implemented in class implementation","clang/test/SemaObjC/property-category-4.m:16:10: error: property declared in category \'CAT\' cannot be implemented in class implementation"} | ["clang/test/SemaObjC/property-category-4.m"]={"clang/test/SemaObjC/property-category-4.m:15:13: error: property declared in category \'CAT\' cannot be implemented in class implementation","clang/test/SemaObjC/property-category-4.m:16:10: error: property declared in category \'CAT\' cannot be implemented in class implementation"} | ||
Line 7,787: | Line 7,807: | ||
}, | }, | ||
["err_cc1_round_trip_fail_then_ok"]={ | ["err_cc1_round_trip_fail_then_ok"]={ | ||
[e]="original arguments parse failed, then succeeded in round-trip", | |||
[d]=l, | |||
[f]=m, | |||
[h]="original arguments parse failed, then succeeded in round-trip", | [h]="original arguments parse failed, then succeeded in round-trip", | ||
[ | [b]=n, | ||
[ | [j]="original arguments parse failed, then succeeded in round\\-trip", | ||
[c]=a, | |||
[i]=a, | |||
[g]={"0175999805cf",1585492323,Jb,Jb}, | |||
[ | [k]={{V,727,"#endif\n // Run the first parse on the original arguments with the dummy invocation and\n // diagnostics.\n if (!Parse(DummyInvocation, CommandLineArgs, DummyDiags, Argv0) || DummyDiags.getNumWarnings() != 0) {\n Diags.Report(diag::err_cc1_round_trip_fail_then_ok);"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_cc1_round_trip_mismatch"]={ | ["err_cc1_round_trip_mismatch"]={ | ||
[e]="generated arguments do not match in round-trip", | |||
[d]=l, | |||
[f]=m, | |||
[h]="generated arguments do not match in round-trip", | [h]="generated arguments do not match in round-trip", | ||
[ | [b]=n, | ||
[ | [j]="generated arguments do not match in round\\-trip", | ||
[c]=a, | |||
[i]=a, | |||
[g]={"0175999805cf",1585492323,Jb,Jb}, | |||
[ | [k]={{V,783,"#endif\n // If we generated different arguments from what we assume are two\n // semantically equivalent CompilerInvocations, the Generate function may\n // be non-deterministic.\n if (!Equal(GeneratedArgs, ComparisonArgs)) {\n Diags.Report(diag::err_cc1_round_trip_mismatch);"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_cc1_round_trip_ok_then_fail"]={ | ["err_cc1_round_trip_ok_then_fail"]={ | ||
[e]="generated arguments parse failed in round-trip", | |||
[d]=l, | |||
[f]=m, | |||
[h]="generated arguments parse failed in round-trip", | [h]="generated arguments parse failed in round-trip", | ||
[ | [b]=n, | ||
[ | [j]="generated arguments parse failed in round\\-trip", | ||
[c]=a, | |||
[i]=a, | |||
[g]={"0175999805cf",1585492323,Jb,Jb}, | |||
[ | [k]={{V,755,"#endif\n // The first parse on original arguments succeeded, but second parse of\n // generated arguments failed. Something must be wrong with the generator.\n if (!Success2) {\n Diags.Report(diag::err_cc1_round_trip_ok_then_fail);"}} | ||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_cc1_unbounded_vscale_min"]={ | ["err_cc1_unbounded_vscale_min"]={ | ||
[e]="minimum vscale must be an unsigned integer greater than 0", | |||
[d]=l, | |||
[f]=m, | |||
[h]="minimum vscale must be an unsigned integer greater than 0", | [h]="minimum vscale must be an unsigned integer greater than 0", | ||
[ | [b]=n, | ||
[ | [j]="minimum vscale must be an unsigned integer greater than 0", | ||
[c]=a, | |||
[ | [i]=a, | ||
[g]={"0687578728ea",1610286626,bc,bc}, | |||
[k]={{V,4053,"#include \"clang/Driver/Options.inc\"\n // Error if -mvscale-min is unbounded.\n if (Arg *A = Args.getLastArg(options::OPT_mvscale_min_EQ)) {\n if (StringRef(A->getValue()).getAsInteger(10, VScaleMin) || VScaleMin == 0)\n Diags.Report(diag::err_cc1_unbounded_vscale_min);"}} | |||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_cconv_change"]={ | ["err_cconv_change"]={ | ||
[ | [e]="function declared \'A\' here was previously declared ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="function declared \'%0\' here was previously declared %select{\'%2\'|without calling convention}1", | ||
[ | [b]=n, | ||
[ | [j]="function declared \'(.*?)\' here was previously declared (?:\'(.*?)\'|without calling convention)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"ab26cfa58de5",1265405516,"Standardize the parsing of function type attributes in a way that","Standardize the parsing of function type attributes in a way that"}, | ||
[k]={{ | [k]={{s,3809,"/// 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 if (OldTypeInfo.getCC() != NewTypeInfo.getCC()) {\n if (!NewCCExplicit) {\n } else if (Old->getBuiltinID()) {\n } else {\n Diag(New->getLocation(), diag::err_cconv_change) << FunctionType::getNameForCallConv(NewTypeInfo.getCC()) << !FirstCCExplicit << (!FirstCCExplicit ? \"\" : FunctionType::getNameForCallConv(FI.getCC()));"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/ms_abi-sysv_abi.c"]={"clang/test/Sema/ms_abi-sysv_abi.c:11:32: error: function declared \'cdecl\' here was previously declared \'ms_abi\'"} | ["clang/test/Sema/ms_abi-sysv_abi.c"]={"clang/test/Sema/ms_abi-sysv_abi.c:11:32: error: function declared \'cdecl\' here was previously declared \'ms_abi\'"} | ||
Line 7,850: | Line 7,870: | ||
}, | }, | ||
["err_cconv_incomplete_param_type"]={ | ["err_cconv_incomplete_param_type"]={ | ||
[ | [e]="parameter A must have a complete type to use function B with the C calling convention", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="parameter %0 must have a complete type to use function %1 with the %2 calling convention", | ||
[ | [b]=n, | ||
[ | [j]="parameter (.*?) must have a complete type to use function (.*?) with the (.*?) calling convention", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e78333a0105d",1560207192,"Require stdcall etc parameters to be complete on ODR use","Require stdcall etc parameters to be complete on ODR use"}, | ||
[k]={{ | [k]={{A,19011,"/// Require that all of the parameter types of function be complete. Normally,\n/// parameter types are only required to be complete when a function is called\n/// or defined, but to mangle functions with certain calling conventions, the\n/// mangler needs to know the size of the parameter list. In this situation,\n/// MSVC doesn\'t emit an error or instantiate templates. Instead, MSVC mangles\n/// the function as _foo@0, i.e. zero bytes of parameters, which will usually\n/// result in a linker error. Clang doesn\'t implement this behavior, and instead\n/// attempts to error at compile time.\nstatic void CheckCompleteParameterTypesForMangler(Sema &S, FunctionDecl *FD, SourceLocation Loc) {\n class ParamIncompleteTypeDiagnoser : public Sema::TypeDiagnoser {\n void diagnose(Sema &S, SourceLocation Loc, QualType T) override {\n S.Diag(Loc, diag::err_cconv_incomplete_param_type) << Param->getDeclName() << FD->getDeclName() << CCName;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/calling-conv-complete-params.c"]={"clang/test/Sema/calling-conv-complete-params.c:23:45: error: parameter \'p\' must have a complete type to use function \'fwd_std\' with the stdcall calling convention","clang/test/Sema/calling-conv-complete-params.c:29:47: error: parameter \'p\' must have a complete type to use function \'fwd_fast\' with the fastcall calling convention","clang/test/Sema/calling-conv-complete-params.c:35:51: error: parameter \'p\' must have a complete type to use function \'fwd_vector\' with the vectorcall calling convention"} | ["clang/test/Sema/calling-conv-complete-params.c"]={"clang/test/Sema/calling-conv-complete-params.c:23:45: error: parameter \'p\' must have a complete type to use function \'fwd_std\' with the stdcall calling convention","clang/test/Sema/calling-conv-complete-params.c:29:47: error: parameter \'p\' must have a complete type to use function \'fwd_fast\' with the fastcall calling convention","clang/test/Sema/calling-conv-complete-params.c:35:51: error: parameter \'p\' must have a complete type to use function \'fwd_vector\' with the vectorcall calling convention"} | ||
Line 7,865: | Line 7,885: | ||
}, | }, | ||
["err_cconv_knr"]={ | ["err_cconv_knr"]={ | ||
[ | [e]="function with no prototype cannot use the A calling convention", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="function with no prototype cannot use the %0 calling convention", | ||
[ | [b]=n, | ||
[ | [j]="function with no prototype cannot use the (.*?) calling convention", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"4976fd4ea971",1257305769,"Diagnose the use of \'fastcall\' on functions without prototypes or with","Diagnose the use of \'fastcall\' on functions without prototypes or with"}, | ||
[k]={{ | [k]={{s,10321,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\n if (!getLangOpts().CPlusPlus) {\n if (isa<FunctionNoProtoType>(FT) && !D.isFunctionDefinition()) {\n if (!supportsVariadicCall(CC)) {\n int DiagID = CC == CC_X86StdCall ? diag::warn_cconv_knr : diag::err_cconv_knr;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/decl-microsoft-call-conv.c"]={"clang/test/Sema/decl-microsoft-call-conv.c:22:17: error: function with no prototype cannot use the fastcall calling convention","clang/test/Sema/decl-microsoft-call-conv.c:24:17: error: function with no prototype cannot use the thiscall calling convention","clang/test/Sema/decl-microsoft-call-conv.c:25:15: error: function with no prototype cannot use the pascal calling convention","clang/test/Sema/decl-microsoft-call-conv.c:26:19: error: function with no prototype cannot use the vectorcall calling convention"} | ["clang/test/Sema/decl-microsoft-call-conv.c"]={"clang/test/Sema/decl-microsoft-call-conv.c:22:17: error: function with no prototype cannot use the fastcall calling convention","clang/test/Sema/decl-microsoft-call-conv.c:24:17: error: function with no prototype cannot use the thiscall calling convention","clang/test/Sema/decl-microsoft-call-conv.c:25:15: error: function with no prototype cannot use the pascal calling convention","clang/test/Sema/decl-microsoft-call-conv.c:26:19: error: function with no prototype cannot use the vectorcall calling convention"} | ||
Line 7,880: | Line 7,900: | ||
}, | }, | ||
["err_cconv_varargs"]={ | ["err_cconv_varargs"]={ | ||
[ | [e]="variadic function cannot use A calling convention", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="variadic function cannot use %0 calling convention", | ||
[ | [b]=n, | ||
[ | [j]="variadic function cannot use (.*?) calling convention", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"4976fd4ea971",1257305769,"Diagnose the use of \'fastcall\' on functions without prototypes or with","Diagnose the use of \'fastcall\' on functions without prototypes or with"}, | ||
[k]={{ | [k]={{t,7999,"/// Process an individual function attribute. Returns true to\n/// indicate that the attribute was handled, false if it wasn\'t.\nstatic bool handleFunctionTypeAttr(TypeProcessingState &state, ParsedAttr &attr, QualType &type) {\n // Diagnose use of variadic functions with calling conventions that\n // don\'t support them (e.g. because they\'re callee-cleanup).\n // We delay warning about this on unprototyped function declarations\n // until after redeclaration checking, just in case we pick up a\n // prototype that way. And apparently we also \"delay\" warning about\n // unprototyped function types in general, despite not necessarily having\n // much ability to diagnose it later.\n if (!supportsVariadicCall(CC)) {\n if (FnP && FnP->isVariadic()) {\n return S.Diag(attr.getLoc(), diag::err_cconv_varargs) << FunctionType::getNameForCallConv(CC);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/attr-swiftcall.cpp"]={"clang/test/SemaCXX/attr-swiftcall.cpp:12:27: error: variadic function cannot use swiftcall calling convention","clang/test/SemaCXX/attr-swiftcall.cpp:13:33: error: variadic function cannot use swiftasynccall calling convention"} | ["clang/test/SemaCXX/attr-swiftcall.cpp"]={"clang/test/SemaCXX/attr-swiftcall.cpp:12:27: error: variadic function cannot use swiftcall calling convention","clang/test/SemaCXX/attr-swiftcall.cpp:13:33: error: variadic function cannot use swiftasynccall calling convention"} | ||
Line 7,895: | Line 7,915: | ||
}, | }, | ||
["err_cfstring_literal_not_string_constant"]={ | ["err_cfstring_literal_not_string_constant"]={ | ||
[e]="CFString literal is not a string constant", | |||
[d]=l, | |||
[f]=m, | |||
[h]="CFString literal is not a string constant", | [h]="CFString literal is not a string constant", | ||
[ | [b]=n, | ||
[ | [j]="CFString literal is not a string constant", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{u,7978,"/// CheckObjCString - Checks that the argument to the builtin\n/// CFString constructor is correct\n/// Note: It might also make sense to do the UTF-16 conversion here (would\n/// simplify the backend).\nbool Sema::CheckObjCString(Expr *Arg) {\n if (!Literal || !Literal->isOrdinary()) {\n Diag(Arg->getBeginLoc(), diag::err_cfstring_literal_not_string_constant) << Arg->getSourceRange();"},{M,56,"ExprResult Sema::ParseObjCStringLiteral(SourceLocation *AtLocs, ArrayRef<Expr *> Strings) {\n // If we have a multi-part string, merge it all together.\n if (Strings.size() != 1) {\n for (Expr *E : Strings) {\n // ObjC strings can\'t be wide or UTF.\n if (!S->isOrdinary()) {\n Diag(S->getBeginLoc(), diag::err_cfstring_literal_not_string_constant) << S->getSourceRange();"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Hb]={"clang/test/Sema/builtins.c:31:13: error: CFString literal is not a string constant"} | ||
} | } | ||
}, | }, | ||
["err_character_not_allowed"]={ | ["err_character_not_allowed"]={ | ||
[ | [e]="unexpected character <U+A>", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="unexpected character <U+%0>", | ||
[ | [b]=n, | ||
[ | [j]="unexpected character \\<U\\+(.*?)\\>", | ||
[ | [c]=a, | ||
[ | [i]=rb, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{ | [k]={{Tb,1691,"static void diagnoseInvalidUnicodeCodepointInIdentifier(DiagnosticsEngine &Diags, const LangOptions &LangOpts, uint32_t CodePoint, CharSourceRange Range, bool IsFirst) {\n if (!IsFirst || InvalidOnlyAtStart) {\n } else {\n Diags.Report(Range.getBegin(), diag::err_character_not_allowed) << Range << codepointAsHexString(CodePoint) << FixItHint::CreateRemoval(Range);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Preprocessor/utf8-allowed-chars.c"]={"clang/test/Preprocessor/utf8-allowed-chars.c:21:13: error: unexpected character <U+0300>"} | ["clang/test/Preprocessor/utf8-allowed-chars.c"]={"clang/test/Preprocessor/utf8-allowed-chars.c:21:13: error: unexpected character <U+0300>"} | ||
Line 7,925: | Line 7,945: | ||
}, | }, | ||
["err_character_not_allowed_identifier"]={ | ["err_character_not_allowed_identifier"]={ | ||
[ | [e]="character <U+A> not allowed ... an identifier", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="character <U+%0> not allowed %select{in|at the start of}1 an identifier", | ||
[ | [b]=n, | ||
[ | [j]="character \\<U\\+(.*?)\\> not allowed (?:in|at the start of) an identifier", | ||
[ | [c]=a, | ||
[ | [i]=rb, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{ | [k]={{Tb,1687,"static void diagnoseInvalidUnicodeCodepointInIdentifier(DiagnosticsEngine &Diags, const LangOptions &LangOpts, uint32_t CodePoint, CharSourceRange Range, bool IsFirst) {\n if (!IsFirst || InvalidOnlyAtStart) {\n Diags.Report(Range.getBegin(), diag::err_character_not_allowed_identifier) << Range << codepointAsHexString(CodePoint) << int(InvalidOnlyAtStart) << FixItHint::CreateRemoval(Range);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Parser/cxx11-user-defined-literals.cpp"]={"clang/test/Parser/cxx11-user-defined-literals.cpp:147:26: error: character <U+00A2> not allowed in an identifier","clang/test/Parser/cxx11-user-defined-literals.cpp:148:26: error: character <U+00A2> not allowed in an identifier","clang/test/Parser/cxx11-user-defined-literals.cpp:149:20: error: character <U+00A2> not allowed in an identifier","clang/test/Parser/cxx11-user-defined-literals.cpp:149:28: error: character <U+00A2> not allowed in an identifier"} | ["clang/test/Parser/cxx11-user-defined-literals.cpp"]={"clang/test/Parser/cxx11-user-defined-literals.cpp:147:26: error: character <U+00A2> not allowed in an identifier","clang/test/Parser/cxx11-user-defined-literals.cpp:148:26: error: character <U+00A2> not allowed in an identifier","clang/test/Parser/cxx11-user-defined-literals.cpp:149:20: error: character <U+00A2> not allowed in an identifier","clang/test/Parser/cxx11-user-defined-literals.cpp:149:28: error: character <U+00A2> not allowed in an identifier"} | ||
Line 7,940: | Line 7,960: | ||
}, | }, | ||
["err_character_too_large"]={ | ["err_character_too_large"]={ | ||
[e]="character too large for enclosing character literal type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="character too large for enclosing character literal type", | [h]="character too large for enclosing character literal type", | ||
[ | [b]=n, | ||
[ | [j]="character too large for enclosing character literal type", | ||
[c]=a, | |||
[ | [i]=rb, | ||
[g]={"8b2b677f390d",1326889624,"Improves support for Unicode in character literals","Improves support for Unicode in character literals"}, | |||
[ | |||
[ | |||
[k]={{"clang/lib/Lex/LiteralSupport.cpp",1761,"/// \\verbatim\n/// user-defined-character-literal: [C++11 lex.ext]\n/// character-literal ud-suffix\n/// ud-suffix:\n/// identifier\n/// character-literal: [C++11 lex.ccon]\n/// \' c-char-sequence \'\n/// u\' c-char-sequence \'\n/// U\' c-char-sequence \'\n/// L\' c-char-sequence \'\n/// u8\' c-char-sequence \' [C++1z lex.ccon]\n/// c-char-sequence:\n/// c-char\n/// c-char-sequence c-char\n/// c-char:\n/// any member of the source character set except the single-quote \',\n/// backslash \\, or new-line character\n/// escape-sequence\n/// universal-character-name\n/// escape-sequence:\n/// simple-escape-sequence\n/// octal-escape-sequence\n/// hexadecimal-escape-sequence\n/// simple-escape-sequence:\n/// one of \\\' \\\" \\? \\\\ \\a \\b \\f \\n \\r \\t \\v\n/// octal-escape-sequence:\n/// \\ octal-digit\n/// \\ octal-digit octal-digit\n/// \\ octal-digit octal-digit octal-digit\n/// hexadecimal-escape-sequence:\n/// \\x hexadecimal-digit\n/// hexadecimal-escape-sequence hexadecimal-digit\n/// universal-character-name: [C++11 lex.charset]\n/// \\u hex-quad\n/// \\U hex-quad hex-quad\n/// hex-quad:\n/// hex-digit hex-digit hex-digit hex-digit\n/// \\endverbatim\n///\nCharLiteralParser::CharLiteralParser(const char *begin, const char *end, SourceLocation Loc, Preprocessor &PP, tok::TokenKind kind) {\n while (begin != end) {\n // Is this a span of non-escape characters?\n if (begin[0] != \'\\\\\') {\n if (res != llvm::conversionOK) {\n } else {\n for (; tmp_out_start < buffer_begin; ++tmp_out_start) {\n if (*tmp_out_start > largest_character_for_kind) {\n PP.Diag(Loc, diag::err_character_too_large);"},{"clang/lib/Lex/LiteralSupport.cpp",1777,"/// \\verbatim\n/// user-defined-character-literal: [C++11 lex.ext]\n/// character-literal ud-suffix\n/// ud-suffix:\n/// identifier\n/// character-literal: [C++11 lex.ccon]\n/// \' c-char-sequence \'\n/// u\' c-char-sequence \'\n/// U\' c-char-sequence \'\n/// L\' c-char-sequence \'\n/// u8\' c-char-sequence \' [C++1z lex.ccon]\n/// c-char-sequence:\n/// c-char\n/// c-char-sequence c-char\n/// c-char:\n/// any member of the source character set except the single-quote \',\n/// backslash \\, or new-line character\n/// escape-sequence\n/// universal-character-name\n/// escape-sequence:\n/// simple-escape-sequence\n/// octal-escape-sequence\n/// hexadecimal-escape-sequence\n/// simple-escape-sequence:\n/// one of \\\' \\\" \\? \\\\ \\a \\b \\f \\n \\r \\t \\v\n/// octal-escape-sequence:\n/// \\ octal-digit\n/// \\ octal-digit octal-digit\n/// \\ octal-digit octal-digit octal-digit\n/// hexadecimal-escape-sequence:\n/// \\x hexadecimal-digit\n/// hexadecimal-escape-sequence hexadecimal-digit\n/// universal-character-name: [C++11 lex.charset]\n/// \\u hex-quad\n/// \\U hex-quad hex-quad\n/// hex-quad:\n/// hex-digit hex-digit hex-digit hex-digit\n/// \\endverbatim\n///\nCharLiteralParser::CharLiteralParser(const char *begin, const char *end, SourceLocation Loc, Preprocessor &PP, tok::TokenKind kind) {\n while (begin != end) {\n // Is this a Universal Character Name escape?\n if (begin[1] == \'u\' || begin[1] == \'U\' || begin[1] == \'N\') {\n if (!ProcessUCNEscape(TokBegin, begin, end, *buffer_begin, UcnLen, FullSourceLoc(Loc, PP.getSourceManager()), &PP.getDiagnostics(), PP.getLangOpts(), true)) {\n } else if (*buffer_begin > largest_character_for_kind) {\n PP.Diag(Loc, diag::err_character_too_large);"}}, | [k]={{"clang/lib/Lex/LiteralSupport.cpp",1761,"/// \\verbatim\n/// user-defined-character-literal: [C++11 lex.ext]\n/// character-literal ud-suffix\n/// ud-suffix:\n/// identifier\n/// character-literal: [C++11 lex.ccon]\n/// \' c-char-sequence \'\n/// u\' c-char-sequence \'\n/// U\' c-char-sequence \'\n/// L\' c-char-sequence \'\n/// u8\' c-char-sequence \' [C++1z lex.ccon]\n/// c-char-sequence:\n/// c-char\n/// c-char-sequence c-char\n/// c-char:\n/// any member of the source character set except the single-quote \',\n/// backslash \\, or new-line character\n/// escape-sequence\n/// universal-character-name\n/// escape-sequence:\n/// simple-escape-sequence\n/// octal-escape-sequence\n/// hexadecimal-escape-sequence\n/// simple-escape-sequence:\n/// one of \\\' \\\" \\? \\\\ \\a \\b \\f \\n \\r \\t \\v\n/// octal-escape-sequence:\n/// \\ octal-digit\n/// \\ octal-digit octal-digit\n/// \\ octal-digit octal-digit octal-digit\n/// hexadecimal-escape-sequence:\n/// \\x hexadecimal-digit\n/// hexadecimal-escape-sequence hexadecimal-digit\n/// universal-character-name: [C++11 lex.charset]\n/// \\u hex-quad\n/// \\U hex-quad hex-quad\n/// hex-quad:\n/// hex-digit hex-digit hex-digit hex-digit\n/// \\endverbatim\n///\nCharLiteralParser::CharLiteralParser(const char *begin, const char *end, SourceLocation Loc, Preprocessor &PP, tok::TokenKind kind) {\n while (begin != end) {\n // Is this a span of non-escape characters?\n if (begin[0] != \'\\\\\') {\n if (res != llvm::conversionOK) {\n } else {\n for (; tmp_out_start < buffer_begin; ++tmp_out_start) {\n if (*tmp_out_start > largest_character_for_kind) {\n PP.Diag(Loc, diag::err_character_too_large);"},{"clang/lib/Lex/LiteralSupport.cpp",1777,"/// \\verbatim\n/// user-defined-character-literal: [C++11 lex.ext]\n/// character-literal ud-suffix\n/// ud-suffix:\n/// identifier\n/// character-literal: [C++11 lex.ccon]\n/// \' c-char-sequence \'\n/// u\' c-char-sequence \'\n/// U\' c-char-sequence \'\n/// L\' c-char-sequence \'\n/// u8\' c-char-sequence \' [C++1z lex.ccon]\n/// c-char-sequence:\n/// c-char\n/// c-char-sequence c-char\n/// c-char:\n/// any member of the source character set except the single-quote \',\n/// backslash \\, or new-line character\n/// escape-sequence\n/// universal-character-name\n/// escape-sequence:\n/// simple-escape-sequence\n/// octal-escape-sequence\n/// hexadecimal-escape-sequence\n/// simple-escape-sequence:\n/// one of \\\' \\\" \\? \\\\ \\a \\b \\f \\n \\r \\t \\v\n/// octal-escape-sequence:\n/// \\ octal-digit\n/// \\ octal-digit octal-digit\n/// \\ octal-digit octal-digit octal-digit\n/// hexadecimal-escape-sequence:\n/// \\x hexadecimal-digit\n/// hexadecimal-escape-sequence hexadecimal-digit\n/// universal-character-name: [C++11 lex.charset]\n/// \\u hex-quad\n/// \\U hex-quad hex-quad\n/// hex-quad:\n/// hex-digit hex-digit hex-digit hex-digit\n/// \\endverbatim\n///\nCharLiteralParser::CharLiteralParser(const char *begin, const char *end, SourceLocation Loc, Preprocessor &PP, tok::TokenKind kind) {\n while (begin != end) {\n // Is this a Universal Character Name escape?\n if (begin[1] == \'u\' || begin[1] == \'U\' || begin[1] == \'N\') {\n if (!ProcessUCNEscape(TokBegin, begin, end, *buffer_begin, UcnLen, FullSourceLoc(Loc, PP.getSourceManager()), &PP.getDiagnostics(), PP.getLangOpts(), true)) {\n } else if (*buffer_begin > largest_character_for_kind) {\n PP.Diag(Loc, diag::err_character_too_large);"}}, | ||
[o]={ | [o]={ | ||
Line 7,955: | Line 7,975: | ||
}, | }, | ||
["err_circular_inheritance"]={ | ["err_circular_inheritance"]={ | ||
[ | [e]="circular inheritance between A and B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="circular inheritance between %0 and %1", | ||
[ | [b]=n, | ||
[ | [j]="circular inheritance between (.*?) and (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"620047011211",1352510297,"Diagnostic circular inheritance involving dependent base classes. We","Diagnostic circular inheritance involving dependent base classes. We"}, | ||
[k]={{w,2685,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n if (BaseType->isDependentType()) {\n // Make sure that we don\'t have circular inheritance among our dependent\n // bases. For non-dependent bases, the check for completeness below handles\n // this.\n if (CXXRecordDecl *BaseDecl = BaseType->getAsCXXRecordDecl()) {\n if (BaseDecl->getCanonicalDecl() == Class->getCanonicalDecl() || ((BaseDecl = BaseDecl->getDefinition()) && findCircularInheritance(Class, BaseDecl))) {\n Diag(BaseLoc, diag::err_circular_inheritance) << BaseType << Context.getTypeDeclType(Class);"}}, | [k]={{w,2685,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n if (BaseType->isDependentType()) {\n // Make sure that we don\'t have circular inheritance among our dependent\n // bases. For non-dependent bases, the check for completeness below handles\n // this.\n if (CXXRecordDecl *BaseDecl = BaseType->getAsCXXRecordDecl()) {\n if (BaseDecl->getCanonicalDecl() == Class->getCanonicalDecl() || ((BaseDecl = BaseDecl->getDefinition()) && findCircularInheritance(Class, BaseDecl))) {\n Diag(BaseLoc, diag::err_circular_inheritance) << BaseType << Context.getTypeDeclType(Class);"}}, | ||
[o]={ | [o]={ | ||
Line 7,970: | Line 7,990: | ||
}, | }, | ||
["err_class_extension_after_impl"]={ | ["err_class_extension_after_impl"]={ | ||
[ | [e]="cannot declare class extension for A after class implementation", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot declare class extension for %0 after class implementation", | ||
[ | [b]=n, | ||
[ | [j]="cannot declare class extension for (.*?) after class implementation", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e16cdb407a3f",1270241585,"diagnose declaring class extension after its implementation","diagnose declaring class extension after its implementation"}, | ||
[k]={{ | [k]={{O,1851,"ObjCCategoryDecl *Sema::ActOnStartCategoryInterface(SourceLocation AtInterfaceLoc, IdentifierInfo *ClassName, SourceLocation ClassLoc, ObjCTypeParamList *typeParamList, IdentifierInfo *CategoryName, SourceLocation CategoryLoc, Decl *const *ProtoRefs, unsigned NumProtoRefs, const SourceLocation *ProtoLocs, SourceLocation EndProtoLoc, const ParsedAttributesView &AttrList) {\n if (!CategoryName && IDecl->getImplementation()) {\n Diag(ClassLoc, diag::err_class_extension_after_impl) << ClassName;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/class-extension-after-implementation.m"]={"clang/test/SemaObjC/class-extension-after-implementation.m:8:12: error: cannot declare class extension for \'A\' after class implementation"} | ["clang/test/SemaObjC/class-extension-after-implementation.m"]={"clang/test/SemaObjC/class-extension-after-implementation.m:8:12: error: cannot declare class extension for \'A\' after class implementation"} | ||
Line 7,985: | Line 8,005: | ||
}, | }, | ||
["err_class_marked_final_used_as_base"]={ | ["err_class_marked_final_used_as_base"]={ | ||
[ | [e]="base A is marked \'...\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="base %0 is marked \'%select{final|sealed}1\'", | ||
[ | [b]=n, | ||
[ | [j]="base (.*?) is marked \'(?:final|sealed)\'", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"fc1eef48980e",1295718713,"Mark classes as final or explicit. Diagnose when a class marked \'final\' is used as a base.","Mark classes as final or explicit. Diagnose when a class marked \'final\' is used as a base."}, | ||
[k]={{w,2780,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n // C++ [class]p3:\n // If a class is marked final and it appears as a base-type-specifier in\n // base-clause, the program is ill-formed.\n if (FinalAttr *FA = CXXBaseDecl->getAttr<FinalAttr>()) {\n Diag(BaseLoc, diag::err_class_marked_final_used_as_base) << CXXBaseDecl->getDeclName() << FA->isSpelledAsSealed();"}}, | [k]={{w,2780,"/// Check the validity of a C++ base class specifier.\n///\n/// \\returns a new CXXBaseSpecifier if well-formed, emits diagnostics\n/// and returns NULL otherwise.\nCXXBaseSpecifier *Sema::CheckBaseSpecifier(CXXRecordDecl *Class, SourceRange SpecifierRange, bool Virtual, AccessSpecifier Access, TypeSourceInfo *TInfo, SourceLocation EllipsisLoc) {\n // C++ [class]p3:\n // If a class is marked final and it appears as a base-type-specifier in\n // base-clause, the program is ill-formed.\n if (FinalAttr *FA = CXXBaseDecl->getAttr<FinalAttr>()) {\n Diag(BaseLoc, diag::err_class_marked_final_used_as_base) << CXXBaseDecl->getDeclName() << FA->isSpelledAsSealed();"}}, | ||
[o]={ | [o]={ | ||
Line 8,000: | Line 8,020: | ||
}, | }, | ||
["err_class_on_template_template_param"]={ | ["err_class_on_template_template_param"]={ | ||
[ | [e]="template template parameter requires \'class\'... after the parameter list", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="template template parameter requires \'class\'%select{| or \'typename\'}0 after the parameter list", | ||
[ | [b]=n, | ||
[ | [j]="template template parameter requires \'class\'(?:| or \'typename\') after the parameter list", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"cbd8125a6ad2",1333690003,"Restrict fixit for missing \'class\' in template template parameters.","Restrict fixit for missing \'class\' in template template parameters."}, | ||
[k]={{ | [k]={{gc,941,"/// ParseTemplateTemplateParameter - Handle the parsing of template\n/// template parameters.\n///\n/// type-parameter: [C++ temp.param]\n/// template-head type-parameter-key ...[opt] identifier[opt]\n/// template-head type-parameter-key identifier[opt] = id-expression\n/// type-parameter-key:\n/// \'class\'\n/// \'typename\' [C++1z]\n/// template-head: [C++2a]\n/// \'template\' \'<\' template-parameter-list \'>\'\n/// requires-clause[opt]\nNamedDecl *Parser::ParseTemplateTemplateParameter(unsigned Depth, unsigned Position) {\n // Provide an ExtWarn if the C++1z feature of using \'typename\' here is used.\n // Generate a meaningful error if the user forgot to put class before the\n // identifier, comma, or greater. Provide a fixit if the identifier, comma,\n // or greater appear immediately or after \'struct\'. In the latter case,\n // replace the keyword with \'class\'.\n if (!TryConsumeToken(tok::kw_class)) {\n if (Tok.is(tok::kw_typename)) {\n } else if (Next.isOneOf(tok::identifier, tok::comma, tok::greater, tok::greatergreater, tok::ellipsis)) {\n Diag(Tok.getLocation(), diag::err_class_on_template_template_param) << getLangOpts().CPlusPlus17 << (Replace ? FixItHint::CreateReplacement(Tok.getLocation(), \"class\") : FixItHint::CreateInsertion(Tok.getLocation(), \"class \"));"},{gc,947,"/// ParseTemplateTemplateParameter - Handle the parsing of template\n/// template parameters.\n///\n/// type-parameter: [C++ temp.param]\n/// template-head type-parameter-key ...[opt] identifier[opt]\n/// template-head type-parameter-key identifier[opt] = id-expression\n/// type-parameter-key:\n/// \'class\'\n/// \'typename\' [C++1z]\n/// template-head: [C++2a]\n/// \'template\' \'<\' template-parameter-list \'>\'\n/// requires-clause[opt]\nNamedDecl *Parser::ParseTemplateTemplateParameter(unsigned Depth, unsigned Position) {\n // Provide an ExtWarn if the C++1z feature of using \'typename\' here is used.\n // Generate a meaningful error if the user forgot to put class before the\n // identifier, comma, or greater. Provide a fixit if the identifier, comma,\n // or greater appear immediately or after \'struct\'. In the latter case,\n // replace the keyword with \'class\'.\n if (!TryConsumeToken(tok::kw_class)) {\n if (Tok.is(tok::kw_typename)) {\n } else if (Next.isOneOf(tok::identifier, tok::comma, tok::greater, tok::greatergreater, tok::ellipsis)) {\n } else\n Diag(Tok.getLocation(), diag::err_class_on_template_template_param) << getLangOpts().CPlusPlus17;"}}, | ||
[o]={ | [o]={ | ||
[ | [Vb]={"clang/test/Parser/cxx2a-concept-declaration.cpp:12:29: error: template template parameter requires \'class\' or \'typename\' after the parameter list"} | ||
} | } | ||
}, | }, | ||
["err_class_property_found"]={ | ["err_class_property_found"]={ | ||
[ | [e]="property A is a class property; did you mean to access it with class \'B\'?", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="property %0 is a class property; did you mean to access it with class \'%1\'?", | ||
[ | [b]=n, | ||
[ | [j]="property (.*?) is a class property; did you mean to access it with class \'(.*?)\'\\?", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"2b2b1a920087",1467154909,"ObjC Class Property: diagnostics when accessing a class property using instance.","ObjC Class Property: diagnostics when accessing a class property using instance."}, | ||
[k]={{ | [k]={{M,2117,"/// HandleExprPropertyRefExpr - Handle foo.bar where foo is a pointer to an\n/// objective C interface. This is a property reference expression.\nExprResult Sema::HandleExprPropertyRefExpr(const ObjCObjectPointerType *OPT, Expr *BaseExpr, SourceLocation OpLoc, DeclarationName MemberName, SourceLocation MemberLoc, SourceLocation SuperLoc, QualType SuperType, bool Super) {\n if (TypoCorrection Corrected = CorrectTypo(DeclarationNameInfo(MemberName, MemberLoc), LookupOrdinaryName, nullptr, nullptr, CCC, CTK_ErrorRecovery, IFace, false, OPT)) {\n if (TypoResult.isIdentifier() && TypoResult.getAsIdentifierInfo() == Member) {\n if (ChosenDecl && isa<ObjCPropertyDecl>(ChosenDecl))\n if (cast<ObjCPropertyDecl>(ChosenDecl)->isClassProperty()) {\n Diag(MemberLoc, diag::err_class_property_found) << MemberName << OPT->getInterfaceDecl()->getName() << FixItHint::CreateReplacement(BaseExpr->getSourceRange(), OPT->getInterfaceDecl()->getName());"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/objc-class-property.m"]={"clang/test/SemaObjC/objc-class-property.m:40:5: error: property \'c\' is a class property; did you mean to access it with class \'A\'?"} | ["clang/test/SemaObjC/objc-class-property.m"]={"clang/test/SemaObjC/objc-class-property.m:40:5: error: property \'c\' is a class property; did you mean to access it with class \'A\'?"} | ||
Line 8,030: | Line 8,050: | ||
}, | }, | ||
["err_class_redeclared_with_different_access"]={ | ["err_class_redeclared_with_different_access"]={ | ||
[ | [e]="A redeclared with \'B\' access", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%0 redeclared with \'%1\' access", | ||
[ | [b]=n, | ||
[ | [j]="(.*?) redeclared with \'(.*?)\' access", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"2ed6ceba1d90",1238027057,"Check that the access specifier of a member redeclaration is the same as the original declaration.","Check that the access specifier of a member redeclaration is the same as the original declaration."}, | ||
[k]={{ | [k]={{eb,53,"/// SetMemberAccessSpecifier - Set the access specifier of a member.\n/// Returns true on error (when the previous member decl access specifier\n/// is different from the new member decl access specifier).\nbool Sema::SetMemberAccessSpecifier(NamedDecl *MemberDecl, NamedDecl *PrevMemberDecl, AccessSpecifier LexicalAS) {\n // C++ [class.access.spec]p3: When a member is redeclared its access\n // specifier must be same as its initial declaration.\n if (LexicalAS != AS_none && LexicalAS != PrevMemberDecl->getAccess()) {\n Diag(MemberDecl->getLocation(), diag::err_class_redeclared_with_different_access) << MemberDecl << LexicalAS;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/access.cpp"]={"clang/test/SemaCXX/access.cpp:7:12: error: \'S\' redeclared with \'public\' access","clang/test/SemaCXX/access.cpp:14:11: error: \'C\' redeclared with \'private\' access","clang/test/SemaCXX/access.cpp:22:33: error: \'A\' redeclared with \'private\' access","clang/test/SemaCXX/access.cpp:32:11: error: \'X\' redeclared with \'public\' access"} | ["clang/test/SemaCXX/access.cpp"]={"clang/test/SemaCXX/access.cpp:7:12: error: \'S\' redeclared with \'public\' access","clang/test/SemaCXX/access.cpp:14:11: error: \'C\' redeclared with \'private\' access","clang/test/SemaCXX/access.cpp:22:33: error: \'A\' redeclared with \'private\' access","clang/test/SemaCXX/access.cpp:32:11: error: \'X\' redeclared with \'public\' access"} | ||
Line 8,045: | Line 8,065: | ||
}, | }, | ||
["err_class_stub_subclassing_mismatch"]={ | ["err_class_stub_subclassing_mismatch"]={ | ||
[e]="\'objc_class_stub\' attribute cannot be specified on a class that does not have the \'objc_subclassing_restricted\' attribute", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'objc_class_stub\' attribute cannot be specified on a class that does not have the \'objc_subclassing_restricted\' attribute", | [h]="\'objc_class_stub\' attribute cannot be specified on a class that does not have the \'objc_subclassing_restricted\' attribute", | ||
[ | [b]=n, | ||
[ | [j]="\'objc_class_stub\' attribute cannot be specified on a class that does not have the \'objc_subclassing_restricted\' attribute", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"2c91c3b7af7c",1559189341,"Add the `objc_class_stub` attribute.","Add the `objc_class_stub` attribute."}, | |||
[ | [k]={{O,4204,"// Note: For class/category implementations, allMethods is always null.\nDecl *Sema::ActOnAtEnd(Scope *S, SourceRange AtEnd, ArrayRef<Decl *> allMethods, ArrayRef<DeclGroupPtrTy> allTUVars) {\n if (ObjCImplementationDecl *IC = dyn_cast<ObjCImplementationDecl>(ClassDecl)) {\n } else if (ObjCCategoryImplDecl *CatImplClass = dyn_cast<ObjCCategoryImplDecl>(ClassDecl)) {\n } else if (const auto *IntfDecl = dyn_cast<ObjCInterfaceDecl>(ClassDecl)) {\n if (IntfDecl->hasAttr<ObjCClassStubAttr>() && !IntfDecl->hasAttr<ObjCSubclassingRestrictedAttr>())\n Diag(IntfDecl->getLocation(), diag::err_class_stub_subclassing_mismatch);"}}, | ||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/class-stub-attr.m"]={"clang/test/SemaObjC/class-stub-attr.m:8:12: error: \'objc_class_stub\' attribute cannot be specified on a class that does not have the \'objc_subclassing_restricted\' attribute"} | ["clang/test/SemaObjC/class-stub-attr.m"]={"clang/test/SemaObjC/class-stub-attr.m:8:12: error: \'objc_class_stub\' attribute cannot be specified on a class that does not have the \'objc_subclassing_restricted\' attribute"} | ||
Line 8,060: | Line 8,080: | ||
}, | }, | ||
["err_cmse_pi_are_incompatible"]={ | ["err_cmse_pi_are_incompatible"]={ | ||
[ | [e]="cmse is not compatible with ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cmse is not compatible with %select{RWPI|ROPI}0", | ||
[ | [b]=n, | ||
[ | [j]="cmse is not compatible with (?:RWPI|ROPI)", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={Wb,1534346725,hb,hb}, | ||
[k]={{"clang/lib/Driver/ToolChains/Clang.cpp",5263,"#endif\n if (Args.hasArg(options::OPT_mcmse) && !Args.hasArg(options::OPT_fallow_unsupported)) {\n if (IsROPI)\n D.Diag(diag::err_cmse_pi_are_incompatible) << IsROPI;"},{"clang/lib/Driver/ToolChains/Clang.cpp",5265,"#endif\n if (Args.hasArg(options::OPT_mcmse) && !Args.hasArg(options::OPT_fallow_unsupported)) {\n if (IsRWPI)\n D.Diag(diag::err_cmse_pi_are_incompatible) << !IsRWPI;"}} | [k]={{"clang/lib/Driver/ToolChains/Clang.cpp",5263,"#endif\n if (Args.hasArg(options::OPT_mcmse) && !Args.hasArg(options::OPT_fallow_unsupported)) {\n if (IsROPI)\n D.Diag(diag::err_cmse_pi_are_incompatible) << IsROPI;"},{"clang/lib/Driver/ToolChains/Clang.cpp",5265,"#endif\n if (Args.hasArg(options::OPT_mcmse) && !Args.hasArg(options::OPT_fallow_unsupported)) {\n if (IsRWPI)\n D.Diag(diag::err_cmse_pi_are_incompatible) << !IsRWPI;"}} | ||
}, | }, | ||
["err_cocoa_naming_owned_rule"]={ | ["err_cocoa_naming_owned_rule"]={ | ||
[e]="property follows Cocoa naming convention for returning \'owned\' objects", | |||
[d]=l, | |||
[f]=m, | |||
[h]="property follows Cocoa naming convention for returning \'owned\' objects", | [h]="property follows Cocoa naming convention for returning \'owned\' objects", | ||
[ | [b]=n, | ||
[ | [j]="property follows Cocoa naming convention for returning \'owned\' objects", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"65b13779118c",1389315228,"ObjectiveC. 1) Warn when @dynamic (as well as synthesize) ","ObjectiveC. 1) Warn when @dynamic (as well as synthesize) "}, | |||
[k]={{Y,2275,"void Sema::DiagnoseOwningPropertyGetterSynthesis(const ObjCImplementationDecl *D) {\n for (const auto *PID : D->property_impls()) {\n if (PD && !PD->hasAttr<NSReturnsNotRetainedAttr>() && !PD->isClassProperty()) {\n if (family == OMF_alloc || family == OMF_copy || family == OMF_mutableCopy || family == OMF_new) {\n if (getLangOpts().ObjCAutoRefCount)\n Diag(PD->getLocation(), diag::err_cocoa_naming_owned_rule);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/arc-decls.m"]={"clang/test/SemaObjC/arc-decls.m:70:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:71:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:72:21: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:74:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:75:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:76:21: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:103:33: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:93:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:98:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:100:23: error: property follows Cocoa naming convention for returning \'owned\' objects"} | ["clang/test/SemaObjC/arc-decls.m"]={"clang/test/SemaObjC/arc-decls.m:70:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:71:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:72:21: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:74:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:75:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:76:21: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:103:33: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:93:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:98:23: error: property follows Cocoa naming convention for returning \'owned\' objects","clang/test/SemaObjC/arc-decls.m:100:23: error: property follows Cocoa naming convention for returning \'owned\' objects"} | ||
Line 8,087: | Line 8,107: | ||
}, | }, | ||
["err_collection_expr_type"]={ | ["err_collection_expr_type"]={ | ||
[ | [e]="the type A is not a pointer to a fast-enumerable object", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="the type %0 is not a pointer to a fast-enumerable object", | ||
[ | [b]=n, | ||
[ | [j]="the type (.*?) is not a pointer to a fast\\-enumerable object", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{bb,2231,"ExprResult Sema::CheckObjCForCollectionOperand(SourceLocation forLoc, Expr *collection) {\n if (!pointerType)\n return Diag(forLoc, diag::err_collection_expr_type) << collection->getType() << collection->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjCXX/instantiate-stmt.mm"]={"clang/test/SemaObjCXX/instantiate-stmt.mm:40:3: error: the type \'vector\' is not a pointer to a fast-enumerable object","clang/test/SemaObjCXX/instantiate-stmt.mm:46:3: error: the type \'vector\' is not a pointer to a fast-enumerable object","clang/test/SemaObjCXX/instantiate-stmt.mm:50:3: error: the type \'vector\' is not a pointer to a fast-enumerable object","clang/test/SemaObjCXX/instantiate-stmt.mm:54:3: error: the type \'vector\' is not a pointer to a fast-enumerable object"} | ["clang/test/SemaObjCXX/instantiate-stmt.mm"]={"clang/test/SemaObjCXX/instantiate-stmt.mm:40:3: error: the type \'vector\' is not a pointer to a fast-enumerable object","clang/test/SemaObjCXX/instantiate-stmt.mm:46:3: error: the type \'vector\' is not a pointer to a fast-enumerable object","clang/test/SemaObjCXX/instantiate-stmt.mm:50:3: error: the type \'vector\' is not a pointer to a fast-enumerable object","clang/test/SemaObjCXX/instantiate-stmt.mm:54:3: error: the type \'vector\' is not a pointer to a fast-enumerable object"} | ||
Line 8,102: | Line 8,122: | ||
}, | }, | ||
["err_complex_mode_vector_type"]={ | ["err_complex_mode_vector_type"]={ | ||
[e]="type of machine mode does not support base vector types", | |||
[d]=l, | |||
[f]=m, | |||
[h]="type of machine mode does not support base vector types", | [h]="type of machine mode does not support base vector types", | ||
[ | [b]=n, | ||
[ | [j]="type of machine mode does not support base vector types", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"326057d0da96",1434699981,"[ATTRIBUTE] Support base vector types of __attribute__((mode)), patch by Alexey Frolov","[ATTRIBUTE] Support base vector types of __attribute__((mode)), patch by Alexey Frolov"}, | |||
[ | |||
[ | |||
[k]={{q,4853,"void Sema::AddModeAttr(Decl *D, const AttributeCommonInfo &CI, IdentifierInfo *Name, bool InInstantiation) {\n if (VectorSize.getBoolValue()) {\n } else if (const auto *OldVT = OldTy->getAs<VectorType>()) {\n // Complex machine mode does not support base vector types.\n if (ComplexMode) {\n Diag(AttrLoc, diag::err_complex_mode_vector_type);"}}, | [k]={{q,4853,"void Sema::AddModeAttr(Decl *D, const AttributeCommonInfo &CI, IdentifierInfo *Name, bool InInstantiation) {\n if (VectorSize.getBoolValue()) {\n } else if (const auto *OldVT = OldTy->getAs<VectorType>()) {\n // Complex machine mode does not support base vector types.\n if (ComplexMode) {\n Diag(AttrLoc, diag::err_complex_mode_vector_type);"}}, | ||
[o]={ | [o]={ | ||
Line 8,117: | Line 8,137: | ||
}, | }, | ||
["err_compound_literal_with_address_space"]={ | ["err_compound_literal_with_address_space"]={ | ||
[e]="compound literal in function scope may not be qualified with an address space", | |||
[d]=l, | |||
[f]=m, | |||
[h]="compound literal in function scope may not be qualified with an address space", | [h]="compound literal in function scope may not be qualified with an address space", | ||
[ | [b]=n, | ||
[ | [j]="compound literal in function scope may not be qualified with an address space", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"7fa8af0abee8",1536175360,"Forbid address spaces on compound literals in local scope.","Forbid address spaces on compound literals in local scope."}, | |||
[k]={{A,7793,"ExprResult Sema::BuildCompoundLiteralExpr(SourceLocation LParenLoc, TypeSourceInfo *TInfo, SourceLocation RParenLoc, Expr *LiteralExpr) {\n if (isFileScope) {\n } else if (literalType.getAddressSpace() != LangAS::opencl_private && literalType.getAddressSpace() != LangAS::Default) {\n Diag(LParenLoc, diag::err_compound_literal_with_address_space) << SourceRange(LParenLoc, LiteralExpr->getSourceRange().getEnd());"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/address_spaces.c"]={"clang/test/Sema/address_spaces.c:90:3: error: compound literal in function scope may not be qualified with an address space","clang/test/Sema/address_spaces.c:91:3: error: compound literal in function scope may not be qualified with an address space","clang/test/Sema/address_spaces.c:92:3: error: compound literal in function scope may not be qualified with an address space"} | ["clang/test/Sema/address_spaces.c"]={"clang/test/Sema/address_spaces.c:90:3: error: compound literal in function scope may not be qualified with an address space","clang/test/Sema/address_spaces.c:91:3: error: compound literal in function scope may not be qualified with an address space","clang/test/Sema/address_spaces.c:92:3: error: compound literal in function scope may not be qualified with an address space"} | ||
Line 8,132: | Line 8,152: | ||
}, | }, | ||
["err_compound_qualified_function_type"]={ | ["err_compound_qualified_function_type"]={ | ||
[ | [e]="... to function type ...cannot have \'A\' qualifier", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{block pointer|pointer|reference}0 to function type %select{%2 |}1cannot have \'%3\' qualifier", | ||
[ | [b]=n, | ||
[ | [j]="(?:block pointer|pointer|reference) to function type (?:(.*?) |)cannot have \'(.*?)\' qualifier", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"63168c75333b",1328871911,"PR11684, core issue 1417:","PR11684, core issue 1417:"}, | ||
[k]={{ | [k]={{t,2133,"/// Check whether the type T is a qualified function type, and if it is,\n/// diagnose that it cannot be contained within the given kind of declarator.\nstatic bool checkQualifiedFunction(Sema &S, QualType T, SourceLocation Loc, QualifiedFunctionKind QFK) {\n S.Diag(Loc, diag::err_compound_qualified_function_type) << QFK << isa<FunctionType>(T.IgnoreParens()) << T << getFunctionQualifiersAsString(FPT);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl.decl/dcl.meaning/dcl.fct/p6.cpp"]={"clang/test/CXX/dcl.decl/dcl.meaning/dcl.fct/p6.cpp:24:13: error: pointer to function type \'void () const\' cannot have \'const\' qualifier","clang/test/CXX/dcl.decl/dcl.meaning/dcl.fct/p6.cpp:25:13: error: reference to function type \'void () const\' cannot have \'const\' qualifier"} | ["clang/test/CXX/dcl.decl/dcl.meaning/dcl.fct/p6.cpp"]={"clang/test/CXX/dcl.decl/dcl.meaning/dcl.fct/p6.cpp:24:13: error: pointer to function type \'void () const\' cannot have \'const\' qualifier","clang/test/CXX/dcl.decl/dcl.meaning/dcl.fct/p6.cpp:25:13: error: reference to function type \'void () const\' cannot have \'const\' qualifier"} | ||
Line 8,147: | Line 8,167: | ||
}, | }, | ||
["err_concept_decls_may_only_appear_in_global_namespace_scope"]={ | ["err_concept_decls_may_only_appear_in_global_namespace_scope"]={ | ||
[e]="concept declarations may only appear in global or namespace scope", | |||
[d]=l, | |||
[f]=m, | |||
[h]="concept declarations may only appear in global or namespace scope", | [h]="concept declarations may only appear in global or namespace scope", | ||
[ | [b]=n, | ||
[ | [j]="concept declarations may only appear in global or namespace scope", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"d7aae33a9513",1562793949,Qb,Qb}, | |||
[k]={{nc,8990,"Decl *Sema::ActOnConceptDefinition(Scope *S, MultiTemplateParamsArg TemplateParameterLists, IdentifierInfo *Name, SourceLocation NameLoc, Expr *ConstraintExpr) {\n if (!DC->getRedeclContext()->isFileContext()) {\n Diag(NameLoc, diag::err_concept_decls_may_only_appear_in_global_namespace_scope);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Vb]={"clang/test/Parser/cxx2a-concept-declaration.cpp:18:32: error: concept declarations may only appear in global or namespace scope"} | ||
} | } | ||
}, | }, | ||
["err_concept_definition_not_identifier"]={ | ["err_concept_definition_not_identifier"]={ | ||
[e]="name defined in concept definition must be an identifier", | |||
[d]=l, | |||
[f]=m, | |||
[h]="name defined in concept definition must be an identifier", | [h]="name defined in concept definition must be an identifier", | ||
[ | [b]=n, | ||
[ | [j]="name defined in concept definition must be an identifier", | ||
[c]=a, | |||
[ | [i]="Concepts Issue", | ||
[g]={"d7aae33a9513",1562793949,Qb,Qb}, | |||
[k]={{gc,417,"/// \\brief Parse a single declaration that declares a concept.\n///\n/// \\param DeclEnd will receive the source location of the last token\n/// within this declaration.\n///\n/// \\returns the new declaration.\nDecl *Parser::ParseConceptDefinition(const ParsedTemplateInfo &TemplateInfo, SourceLocation &DeclEnd) {\n if (SS.isNotEmpty())\n Diag(SS.getBeginLoc(), diag::err_concept_definition_not_identifier);"},{gc,431,"/// \\brief Parse a single declaration that declares a concept.\n///\n/// \\param DeclEnd will receive the source location of the last token\n/// within this declaration.\n///\n/// \\returns the new declaration.\nDecl *Parser::ParseConceptDefinition(const ParsedTemplateInfo &TemplateInfo, SourceLocation &DeclEnd) {\n if (Result.getKind() != UnqualifiedIdKind::IK_Identifier) {\n Diag(Result.getBeginLoc(), diag::err_concept_definition_not_identifier);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Vb]={"clang/test/Parser/cxx2a-concept-declaration.cpp:58:20: error: name defined in concept definition must be an identifier","clang/test/Parser/cxx2a-concept-declaration.cpp:61:30: error: name defined in concept definition must be an identifier","clang/test/Parser/cxx2a-concept-declaration.cpp:70:30: error: name defined in concept definition must be an identifier"} | ||
} | } | ||
}, | }, | ||
["err_concept_extra_headers"]={ | ["err_concept_extra_headers"]={ | ||
[e]="extraneous template parameter list in concept definition", | |||
[d]=l, | |||
[f]=m, | |||
[h]="extraneous template parameter list in concept definition", | [h]="extraneous template parameter list in concept definition", | ||
[ | [b]=n, | ||
[ | [j]="extraneous template parameter list in concept definition", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"936de9d66600",1524624146,"[c++2a] [concepts] Add rudimentary parsing support for template concept declarations","[c++2a] [concepts] Add rudimentary parsing support for template concept declarations"}, | |||
[k]={{nc,8995,"Decl *Sema::ActOnConceptDefinition(Scope *S, MultiTemplateParamsArg TemplateParameterLists, IdentifierInfo *Name, SourceLocation NameLoc, Expr *ConstraintExpr) {\n if (TemplateParameterLists.size() > 1) {\n Diag(NameLoc, diag::err_concept_extra_headers);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Vb]={"clang/test/Parser/cxx2a-concept-declaration.cpp:27:9: error: extraneous template parameter list in concept definition"} | ||
} | } | ||
}, | }, | ||
["err_concept_legacy_bool_keyword"]={ | ["err_concept_legacy_bool_keyword"]={ | ||
[e]="ISO C++ does not permit the \'bool\' keyword after \'concept\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="ISO C++ does not permit the \'bool\' keyword after \'concept\'", | [h]="ISO C++ does not permit the \'bool\' keyword after \'concept\'", | ||
[ | [b]=n, | ||
[ | [j]="ISO C\\+\\+ does not permit the \'bool\' keyword after \'concept\'", | ||
[c]=a, | |||
[i]="Concepts Issue", | |||
[g]={"9061928ebbb1",1669659698,"Stop accepting \'bool\' in a concept declaration as an extension.","Stop accepting \'bool\' in a concept declaration as an extension."}, | |||
[ | [k]={{gc,399,"/// \\brief Parse a single declaration that declares a concept.\n///\n/// \\param DeclEnd will receive the source location of the last token\n/// within this declaration.\n///\n/// \\returns the new declaration.\nDecl *Parser::ParseConceptDefinition(const ParsedTemplateInfo &TemplateInfo, SourceLocation &DeclEnd) {\n if (TryConsumeToken(tok::kw_bool, BoolKWLoc))\n Diag(Tok.getLocation(), diag::err_concept_legacy_bool_keyword) << FixItHint::CreateRemoval(SourceLocation(BoolKWLoc));"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Vb]={"clang/test/Parser/cxx2a-concept-declaration.cpp:52:35: error: ISO C++ does not permit the \'bool\' keyword after \'concept\'"} | ||
} | } | ||
}, | }, | ||
["err_concept_no_associated_constraints"]={ | ["err_concept_no_associated_constraints"]={ | ||
[e]="concept cannot have associated constraints", | |||
[d]=l, | |||
[f]=m, | |||
[h]="concept cannot have associated constraints", | [h]="concept cannot have associated constraints", | ||
[ | [b]=n, | ||
[ | [j]="concept cannot have associated constraints", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"936de9d66600",1524624146,"[c++2a] [concepts] Add rudimentary parsing support for template concept declarations","[c++2a] [concepts] Add rudimentary parsing support for template concept declarations"}, | |||
[k]={{nc,9030,"Decl *Sema::ActOnConceptDefinition(Scope *S, MultiTemplateParamsArg TemplateParameterLists, IdentifierInfo *Name, SourceLocation NameLoc, Expr *ConstraintExpr) {\n if (NewDecl->hasAssociatedConstraints()) {\n Diag(NameLoc, diag::err_concept_no_associated_constraints);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/CXX/temp/concept/p4.cpp"]={"clang/test/CXX/temp/concept/p4.cpp:4:9: error: concept cannot have associated constraints"} | ["clang/test/CXX/temp/concept/p4.cpp"]={"clang/test/CXX/temp/concept/p4.cpp:4:9: error: concept cannot have associated constraints"} | ||
Line 8,222: | Line 8,242: | ||
}, | }, | ||
["err_concept_no_parameters"]={ | ["err_concept_no_parameters"]={ | ||
[e]="concept template parameter list must have at least one parameter; explicit specialization of concepts is not allowed", | |||
[d]=l, | |||
[f]=m, | |||
[h]="concept template parameter list must have at least one parameter; explicit specialization of concepts is not allowed", | [h]="concept template parameter list must have at least one parameter; explicit specialization of concepts is not allowed", | ||
[ | [b]=n, | ||
[ | [j]="concept template parameter list must have at least one parameter; explicit specialization of concepts is not allowed", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"d7aae33a9513",1562793949,Qb,Qb}, | |||
[k]={{nc,9002,"Decl *Sema::ActOnConceptDefinition(Scope *S, MultiTemplateParamsArg TemplateParameterLists, IdentifierInfo *Name, SourceLocation NameLoc, Expr *ConstraintExpr) {\n if (Params->size() == 0) {\n Diag(NameLoc, diag::err_concept_no_parameters);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Vb]={"clang/test/Parser/cxx2a-concept-declaration.cpp:8:29: error: concept template parameter list must have at least one parameter; explicit specialization of concepts is not allowed","clang/test/Parser/cxx2a-concept-declaration.cpp:12:48: error: concept template parameter list must have at least one parameter; explicit specialization of concepts is not allowed","clang/test/Parser/cxx2a-concept-declaration.cpp:55:20: error: concept template parameter list must have at least one parameter; explicit specialization of concepts is not allowed"} | ||
} | } | ||
}, | }, | ||
["err_cond_voidptr_arc"]={ | ["err_cond_voidptr_arc"]={ | ||
[ | [e]="operands to conditional of types A and B are incompatible in ARC mode", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="operands to conditional of types%diff{ $ and $|}0,1 are incompatible in ARC mode", | ||
[ | [b]=n, | ||
[ | [j]="operands to conditional of types(?: (.*?) and (.*?)|) are incompatible in ARC mode", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"8a78a58188b7",1330129424,"Improve the diagnostic in ARC mode when a conditional with an Objective-C type and void* is used. <...","Improve the diagnostic in ARC mode when a conditional with an Objective-C type and void* is used. <rdar://problem/10486347>."}, | ||
[k]={{ | [k]={{A,9372,"/// FindCompositeObjCPointerType - Helper method to find composite type of\n/// two objective-c pointer types of the two input expressions.\nQualType Sema::FindCompositeObjCPointerType(ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n // Check Objective-C object pointer types and \'void *\'\n if (LHSTy->isVoidPointerType() && RHSTy->isObjCObjectPointerType()) {\n if (getLangOpts().ObjCAutoRefCount) {\n Diag(QuestionLoc, diag::err_cond_voidptr_arc) << LHSTy << RHSTy << LHS.get()->getSourceRange() << RHS.get()->getSourceRange();"},{A,9507,"/// FindCompositeObjCPointerType - Helper method to find composite type of\n/// two objective-c pointer types of the two input expressions.\nQualType Sema::FindCompositeObjCPointerType(ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSTy->isObjCObjectPointerType() && RHSTy->isVoidPointerType()) {\n if (getLangOpts().ObjCAutoRefCount) {\n Diag(QuestionLoc, diag::err_cond_voidptr_arc) << LHSTy << RHSTy << LHS.get()->getSourceRange() << RHS.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/arc-type-conversion.m"]={"clang/test/SemaObjC/arc-type-conversion.m:96:12: error: operands to conditional of types \'id\' and \'void *\' are incompatible in ARC mode","clang/test/SemaObjC/arc-type-conversion.m:97:12: error: operands to conditional of types \'void *\' and \'id\' are incompatible in ARC mode"} | ["clang/test/SemaObjC/arc-type-conversion.m"]={"clang/test/SemaObjC/arc-type-conversion.m:96:12: error: operands to conditional of types \'id\' and \'void *\' are incompatible in ARC mode","clang/test/SemaObjC/arc-type-conversion.m:97:12: error: operands to conditional of types \'void *\' and \'id\' are incompatible in ARC mode"} | ||
Line 8,252: | Line 8,272: | ||
}, | }, | ||
["err_conditional_ambiguous"]={ | ["err_conditional_ambiguous"]={ | ||
[ | [e]="conditional expression is ambiguous; A can be converted to B and vice versa", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="conditional expression is ambiguous; %diff{$ can be converted to $ and vice versa|types can be convert to each other}0,1", | ||
[ | [b]=n, | ||
[ | [j]="conditional expression is ambiguous; (?:(.*?) can be converted to (.*?) and vice versa|types can be convert to each other)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"1a99f441e64c",1239904287,"Fix a crash bug when comparing overload quality of conversion operators with conversion constructors...","Fix a crash bug when comparing overload quality of conversion operators with conversion constructors."}, | ||
[k]={{y,6625,"/// Check the operands of ?: under C++ semantics.\n///\n/// See C++ [expr.cond]. Note that LHS is never null, even for the GNU x ?: y\n/// extension. In this case, LHS == Cond. (But they\'re not aliases.)\n///\n/// This function also implements GCC\'s vector extension and the\n/// OpenCL/ext_vector_type extension for conditionals. The vector extensions\n/// permit the use of a?b:c where the type of a is that of a integer vector with\n/// the same number of elements and size as the vectors of b and c. If one of\n/// either b or c is a scalar it is implicitly converted to match the type of\n/// the vector. Otherwise the expression is ill-formed. If both b and c are\n/// scalars, then b and c are checked and converted to the type of a if\n/// possible.\n///\n/// The expressions are evaluated differently for GCC\'s and OpenCL\'s extensions.\n/// For the GCC extension, the ?: operator is evaluated as\n/// (a[0] != 0 ? b[0] : c[0], .. , a[n] != 0 ? b[n] : c[n]).\n/// For the OpenCL extensions, the ?: operator is evaluated as\n/// (most-significant-bit-set(a[0]) ? b[0] : c[0], .. ,\n/// most-significant-bit-set(a[n]) ? b[n] : c[n]).\nQualType Sema::CXXCheckConditionalOperands(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, ExprObjectKind &OK, SourceLocation QuestionLoc) {\n // C++11 [expr.cond]p3\n // Otherwise, if the second and third operand have different types, and\n // either has (cv) class type [...] an attempt is made to convert each of\n // those operands to the type of the other.\n if (!Context.hasSameType(LTy, RTy) && (LTy->isRecordType() || RTy->isRecordType())) {\n // If both can be converted, [...] the program is ill-formed.\n if (HaveL2R && HaveR2L) {\n Diag(QuestionLoc, diag::err_conditional_ambiguous) << LTy << RTy << LHS.get()->getSourceRange() << RHS.get()->getSourceRange();"}}, | [k]={{y,6625,"/// Check the operands of ?: under C++ semantics.\n///\n/// See C++ [expr.cond]. Note that LHS is never null, even for the GNU x ?: y\n/// extension. In this case, LHS == Cond. (But they\'re not aliases.)\n///\n/// This function also implements GCC\'s vector extension and the\n/// OpenCL/ext_vector_type extension for conditionals. The vector extensions\n/// permit the use of a?b:c where the type of a is that of a integer vector with\n/// the same number of elements and size as the vectors of b and c. If one of\n/// either b or c is a scalar it is implicitly converted to match the type of\n/// the vector. Otherwise the expression is ill-formed. If both b and c are\n/// scalars, then b and c are checked and converted to the type of a if\n/// possible.\n///\n/// The expressions are evaluated differently for GCC\'s and OpenCL\'s extensions.\n/// For the GCC extension, the ?: operator is evaluated as\n/// (a[0] != 0 ? b[0] : c[0], .. , a[n] != 0 ? b[n] : c[n]).\n/// For the OpenCL extensions, the ?: operator is evaluated as\n/// (most-significant-bit-set(a[0]) ? b[0] : c[0], .. ,\n/// most-significant-bit-set(a[n]) ? b[n] : c[n]).\nQualType Sema::CXXCheckConditionalOperands(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, ExprObjectKind &OK, SourceLocation QuestionLoc) {\n // C++11 [expr.cond]p3\n // Otherwise, if the second and third operand have different types, and\n // either has (cv) class type [...] an attempt is made to convert each of\n // those operands to the type of the other.\n if (!Context.hasSameType(LTy, RTy) && (LTy->isRecordType() || RTy->isRecordType())) {\n // If both can be converted, [...] the program is ill-formed.\n if (HaveL2R && HaveR2L) {\n Diag(QuestionLoc, diag::err_conditional_ambiguous) << LTy << RTy << LHS.get()->getSourceRange() << RHS.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 8,267: | Line 8,287: | ||
}, | }, | ||
["err_conditional_ambiguous_ovl"]={ | ["err_conditional_ambiguous_ovl"]={ | ||
[ | [e]="conditional expression is ambiguous; A and B can be converted to several common types", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="conditional expression is ambiguous; %diff{$ and $|types}0,1 can be converted to several common types", | ||
[ | [b]=n, | ||
[ | [j]="conditional expression is ambiguous; (?:(.*?) and (.*?)|types) can be converted to several common types", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"1a99f441e64c",1239904287,"Fix a crash bug when comparing overload quality of conversion operators with conversion constructors...","Fix a crash bug when comparing overload quality of conversion operators with conversion constructors."}, | ||
[k]={{y,6267,"/// Try to find a common type for two according to C++0x 5.16p5.\n///\n/// This is part of the parameter validation for the ? operator. If either\n/// value operand is a class type, overload resolution is used to find a\n/// conversion to a common type.\nstatic bool FindConditionalOverload(Sema &Self, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n case OR_Ambiguous:\n Self.Diag(QuestionLoc, diag::err_conditional_ambiguous_ovl) << LHS.get()->getType() << RHS.get()->getType() << LHS.get()->getSourceRange() << RHS.get()->getSourceRange();"}} | [k]={{y,6267,"/// Try to find a common type for two according to C++0x 5.16p5.\n///\n/// This is part of the parameter validation for the ? operator. If either\n/// value operand is a class type, overload resolution is used to find a\n/// conversion to a common type.\nstatic bool FindConditionalOverload(Sema &Self, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n case OR_Ambiguous:\n Self.Diag(QuestionLoc, diag::err_conditional_ambiguous_ovl) << LHS.get()->getType() << RHS.get()->getType() << LHS.get()->getSourceRange() << RHS.get()->getSourceRange();"}} | ||
}, | }, | ||
["err_conditional_vector_cond_result_mismatch"]={ | ["err_conditional_vector_cond_result_mismatch"]={ | ||
[e]="cannot mix vectors and extended vectors in a vector conditional", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot mix vectors and extended vectors in a vector conditional", | [h]="cannot mix vectors and extended vectors in a vector conditional", | ||
[ | [b]=n, | ||
[ | [j]="cannot mix vectors and extended vectors in a vector conditional", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={sb,1590001902,T,T}, | |||
[ | |||
[ | |||
[k]={{y,6338,"QualType Sema::CheckVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSVT && RHSVT) {\n if (isa<ExtVectorType>(CondVT) != isa<ExtVectorType>(LHSVT)) {\n Diag(QuestionLoc, diag::err_conditional_vector_cond_result_mismatch) << /*isExtVector*/ isa<ExtVectorType>(CondVT);"}}, | [k]={{y,6338,"QualType Sema::CheckVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSVT && RHSVT) {\n if (isa<ExtVectorType>(CondVT) != isa<ExtVectorType>(LHSVT)) {\n Diag(QuestionLoc, diag::err_conditional_vector_cond_result_mismatch) << /*isExtVector*/ isa<ExtVectorType>(CondVT);"}}, | ||
[o]={ | [o]={ | ||
Line 8,294: | Line 8,314: | ||
}, | }, | ||
["err_conditional_vector_element_size"]={ | ["err_conditional_vector_element_size"]={ | ||
[ | [e]="vector condition type A and result type B do not have elements of the same size", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="vector condition type %0 and result type %1 do not have elements of the same size", | ||
[ | [b]=n, | ||
[ | [j]="vector condition type (.*?) and result type (.*?) do not have elements of the same size", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e8d2aaf32021",1423031898,"OpenCL: handle ternary operator when the condition is a vector","OpenCL: handle ternary operator when the condition is a vector"}, | ||
[k]={{ | [k]={{A,8963,"/// Convert scalar operands to a vector that matches the\n/// condition in length.\n///\n/// Used when handling the OpenCL conditional operator where the\n/// condition is a vector while the other operands are scalar.\n///\n/// We first compute the \"result type\" for the scalar operands\n/// according to OpenCL v1.1 s6.3.i. Both operands are then converted\n/// into a vector of that type where the length matches the condition\n/// vector type. s6.11.6 requires that the element types of the result\n/// and the condition must have the same number of bits.\nstatic QualType OpenCLConvertScalarsToVectors(Sema &S, ExprResult &LHS, ExprResult &RHS, QualType CondTy, SourceLocation QuestionLoc) {\n // Ensure that all types have the same number of bits\n if (S.Context.getTypeSize(CV->getElementType()) != S.Context.getTypeSize(ResTy)) {\n S.Diag(QuestionLoc, diag::err_conditional_vector_element_size) << CondTy << OS.str();"},{A,9044,"/// Return false if the vector condition type and the vector\n/// result type are compatible.\n///\n/// OpenCL v1.1 s6.11.6 requires that both vector types have the same\n/// number of elements, and their element types have the same number\n/// of bits.\nstatic bool checkVectorResult(Sema &S, QualType CondTy, QualType VecResTy, SourceLocation QuestionLoc) {\n if (S.Context.getTypeSize(CVE) != S.Context.getTypeSize(RVE)) {\n S.Diag(QuestionLoc, diag::err_conditional_vector_element_size) << CondTy << VecResTy;"},{y,6399,"QualType Sema::CheckVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (Context.getTypeSize(ResultElementTy) != Context.getTypeSize(CondElementTy)) {\n Diag(QuestionLoc, diag::err_conditional_vector_element_size) << CondType << ResultType;"},{y,6482,"QualType Sema::CheckSizelessVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (Context.getTypeSize(ResultElementTy) != Context.getTypeSize(CondElementTy)) {\n Diag(QuestionLoc, diag::err_conditional_vector_element_size) << CondType << ResultType;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaOpenCL/cond.cl"]={"clang/test/SemaOpenCL/cond.cl:72:12: error: vector condition type \'char2\' (vector of 2 \'char\' values) and result type (vector of 2 \'int\' values) do not have elements of the same size","clang/test/SemaOpenCL/cond.cl:77:12: error: vector condition type \'char2\' (vector of 2 \'char\' values) and result type \'int2\' (vector of 2 \'int\' values) do not have elements of the same size","clang/test/SemaOpenCL/cond.cl:82:12: error: vector condition type \'int2\' (vector of 2 \'int\' values) and result type (vector of 2 \'unsigned char\' values) do not have elements of the same size","clang/test/SemaOpenCL/cond.cl:97:12: error: vector condition type \'int2\' (vector of 2 \'int\' values) and result type \'char2\' (vector of 2 \'char\' values) do not have elements of the same size"} | ["clang/test/SemaOpenCL/cond.cl"]={"clang/test/SemaOpenCL/cond.cl:72:12: error: vector condition type \'char2\' (vector of 2 \'char\' values) and result type (vector of 2 \'int\' values) do not have elements of the same size","clang/test/SemaOpenCL/cond.cl:77:12: error: vector condition type \'char2\' (vector of 2 \'char\' values) and result type \'int2\' (vector of 2 \'int\' values) do not have elements of the same size","clang/test/SemaOpenCL/cond.cl:82:12: error: vector condition type \'int2\' (vector of 2 \'int\' values) and result type (vector of 2 \'unsigned char\' values) do not have elements of the same size","clang/test/SemaOpenCL/cond.cl:97:12: error: vector condition type \'int2\' (vector of 2 \'int\' values) and result type \'char2\' (vector of 2 \'char\' values) do not have elements of the same size"} | ||
Line 8,309: | Line 8,329: | ||
}, | }, | ||
["err_conditional_vector_has_void"]={ | ["err_conditional_vector_has_void"]={ | ||
[ | [e]="GNU vector conditional operand cannot be ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="GNU vector conditional operand cannot be %select{void|a throw expression}0", | ||
[ | [b]=n, | ||
[ | [j]="GNU vector conditional operand cannot be (?:void|a throw expression)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"349636d2bfc3",1575555459,ub,ub}, | ||
[k]={{y,6569,"/// Check the operands of ?: under C++ semantics.\n///\n/// See C++ [expr.cond]. Note that LHS is never null, even for the GNU x ?: y\n/// extension. In this case, LHS == Cond. (But they\'re not aliases.)\n///\n/// This function also implements GCC\'s vector extension and the\n/// OpenCL/ext_vector_type extension for conditionals. The vector extensions\n/// permit the use of a?b:c where the type of a is that of a integer vector with\n/// the same number of elements and size as the vectors of b and c. If one of\n/// either b or c is a scalar it is implicitly converted to match the type of\n/// the vector. Otherwise the expression is ill-formed. If both b and c are\n/// scalars, then b and c are checked and converted to the type of a if\n/// possible.\n///\n/// The expressions are evaluated differently for GCC\'s and OpenCL\'s extensions.\n/// For the GCC extension, the ?: operator is evaluated as\n/// (a[0] != 0 ? b[0] : c[0], .. , a[n] != 0 ? b[n] : c[n]).\n/// For the OpenCL extensions, the ?: operator is evaluated as\n/// (most-significant-bit-set(a[0]) ? b[0] : c[0], .. ,\n/// most-significant-bit-set(a[n]) ? b[n] : c[n]).\nQualType Sema::CXXCheckConditionalOperands(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, ExprObjectKind &OK, SourceLocation QuestionLoc) {\n if (LVoid || RVoid) {\n // Void expressions aren\'t legal in the vector-conditional expressions.\n if (IsVectorConditional) {\n Diag(DiagLoc.getBegin(), diag::err_conditional_vector_has_void) << DiagLoc << IsThrow;"}}, | [k]={{y,6569,"/// Check the operands of ?: under C++ semantics.\n///\n/// See C++ [expr.cond]. Note that LHS is never null, even for the GNU x ?: y\n/// extension. In this case, LHS == Cond. (But they\'re not aliases.)\n///\n/// This function also implements GCC\'s vector extension and the\n/// OpenCL/ext_vector_type extension for conditionals. The vector extensions\n/// permit the use of a?b:c where the type of a is that of a integer vector with\n/// the same number of elements and size as the vectors of b and c. If one of\n/// either b or c is a scalar it is implicitly converted to match the type of\n/// the vector. Otherwise the expression is ill-formed. If both b and c are\n/// scalars, then b and c are checked and converted to the type of a if\n/// possible.\n///\n/// The expressions are evaluated differently for GCC\'s and OpenCL\'s extensions.\n/// For the GCC extension, the ?: operator is evaluated as\n/// (a[0] != 0 ? b[0] : c[0], .. , a[n] != 0 ? b[n] : c[n]).\n/// For the OpenCL extensions, the ?: operator is evaluated as\n/// (most-significant-bit-set(a[0]) ? b[0] : c[0], .. ,\n/// most-significant-bit-set(a[n]) ? b[n] : c[n]).\nQualType Sema::CXXCheckConditionalOperands(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, ExprObjectKind &OK, SourceLocation QuestionLoc) {\n if (LVoid || RVoid) {\n // Void expressions aren\'t legal in the vector-conditional expressions.\n if (IsVectorConditional) {\n Diag(DiagLoc.getBegin(), diag::err_conditional_vector_has_void) << DiagLoc << IsThrow;"}}, | ||
[o]={ | [o]={ | ||
Line 8,324: | Line 8,344: | ||
}, | }, | ||
["err_conditional_vector_mismatched"]={ | ["err_conditional_vector_mismatched"]={ | ||
[ | [e]="vector operands to the vector conditional must be the same type (A and B)}", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="vector operands to the vector conditional must be the same type %diff{($ and $)|}0,1}", | ||
[ | [b]=n, | ||
[ | [j]="vector operands to the vector conditional must be the same type (?:\\((.*?) and (.*?)\\)|)\\}", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={sb,1590001902,T,T}, | ||
[k]={{y,6345,"QualType Sema::CheckVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSVT && RHSVT) {\n // If both are vector types, they must be the same type.\n if (!Context.hasSameType(LHSType, RHSType)) {\n Diag(QuestionLoc, diag::err_conditional_vector_mismatched) << LHSType << RHSType;"},{y,6432,"QualType Sema::CheckSizelessVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSBT && RHSBT) {\n // If both are sizeless vector types, they must be the same type.\n if (!Context.hasSameType(LHSType, RHSType)) {\n Diag(QuestionLoc, diag::err_conditional_vector_mismatched) << LHSType << RHSType;"}}, | [k]={{y,6345,"QualType Sema::CheckVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSVT && RHSVT) {\n // If both are vector types, they must be the same type.\n if (!Context.hasSameType(LHSType, RHSType)) {\n Diag(QuestionLoc, diag::err_conditional_vector_mismatched) << LHSType << RHSType;"},{y,6432,"QualType Sema::CheckSizelessVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSBT && RHSBT) {\n // If both are sizeless vector types, they must be the same type.\n if (!Context.hasSameType(LHSType, RHSType)) {\n Diag(QuestionLoc, diag::err_conditional_vector_mismatched) << LHSType << RHSType;"}}, | ||
[o]={ | [o]={ | ||
Line 8,339: | Line 8,359: | ||
}, | }, | ||
["err_conditional_vector_operand_type"]={ | ["err_conditional_vector_operand_type"]={ | ||
[ | [e]="enumeration type A is not allowed in a vector conditional", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="enumeration type %0 is not allowed in a vector conditional", | ||
[ | [b]=n, | ||
[ | [j]="enumeration type (.*?) is not allowed in a vector conditional", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"349636d2bfc3",1575555459,ub,ub}, | ||
[k]={{y,6369,"QualType Sema::CheckVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSVT && RHSVT) {\n } else if (LHSVT || RHSVT) {\n } else {\n if (ResultElementTy->isEnumeralType()) {\n Diag(QuestionLoc, diag::err_conditional_vector_operand_type) << ResultElementTy;"},{y,6455,"QualType Sema::CheckSizelessVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSBT && RHSBT) {\n } else if (LHSBT || RHSBT) {\n } else {\n if (ResultElementTy->isEnumeralType()) {\n Diag(QuestionLoc, diag::err_conditional_vector_operand_type) << ResultElementTy;"}}, | [k]={{y,6369,"QualType Sema::CheckVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSVT && RHSVT) {\n } else if (LHSVT || RHSVT) {\n } else {\n if (ResultElementTy->isEnumeralType()) {\n Diag(QuestionLoc, diag::err_conditional_vector_operand_type) << ResultElementTy;"},{y,6455,"QualType Sema::CheckSizelessVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (LHSBT && RHSBT) {\n } else if (LHSBT || RHSBT) {\n } else {\n if (ResultElementTy->isEnumeralType()) {\n Diag(QuestionLoc, diag::err_conditional_vector_operand_type) << ResultElementTy;"}}, | ||
[o]={ | [o]={ | ||
Line 8,354: | Line 8,374: | ||
}, | }, | ||
["err_conditional_vector_size"]={ | ["err_conditional_vector_size"]={ | ||
[ | [e]="vector condition type A and result type B do not have the same number of elements", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="vector condition type %0 and result type %1 do not have the same number of elements", | ||
[ | [b]=n, | ||
[ | [j]="vector condition type (.*?) and result type (.*?) do not have the same number of elements", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"e8d2aaf32021",1423031898,"OpenCL: handle ternary operator when the condition is a vector","OpenCL: handle ternary operator when the condition is a vector"}, | ||
[k]={{ | [k]={{A,8990,"/// Return false if the vector condition type and the vector\n/// result type are compatible.\n///\n/// OpenCL v1.1 s6.11.6 requires that both vector types have the same\n/// number of elements, and their element types have the same number\n/// of bits.\nstatic bool checkVectorResult(Sema &S, QualType CondTy, QualType VecResTy, SourceLocation QuestionLoc) {\n if (CV->getNumElements() != RV->getNumElements()) {\n S.Diag(QuestionLoc, diag::err_conditional_vector_size) << CondTy << VecResTy;"},{y,6392,"QualType Sema::CheckVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (ResultElementCount != CondElementCount) {\n Diag(QuestionLoc, diag::err_conditional_vector_size) << CondType << ResultType;"},{y,6475,"QualType Sema::CheckSizelessVectorConditionalTypes(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, SourceLocation QuestionLoc) {\n if (ResultElementCount != CondElementCount) {\n Diag(QuestionLoc, diag::err_conditional_vector_size) << CondType << ResultType;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaOpenCL/cond.cl"]={"clang/test/SemaOpenCL/cond.cl:123:12: error: vector condition type \'char2\' (vector of 2 \'char\' values) and result type \'char3\' (vector of 3 \'char\' values) do not have the same number of elements"} | ["clang/test/SemaOpenCL/cond.cl"]={"clang/test/SemaOpenCL/cond.cl:123:12: error: vector condition type \'char2\' (vector of 2 \'char\' values) and result type \'char3\' (vector of 3 \'char\' values) do not have the same number of elements"} | ||
Line 8,369: | Line 8,389: | ||
}, | }, | ||
["err_conditional_void_nonvoid"]={ | ["err_conditional_void_nonvoid"]={ | ||
[ | [e]="... operand to ? is void, but ... operand is of type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{left|right}1 operand to ? is void, but %select{right|left}1 operand is of type %0", | ||
[ | [b]=n, | ||
[ | [j]="(?:left|right) operand to \\? is void, but (?:right|left) operand is of type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"1a99f441e64c",1239904287,"Fix a crash bug when comparing overload quality of conversion operators with conversion constructors...","Fix a crash bug when comparing overload quality of conversion operators with conversion constructors."}, | ||
[k]={{y,6589,"/// Check the operands of ?: under C++ semantics.\n///\n/// See C++ [expr.cond]. Note that LHS is never null, even for the GNU x ?: y\n/// extension. In this case, LHS == Cond. (But they\'re not aliases.)\n///\n/// This function also implements GCC\'s vector extension and the\n/// OpenCL/ext_vector_type extension for conditionals. The vector extensions\n/// permit the use of a?b:c where the type of a is that of a integer vector with\n/// the same number of elements and size as the vectors of b and c. If one of\n/// either b or c is a scalar it is implicitly converted to match the type of\n/// the vector. Otherwise the expression is ill-formed. If both b and c are\n/// scalars, then b and c are checked and converted to the type of a if\n/// possible.\n///\n/// The expressions are evaluated differently for GCC\'s and OpenCL\'s extensions.\n/// For the GCC extension, the ?: operator is evaluated as\n/// (a[0] != 0 ? b[0] : c[0], .. , a[n] != 0 ? b[n] : c[n]).\n/// For the OpenCL extensions, the ?: operator is evaluated as\n/// (most-significant-bit-set(a[0]) ? b[0] : c[0], .. ,\n/// most-significant-bit-set(a[n]) ? b[n] : c[n]).\nQualType Sema::CXXCheckConditionalOperands(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, ExprObjectKind &OK, SourceLocation QuestionLoc) {\n if (LVoid || RVoid) {\n Diag(QuestionLoc, diag::err_conditional_void_nonvoid) << (LVoid ? RTy : LTy) << (LVoid ? 0 : 1) << LHS.get()->getSourceRange() << RHS.get()->getSourceRange();"}}, | [k]={{y,6589,"/// Check the operands of ?: under C++ semantics.\n///\n/// See C++ [expr.cond]. Note that LHS is never null, even for the GNU x ?: y\n/// extension. In this case, LHS == Cond. (But they\'re not aliases.)\n///\n/// This function also implements GCC\'s vector extension and the\n/// OpenCL/ext_vector_type extension for conditionals. The vector extensions\n/// permit the use of a?b:c where the type of a is that of a integer vector with\n/// the same number of elements and size as the vectors of b and c. If one of\n/// either b or c is a scalar it is implicitly converted to match the type of\n/// the vector. Otherwise the expression is ill-formed. If both b and c are\n/// scalars, then b and c are checked and converted to the type of a if\n/// possible.\n///\n/// The expressions are evaluated differently for GCC\'s and OpenCL\'s extensions.\n/// For the GCC extension, the ?: operator is evaluated as\n/// (a[0] != 0 ? b[0] : c[0], .. , a[n] != 0 ? b[n] : c[n]).\n/// For the OpenCL extensions, the ?: operator is evaluated as\n/// (most-significant-bit-set(a[0]) ? b[0] : c[0], .. ,\n/// most-significant-bit-set(a[n]) ? b[n] : c[n]).\nQualType Sema::CXXCheckConditionalOperands(ExprResult &Cond, ExprResult &LHS, ExprResult &RHS, ExprValueKind &VK, ExprObjectKind &OK, SourceLocation QuestionLoc) {\n if (LVoid || RVoid) {\n Diag(QuestionLoc, diag::err_conditional_void_nonvoid) << (LVoid ? RTy : LTy) << (LVoid ? 0 : 1) << LHS.get()->getSourceRange() << RHS.get()->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 8,384: | Line 8,404: | ||
}, | }, | ||
["err_config_scalar_return"]={ | ["err_config_scalar_return"]={ | ||
[ | [e]="CUDA special function \'A\' must have scalar return type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="CUDA special function \'%0\' must have scalar return type", | ||
[ | [b]=n, | ||
[ | [j]="CUDA special function \'(.*?)\' must have scalar return type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"9e2c81f00a0a",1297285472,"AST, Sema, Serialization: keep track of cudaConfigureCall","AST, Sema, Serialization: keep track of cudaConfigureCall"}, | ||
[k]={{ | [k]={{s,10667,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\n if (getLangOpts().CUDA) {\n if (II && II->isStr(getCudaConfigureFuncName()) && !NewFD->isInvalidDecl() && NewFD->getDeclContext()->getRedeclContext()->isTranslationUnit()) {\n if (!R->castAs<FunctionType>()->getReturnType()->isScalarType())\n Diag(NewFD->getLocation(), diag::err_config_scalar_return) << getCudaConfigureFuncName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCUDA/config-type.cu"]={"clang/test/SemaCUDA/config-type.cu:7:6: error: CUDA special function \'__cudaPushCallConfiguration\' must have scalar return type"} | ["clang/test/SemaCUDA/config-type.cu"]={"clang/test/SemaCUDA/config-type.cu:7:6: error: CUDA special function \'__cudaPushCallConfiguration\' must have scalar return type"} | ||
Line 8,399: | Line 8,419: | ||
}, | }, | ||
["err_conflict_marker"]={ | ["err_conflict_marker"]={ | ||
[e]="version control conflict marker in file", | |||
[d]=l, | |||
[f]=m, | |||
[h]="version control conflict marker in file", | [h]="version control conflict marker in file", | ||
[ | [b]=n, | ||
[ | [j]="version control conflict marker in file", | ||
[c]=a, | |||
[ | [i]=rb, | ||
[g]={"7c027ee4c272",1260771417,"teach clang to recover gracefully from conflict markers left in source","teach clang to recover gracefully from conflict markers left in source"}, | |||
[k]={{Tb,3162,"/// IsStartOfConflictMarker - If the specified pointer is the start of a version\n/// control conflict marker like \'<<<<<<<\', recognize it as such, emit an error\n/// and recover nicely. This returns true if it is a conflict marker and false\n/// if not.\nbool Lexer::IsStartOfConflictMarker(const char *CurPtr) {\n // Check to see if there is an ending marker somewhere in the buffer at the\n // start of a line to terminate this conflict marker.\n if (FindConflictEnd(CurPtr, BufferEnd, Kind)) {\n Diag(CurPtr, diag::err_conflict_marker);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Lexer/conflict-marker.c"]={"clang/test/Lexer/conflict-marker.c:7:1: error: version control conflict marker in file","clang/test/Lexer/conflict-marker.c:16:1: error: version control conflict marker in file","clang/test/Lexer/conflict-marker.c:23:1: error: version control conflict marker in file"} | ["clang/test/Lexer/conflict-marker.c"]={"clang/test/Lexer/conflict-marker.c:7:1: error: version control conflict marker in file","clang/test/Lexer/conflict-marker.c:16:1: error: version control conflict marker in file","clang/test/Lexer/conflict-marker.c:23:1: error: version control conflict marker in file"} | ||
Line 8,414: | Line 8,434: | ||
}, | }, | ||
["err_conflicting_aliasing_type"]={ | ["err_conflicting_aliasing_type"]={ | ||
[ | [e]="conflicting types for alias A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="conflicting types for alias %0", | ||
[ | [b]=n, | ||
[ | [j]="conflicting types for alias (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{O,1156,"/// ActOnCompatibilityAlias - this action is called after complete parsing of\n/// a \\@compatibility_alias declaration. It sets up the alias relationships.\nDecl *Sema::ActOnCompatibilityAlias(SourceLocation AtLoc, IdentifierInfo *AliasName, SourceLocation AliasLocation, IdentifierInfo *ClassName, SourceLocation ClassLocation) {\n if (ADecl) {\n Diag(AliasLocation, diag::err_conflicting_aliasing_type) << AliasName;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/alias-test-1.m"]={"clang/test/SemaObjC/alias-test-1.m:13:22: error: conflicting types for alias \'alias\'","clang/test/SemaObjC/alias-test-1.m:17:22: error: conflicting types for alias \'alias2\'"} | ["clang/test/SemaObjC/alias-test-1.m"]={"clang/test/SemaObjC/alias-test-1.m:13:22: error: conflicting types for alias \'alias\'","clang/test/SemaObjC/alias-test-1.m:17:22: error: conflicting types for alias \'alias2\'"} | ||
Line 8,429: | Line 8,449: | ||
}, | }, | ||
["err_conflicting_aligned_options"]={ | ["err_conflicting_aligned_options"]={ | ||
[e]="conflicting option \'-fcoro-aligned-allocation\' and \'-fno-aligned-allocation\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="conflicting option \'-fcoro-aligned-allocation\' and \'-fno-aligned-allocation\'", | [h]="conflicting option \'-fcoro-aligned-allocation\' and \'-fno-aligned-allocation\'", | ||
[ | [b]=n, | ||
[ | [j]="conflicting option \'\\-fcoro\\-aligned\\-allocation\' and \'\\-fno\\-aligned\\-allocation\'", | ||
[c]=a, | |||
[i]="Coroutines Issue", | |||
[g]={R,1625925174,B,B} | |||
[ | |||
[ | |||
[ | |||
}, | }, | ||
["err_conflicting_codeseg_attribute"]={ | ["err_conflicting_codeseg_attribute"]={ | ||
[e]="conflicting code segment specifiers", | |||
[d]=l, | |||
[f]=m, | |||
[h]="conflicting code segment specifiers", | [h]="conflicting code segment specifiers", | ||
[ | [b]=n, | ||
[ | [j]="conflicting code segment specifiers", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"64144eb194c8",1526479037,"Add support for __declspec(code_seg(\"segname\"))","Add support for __declspec(code_seg(\"segname\"))"}, | |||
[ | |||
[ | |||
[k]={{q,3401,"static void handleCodeSegAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (const auto *ExistingAttr = D->getAttr<CodeSegAttr>()) {\n if (!ExistingAttr->isImplicit()) {\n S.Diag(AL.getLoc(), ExistingAttr->getName() == Str ? diag::warn_duplicate_codeseg_attribute : diag::err_conflicting_codeseg_attribute);"}}, | [k]={{q,3401,"static void handleCodeSegAttr(Sema &S, Decl *D, const ParsedAttr &AL) {\n if (const auto *ExistingAttr = D->getAttr<CodeSegAttr>()) {\n if (!ExistingAttr->isImplicit()) {\n S.Diag(AL.getLoc(), ExistingAttr->getName() == Str ? diag::warn_duplicate_codeseg_attribute : diag::err_conflicting_codeseg_attribute);"}}, | ||
[o]={ | [o]={ | ||
Line 8,455: | Line 8,475: | ||
}, | }, | ||
["err_conflicting_ivar_bitwidth"]={ | ["err_conflicting_ivar_bitwidth"]={ | ||
[ | [e]="instance variable A has conflicting bit-field width", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="instance variable %0 has conflicting bit-field width", | ||
[ | [b]=n, | ||
[ | [j]="instance variable (.*?) has conflicting bit\\-field width", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{O,2215,"void Sema::CheckImplementationIvars(ObjCImplementationDecl *ImpDecl, ObjCIvarDecl **ivars, unsigned numIvars, SourceLocation RBrace) {\n for (; numIvars > 0 && IVI != IVE; ++IVI) {\n // First, make sure the types match.\n if (!Context.hasSameType(ImplIvar->getType(), ClsIvar->getType())) {\n } else if (ImplIvar->isBitField() && ClsIvar->isBitField() && ImplIvar->getBitWidthValue(Context) != ClsIvar->getBitWidthValue(Context)) {\n Diag(ImplIvar->getBitWidth()->getBeginLoc(), diag::err_conflicting_ivar_bitwidth) << ImplIvar->getIdentifier();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/class-bitfield.m"]={"clang/test/SemaObjC/class-bitfield.m:35:10: error: instance variable \'c\' has conflicting bit-field width"} | ["clang/test/SemaObjC/class-bitfield.m"]={"clang/test/SemaObjC/class-bitfield.m:35:10: error: instance variable \'c\' has conflicting bit-field width"} | ||
Line 8,470: | Line 8,490: | ||
}, | }, | ||
["err_conflicting_ivar_name"]={ | ["err_conflicting_ivar_name"]={ | ||
[ | [e]="conflicting instance variable names: A vs B", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="conflicting instance variable names: %0 vs %1", | ||
[ | [b]=n, | ||
[ | [j]="conflicting instance variable names\\: (.*?) vs (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{O,2222,"void Sema::CheckImplementationIvars(ObjCImplementationDecl *ImpDecl, ObjCIvarDecl **ivars, unsigned numIvars, SourceLocation RBrace) {\n for (; numIvars > 0 && IVI != IVE; ++IVI) {\n // Make sure the names are identical.\n if (ImplIvar->getIdentifier() != ClsIvar->getIdentifier()) {\n Diag(ImplIvar->getLocation(), diag::err_conflicting_ivar_name) << ImplIvar->getIdentifier() << ClsIvar->getIdentifier();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/conflicting-ivar-test-1.m"]={"clang/test/SemaObjC/conflicting-ivar-test-1.m:14:13: error: conflicting instance variable names: \'XIVAR\' vs \'IVAR\'"} | ["clang/test/SemaObjC/conflicting-ivar-test-1.m"]={"clang/test/SemaObjC/conflicting-ivar-test-1.m:14:13: error: conflicting instance variable names: \'XIVAR\' vs \'IVAR\'"} | ||
Line 8,485: | Line 8,505: | ||
}, | }, | ||
["err_conflicting_ivar_type"]={ | ["err_conflicting_ivar_type"]={ | ||
[ | [e]="instance variable A has conflicting type: B vs C", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="instance variable %0 has conflicting type%diff{: $ vs $|}1,2", | ||
[ | [b]=n, | ||
[ | [j]="instance variable (.*?) has conflicting type(?:\\: (.*?) vs (.*?)|)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{O,2207,"void Sema::CheckImplementationIvars(ObjCImplementationDecl *ImpDecl, ObjCIvarDecl **ivars, unsigned numIvars, SourceLocation RBrace) {\n for (; numIvars > 0 && IVI != IVE; ++IVI) {\n // First, make sure the types match.\n if (!Context.hasSameType(ImplIvar->getType(), ClsIvar->getType())) {\n Diag(ImplIvar->getLocation(), diag::err_conflicting_ivar_type) << ImplIvar->getIdentifier() << ImplIvar->getType() << ClsIvar->getType();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/class-bitfield.m"]={"clang/test/SemaObjC/class-bitfield.m:32:9: error: instance variable \'isa\' has conflicting type: \'char *\' vs \'void *\'"} | ["clang/test/SemaObjC/class-bitfield.m"]={"clang/test/SemaObjC/class-bitfield.m:32:9: error: instance variable \'isa\' has conflicting type: \'char *\' vs \'void *\'"} | ||
Line 8,500: | Line 8,520: | ||
}, | }, | ||
["err_conflicting_overriding_cc_attributes"]={ | ["err_conflicting_overriding_cc_attributes"]={ | ||
[ | [e]="virtual function A has different calling convention attributes (B) than the function it overrides (which has calling convention C)", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="virtual function %0 has different calling convention attributes %diff{($) than the function it overrides (which has calling convention $)|than the function it overrides}1,2", | ||
[ | [b]=n, | ||
[ | [j]="virtual function (.*?) has different calling convention attributes (?:\\((.*?)\\) than the function it overrides \\(which has calling convention (.*?)\\)|than the function it overrides)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"02df2e08720f",1355075141,"Virtual method overrides can no longer have mismatched calling conventions. This fixes PR14339.","Virtual method overrides can no longer have mismatched calling conventions. This fixes PR14339."}, | ||
[k]={{w,18013,"bool Sema::CheckOverridingFunctionAttributes(const CXXMethodDecl *New, const CXXMethodDecl *Old) {\n Diag(New->getLocation(), diag::err_conflicting_overriding_cc_attributes) << New->getDeclName() << New->getType() << Old->getType();"}}, | [k]={{w,18013,"bool Sema::CheckOverridingFunctionAttributes(const CXXMethodDecl *New, const CXXMethodDecl *Old) {\n Diag(New->getLocation(), diag::err_conflicting_overriding_cc_attributes) << New->getDeclName() << New->getType() << Old->getType();"}}, | ||
[o]={ | [o]={ | ||
Line 8,515: | Line 8,535: | ||
}, | }, | ||
["err_conflicting_super_class"]={ | ["err_conflicting_super_class"]={ | ||
[ | [e]="conflicting super class name A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="conflicting super class name %0", | ||
[ | [b]=n, | ||
[ | [j]="conflicting super class name (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{ | [k]={{O,2039,"ObjCImplementationDecl *Sema::ActOnStartClassImplementation(SourceLocation AtClassImplLoc, IdentifierInfo *ClassName, SourceLocation ClassLoc, IdentifierInfo *SuperClassname, SourceLocation SuperClassLoc, const ParsedAttributesView &Attrs) {\n if (SuperClassname) {\n if (PrevDecl && !isa<ObjCInterfaceDecl>(PrevDecl)) {\n } else {\n if (!SDecl)\n else if (IDecl && !declaresSameEntity(IDecl->getSuperClass(), SDecl)) {\n Diag(SuperClassLoc, diag::err_conflicting_super_class) << SDecl->getDeclName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaObjC/alias-test-2.m"]={"clang/test/SemaObjC/alias-test-2.m:12:27: error: conflicting super class name \'Super\'"} | ["clang/test/SemaObjC/alias-test-2.m"]={"clang/test/SemaObjC/alias-test-2.m:12:27: error: conflicting super class name \'Super\'"} | ||
Line 8,530: | Line 8,550: | ||
}, | }, | ||
["err_conflicting_types"]={ | ["err_conflicting_types"]={ | ||
[ | [e]="conflicting types for A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="conflicting types for %0", | ||
[ | [b]=n, | ||
[ | [j]="conflicting types for (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={v,1237025389,r,r}, | ||
[k]={{ | [k]={{s,4130,"/// 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 // C: Function types need to be compatible, not identical. This handles\n // duplicate function decls like \"void f(int); void f(enum X);\" properly.\n if (!getLangOpts().CPlusPlus) {\n // C99 6.7.5.3p15: ...If one type has a parameter type list and the other\n // type is specified by a function definition that contains a (possibly\n // empty) identifier list, both shall agree in the number of parameters\n // and the type of each parameter shall be compatible with the type that\n // results from the application of default argument promotions to the\n // type of the corresponding identifier. ...\n // This cannot be handled by ASTContext::typesAreCompatible() because that\n // doesn\'t know whether the function type is for a definition or not when\n // eventually calling ASTContext::mergeFunctionTypes(). The only situation\n // we need to cover here is that the number of arguments agree as the\n // default argument promotion rules were already checked by\n // ASTContext::typesAreCompatible().\n if (Old->hasPrototype() && !New->hasWrittenPrototype() && NewDeclIsDefn && Old->getNumParams() != New->getNumParams() && !Old->isImplicit()) {\n Diag(New->getLocation(), diag::err_conflicting_types) << New;"},{s,4305,"/// 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 Diag(New->getLocation(), diag::err_conflicting_types) << New->getDeclName();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/ms-overload-entry-point.cpp"]={"clang/test/SemaCXX/ms-overload-entry-point.cpp:14:6: error: conflicting types for \'wWinMain\'"} | ["clang/test/SemaCXX/ms-overload-entry-point.cpp"]={"clang/test/SemaCXX/ms-overload-entry-point.cpp:14:6: error: conflicting types for \'wWinMain\'"} | ||
Line 8,545: | Line 8,565: | ||
}, | }, | ||
["err_constant_integer_arg_type"]={ | ["err_constant_integer_arg_type"]={ | ||
[ | [e]="argument to A must be a constant integer", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="argument to %0 must be a constant integer", | ||
[ | [b]=n, | ||
[ | [j]="argument to (.*?) must be a constant integer", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"8d0c621ca600",1271471183,"Consolidate most of the integer constant expression builtin requirement","Consolidate most of the integer constant expression builtin requirement"}, | ||
[k]={{ | [k]={{u,8784,"/// SemaBuiltinConstantArg - Handle a check if argument ArgNum of CallExpr\n/// TheCall is a constant expression.\nbool Sema::SemaBuiltinConstantArg(CallExpr *TheCall, int ArgNum, llvm::APSInt &Result) {\n if (!(R = Arg->getIntegerConstantExpr(Context)))\n return Diag(TheCall->getBeginLoc(), diag::err_constant_integer_arg_type) << FDecl->getDeclName() << Arg->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Sema/builtin-stackaddress.c"]={"clang/test/Sema/builtin-stackaddress.c:8:8: error: argument to \'__builtin_return_address\' must be a constant integer","clang/test/Sema/builtin-stackaddress.c:27:8: error: argument to \'__builtin_frame_address\' must be a constant integer"} | ["clang/test/Sema/builtin-stackaddress.c"]={"clang/test/Sema/builtin-stackaddress.c:8:8: error: argument to \'__builtin_return_address\' must be a constant integer","clang/test/Sema/builtin-stackaddress.c:27:8: error: argument to \'__builtin_frame_address\' must be a constant integer"} | ||
Line 8,560: | Line 8,580: | ||
}, | }, | ||
["err_consteval_override"]={ | ["err_consteval_override"]={ | ||
[ | [e]="consteval function A cannot override a non-consteval function", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="consteval function %0 cannot override a non-consteval function", | ||
[ | [b]=n, | ||
[ | [j]="consteval function (.*?) cannot override a non\\-consteval function", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={ib,1576908663,K,K}, | ||
[k]={{w,7040,"/// Perform semantic checks on a class definition that has been\n/// completing, introducing implicitly-declared members, checking for\n/// abstract types, etc.\n///\n/// \\param S The scope in which the class was parsed. Null if we didn\'t just\n/// parse a class definition.\n/// \\param Record The completed class.\nvoid Sema::CheckCompletedCXXClass(Scope *S, CXXRecordDecl *Record) {\n // Perform checks that can\'t be done until we know all the properties of a\n // member function (whether it\'s defaulted, deleted, virtual, overriding,\n // ...).\n auto CheckCompletedMemberFunction = [&](CXXMethodDecl *MD) {\n if (ReportOverrides(*this, MD->isConsteval() ? diag::err_consteval_override : diag::err_non_consteval_override, MD, [&](const CXXMethodDecl *V) { return MD->isConsteval() != V->isConsteval(); })) {"}}, | [k]={{w,7040,"/// Perform semantic checks on a class definition that has been\n/// completing, introducing implicitly-declared members, checking for\n/// abstract types, etc.\n///\n/// \\param S The scope in which the class was parsed. Null if we didn\'t just\n/// parse a class definition.\n/// \\param Record The completed class.\nvoid Sema::CheckCompletedCXXClass(Scope *S, CXXRecordDecl *Record) {\n // Perform checks that can\'t be done until we know all the properties of a\n // member function (whether it\'s defaulted, deleted, virtual, overriding,\n // ...).\n auto CheckCompletedMemberFunction = [&](CXXMethodDecl *MD) {\n if (ReportOverrides(*this, MD->isConsteval() ? diag::err_consteval_override : diag::err_non_consteval_override, MD, [&](const CXXMethodDecl *V) { return MD->isConsteval() != V->isConsteval(); })) {"}}, | ||
[o]={ | [o]={ | ||
Line 8,575: | Line 8,595: | ||
}, | }, | ||
["err_constexpr_body_invalid_stmt"]={ | ["err_constexpr_body_invalid_stmt"]={ | ||
[ | [e]="statement not allowed in ... ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="statement not allowed in %select{constexpr|consteval}1 %select{function|constructor}0", | ||
[ | [b]=n, | ||
[ | [j]="statement not allowed in (?:constexpr|consteval) (?:function|constructor)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={vb,1317436288,U,U}, | ||
[k]={{w,1990,"/// Check the given declaration statement is legal within a constexpr function\n/// body. C++11 [dcl.constexpr]p3,p4, and C++1y [dcl.constexpr]p3.\n///\n/// \\return true if the body is OK (maybe only as an extension), false if we\n/// have diagnosed a problem.\nstatic bool CheckConstexprDeclStmt(Sema &SemaRef, const FunctionDecl *Dcl, DeclStmt *DS, SourceLocation &Cxx1yLoc, Sema::CheckConstexprKind Kind) {\n // C++11 [dcl.constexpr]p3 and p4:\n // The definition of a constexpr function(p3) or constructor(p4) [...] shall\n // contain only\n for (const auto *DclIt : DS->decls()) {\n default:\n if (Kind == Sema::CheckConstexprKind::Diagnose) {\n SemaRef.Diag(DS->getBeginLoc(), diag::err_constexpr_body_invalid_stmt) << isa<CXXConstructorDecl>(Dcl) << Dcl->isConsteval();"},{w,2220,"/// Check the provided statement is allowed in a constexpr function\n/// definition.\nstatic bool CheckConstexprFunctionStmt(Sema &SemaRef, const FunctionDecl *Dcl, Stmt *S, SmallVectorImpl<SourceLocation> &ReturnStmts, SourceLocation &Cxx1yLoc, SourceLocation &Cxx2aLoc, SourceLocation &Cxx2bLoc, Sema::CheckConstexprKind Kind) {\n if (Kind == Sema::CheckConstexprKind::Diagnose) {\n SemaRef.Diag(S->getBeginLoc(), diag::err_constexpr_body_invalid_stmt) << isa<CXXConstructorDecl>(Dcl) << Dcl->isConsteval();"}}, | [k]={{w,1990,"/// Check the given declaration statement is legal within a constexpr function\n/// body. C++11 [dcl.constexpr]p3,p4, and C++1y [dcl.constexpr]p3.\n///\n/// \\return true if the body is OK (maybe only as an extension), false if we\n/// have diagnosed a problem.\nstatic bool CheckConstexprDeclStmt(Sema &SemaRef, const FunctionDecl *Dcl, DeclStmt *DS, SourceLocation &Cxx1yLoc, Sema::CheckConstexprKind Kind) {\n // C++11 [dcl.constexpr]p3 and p4:\n // The definition of a constexpr function(p3) or constructor(p4) [...] shall\n // contain only\n for (const auto *DclIt : DS->decls()) {\n default:\n if (Kind == Sema::CheckConstexprKind::Diagnose) {\n SemaRef.Diag(DS->getBeginLoc(), diag::err_constexpr_body_invalid_stmt) << isa<CXXConstructorDecl>(Dcl) << Dcl->isConsteval();"},{w,2220,"/// Check the provided statement is allowed in a constexpr function\n/// definition.\nstatic bool CheckConstexprFunctionStmt(Sema &SemaRef, const FunctionDecl *Dcl, Stmt *S, SmallVectorImpl<SourceLocation> &ReturnStmts, SourceLocation &Cxx1yLoc, SourceLocation &Cxx2aLoc, SourceLocation &Cxx2bLoc, Sema::CheckConstexprKind Kind) {\n if (Kind == Sema::CheckConstexprKind::Diagnose) {\n SemaRef.Diag(S->getBeginLoc(), diag::err_constexpr_body_invalid_stmt) << isa<CXXConstructorDecl>(Dcl) << Dcl->isConsteval();"}}, | ||
[o]={ | [o]={ | ||
Line 8,590: | Line 8,610: | ||
}, | }, | ||
["err_constexpr_body_no_return"]={ | ["err_constexpr_body_no_return"]={ | ||
[ | [e]="no return statement in ... function", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="no return statement in %select{constexpr|consteval}0 function", | ||
[ | [b]=n, | ||
[ | [j]="no return statement in (?:constexpr|consteval) function", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={vb,1317436288,U,U}, | ||
[k]={{w,2379,"/// Check the body for the given constexpr function declaration only contains\n/// the permitted types of statement. C++11 [dcl.constexpr]p3,p4.\n///\n/// \\return true if the body is OK, false if we have found or diagnosed a\n/// problem.\nstatic bool CheckConstexprFunctionBody(Sema &SemaRef, const FunctionDecl *Dcl, Stmt *Body, Sema::CheckConstexprKind Kind) {\n if (const CXXConstructorDecl *Constructor = dyn_cast<CXXConstructorDecl>(Dcl)) {\n } else {\n if (ReturnStmts.empty()) {\n case Sema::CheckConstexprKind::Diagnose:\n SemaRef.Diag(Dcl->getLocation(), OK ? diag::warn_cxx11_compat_constexpr_body_no_return : diag::err_constexpr_body_no_return) << Dcl->isConsteval();"}}, | [k]={{w,2379,"/// Check the body for the given constexpr function declaration only contains\n/// the permitted types of statement. C++11 [dcl.constexpr]p3,p4.\n///\n/// \\return true if the body is OK, false if we have found or diagnosed a\n/// problem.\nstatic bool CheckConstexprFunctionBody(Sema &SemaRef, const FunctionDecl *Dcl, Stmt *Body, Sema::CheckConstexprKind Kind) {\n if (const CXXConstructorDecl *Constructor = dyn_cast<CXXConstructorDecl>(Dcl)) {\n } else {\n if (ReturnStmts.empty()) {\n case Sema::CheckConstexprKind::Diagnose:\n SemaRef.Diag(Dcl->getLocation(), OK ? diag::warn_cxx11_compat_constexpr_body_no_return : diag::err_constexpr_body_no_return) << Dcl->isConsteval();"}}, | ||
[o]={ | [o]={ | ||
Line 8,605: | Line 8,625: | ||
}, | }, | ||
["err_constexpr_dtor"]={ | ["err_constexpr_dtor"]={ | ||
[ | [e]="destructor cannot be declared ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="destructor cannot be declared %select{<ERROR>|constexpr|consteval|constinit}0", | ||
[ | [b]=n, | ||
[ | [j]="destructor cannot be declared (?:constexpr|consteval|constinit)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"a77a0a6bf221",1313442247,"Track in the AST whether a function is constexpr.","Track in the AST whether a function is constexpr."}, | ||
[k]={{ | [k]={{s,9963,"NamedDecl *Sema::ActOnFunctionDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamListsRef, bool &AddToScope) {\n if (getLangOpts().CPlusPlus) {\n if (ConstexprKind != ConstexprSpecKind::Unspecified) {\n // C++11 [dcl.constexpr]p3: functions declared constexpr are required to\n // be either constructors or to return a literal type. Therefore,\n // destructors cannot be declared constexpr.\n if (isa<CXXDestructorDecl>(NewFD) && (!getLangOpts().CPlusPlus20 || ConstexprKind == ConstexprSpecKind::Consteval)) {\n Diag(D.getDeclSpec().getConstexprSpecLoc(), diag::err_constexpr_dtor) << static_cast<int>(ConstexprKind);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl.decl/dcl.fct.def/dcl.fct.def.default/p2.cpp"]={"clang/test/CXX/dcl.decl/dcl.fct.def/dcl.fct.def.default/p2.cpp:11:3: error: destructor cannot be declared constexpr"} | ["clang/test/CXX/dcl.decl/dcl.fct.def/dcl.fct.def.default/p2.cpp"]={"clang/test/CXX/dcl.decl/dcl.fct.def/dcl.fct.def.default/p2.cpp:11:3: error: destructor cannot be declared constexpr"} | ||
Line 8,620: | Line 8,640: | ||
}, | }, | ||
["err_constexpr_dtor_subobject"]={ | ["err_constexpr_dtor_subobject"]={ | ||
[ | [e]="destructor cannot be declared ... because ... does not have a constexpr destructor", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="destructor cannot be declared %select{<ERROR>|constexpr|consteval|constinit}0 because %select{data member %2|base class %3}1 does not have a constexpr destructor", | ||
[ | [b]=n, | ||
[ | [j]="destructor cannot be declared (?:constexpr|consteval|constinit) because (?:data member (.*?)|base class (.*?)) does not have a constexpr destructor", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"7c11da0cfd33",1567434909,tb,tb}, | ||
[k]={{w,1697,"/// Determine whether a destructor cannot be constexpr due to\nstatic bool CheckConstexprDestructorSubobjects(Sema &SemaRef, const CXXDestructorDecl *DD, Sema::CheckConstexprKind Kind) {\n auto Check = [&](SourceLocation Loc, QualType T, const FieldDecl *FD) {\n if (Kind == Sema::CheckConstexprKind::Diagnose) {\n SemaRef.Diag(DD->getLocation(), diag::err_constexpr_dtor_subobject) << static_cast<int>(DD->getConstexprKind()) << !FD << (FD ? FD->getDeclName() : DeclarationName()) << T;"}}, | [k]={{w,1697,"/// Determine whether a destructor cannot be constexpr due to\nstatic bool CheckConstexprDestructorSubobjects(Sema &SemaRef, const CXXDestructorDecl *DD, Sema::CheckConstexprKind Kind) {\n auto Check = [&](SourceLocation Loc, QualType T, const FieldDecl *FD) {\n if (Kind == Sema::CheckConstexprKind::Diagnose) {\n SemaRef.Diag(DD->getLocation(), diag::err_constexpr_dtor_subobject) << static_cast<int>(DD->getConstexprKind()) << !FD << (FD ? FD->getDeclName() : DeclarationName()) << T;"}}, | ||
[o]={ | [o]={ | ||
Line 8,635: | Line 8,655: | ||
}, | }, | ||
["err_constexpr_if_condition_expression_is_not_constant"]={ | ["err_constexpr_if_condition_expression_is_not_constant"]={ | ||
[e]="constexpr if condition is not a constant expression", | |||
[d]=l, | |||
[f]=m, | |||
[h]="constexpr if condition is not a constant expression", | [h]="constexpr if condition is not a constant expression", | ||
[ | [b]=n, | ||
[ | [j]="constexpr if condition is not a constant expression", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={hc,1615397021,lb,lb}, | |||
[ | |||
[ | |||
[k]={{y,4058,"/// CheckCXXBooleanCondition - Returns true if a conversion to bool is invalid.\nExprResult Sema::CheckCXXBooleanCondition(Expr *CondExpr, bool IsConstexpr) {\n E = VerifyIntegerConstantExpression(E.get(), &Cond, diag::err_constexpr_if_condition_expression_is_not_constant);"}}, | [k]={{y,4058,"/// CheckCXXBooleanCondition - Returns true if a conversion to bool is invalid.\nExprResult Sema::CheckCXXBooleanCondition(Expr *CondExpr, bool IsConstexpr) {\n E = VerifyIntegerConstantExpression(E.get(), &Cond, diag::err_constexpr_if_condition_expression_is_not_constant);"}}, | ||
[o]={ | [o]={ | ||
Line 8,650: | Line 8,670: | ||
}, | }, | ||
["err_constexpr_invalid_template_arg"]={ | ["err_constexpr_invalid_template_arg"]={ | ||
[ | [e]="... to ...... is not allowed in a template argument", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{pointer|reference}0 to %select{|subobject of }1%select{type_info object|string literal|temporary object|predefined \'%3\' variable}2 is not allowed in a template argument", | ||
[ | [b]=n, | ||
[ | [j]="(?:pointer|reference) to (?:|subobject of )(?:type_info object|string literal|temporary object|predefined \'(.*?)\' variable) is not allowed in a template argument", | ||
[ | [c]=a, | ||
[ | [i]=a, | ||
[ | [g]={"7b3515880c22",1603602504,"For P0732R2, P1907R1: ensure that template parameter objects don\'t refer","For P0732R2, P1907R1: ensure that template parameter objects don\'t refer"}, | ||
[k]={{ | [k]={{ab,5990,"/// EvaluateConvertedConstantExpression - Evaluate an Expression\n/// That is a converted constant expression\n/// (which was built with BuildConvertedConstantExpression)\nstatic ExprResult EvaluateConvertedConstantExpression(Sema &S, Expr *E, QualType T, APValue &Value, Sema::CCEKind CCE, bool RequireInt, const APValue &PreNarrowingValue) {\n // It\'s not a constant expression. Produce an appropriate diagnostic.\n if (Notes.size() == 1 && Notes[0].second.getDiagID() == diag::note_invalid_subexpr_in_const_expr) {\n } else if (!Notes.empty() && Notes[0].second.getDiagID() == diag::note_constexpr_invalid_template_arg) {\n Notes[0].second.setDiagID(diag::err_constexpr_invalid_template_arg);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp"]={"clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:233:5: error: reference to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:234:5: error: reference to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:239:5: error: reference to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:240:5: error: reference to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:244:5: error: reference to subobject of temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:247:5: error: pointer to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:248:5: error: pointer to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:249:5: error: pointer to subobject of temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:253:5: error: pointer to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:258:5: error: pointer to string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:259:5: error: reference to string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:260:5: error: pointer to subobject of string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:261:5: error: reference to subobject of string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:265:5: error: pointer to subobject of string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:266:5: error: reference to subobject of string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:271:5: error: pointer to type_info object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:272:5: error: reference to type_info object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:276:5: error: pointer to type_info object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:277:5: error: reference to type_info object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:287:7: error: pointer to subobject of predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:288:7: error: pointer to subobject of predefined \'__PRETTY_FUNCTION__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:289:7: error: reference to predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:290:7: error: pointer to predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:291:7: error: reference to predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:292:7: error: pointer to subobject of predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:293:7: error: reference to subobject of predefined \'__func__\' variable is not allowed in a template argument"} | ["clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp"]={"clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:233:5: error: reference to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:234:5: error: reference to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:239:5: error: reference to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:240:5: error: reference to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:244:5: error: reference to subobject of temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:247:5: error: pointer to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:248:5: error: pointer to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:249:5: error: pointer to subobject of temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:253:5: error: pointer to temporary object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:258:5: error: pointer to string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:259:5: error: reference to string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:260:5: error: pointer to subobject of string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:261:5: error: reference to subobject of string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:265:5: error: pointer to subobject of string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:266:5: error: reference to subobject of string literal is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:271:5: error: pointer to type_info object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:272:5: error: reference to type_info object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:276:5: error: pointer to type_info object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:277:5: error: reference to type_info object is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:287:7: error: pointer to subobject of predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:288:7: error: pointer to subobject of predefined \'__PRETTY_FUNCTION__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:289:7: error: reference to predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:290:7: error: pointer to predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:291:7: error: reference to predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:292:7: error: pointer to subobject of predefined \'__func__\' variable is not allowed in a template argument","clang/test/SemaTemplate/temp_arg_nontype_cxx20.cpp:293:7: error: reference to subobject of predefined \'__func__\' variable is not allowed in a template argument"} | ||
Line 8,665: | Line 8,685: | ||
}, | }, | ||
["err_constexpr_local_var_non_literal_type"]={ | ["err_constexpr_local_var_non_literal_type"]={ | ||
[ | [e]="variable of non-literal type A cannot be defined in a constexpr ... before C++23", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="variable of non-literal type %1 cannot be defined in a constexpr %select{function|constructor}0 before C++23", | ||
[ | [b]=n, | ||
[ | [j]="variable of non\\-literal type (.*?) cannot be defined in a constexpr (?:function|constructor) before C\\+\\+23", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"d9f663b510c4",1366644711,"C++1y constexpr extensions, round 1: Allow most forms of declaration and","C++1y constexpr extensions, round 1: Allow most forms of declaration and"}, | ||
[k]={{w,1949,"/// Check the given declaration statement is legal within a constexpr function\n/// body. C++11 [dcl.constexpr]p3,p4, and C++1y [dcl.constexpr]p3.\n///\n/// \\return true if the body is OK (maybe only as an extension), false if we\n/// have diagnosed a problem.\nstatic bool CheckConstexprDeclStmt(Sema &SemaRef, const FunctionDecl *Dcl, DeclStmt *DS, SourceLocation &Cxx1yLoc, Sema::CheckConstexprKind Kind) {\n // C++11 [dcl.constexpr]p3 and p4:\n // The definition of a constexpr function(p3) or constructor(p4) [...] shall\n // contain only\n for (const auto *DclIt : DS->decls()) {\n case Decl::Decomposition: {\n if (VD->isThisDeclarationADefinition()) {\n } else if (CheckLiteralType(SemaRef, Kind, VD->getLocation(), VD->getType(), diag::err_constexpr_local_var_non_literal_type, isa<CXXConstructorDecl>(Dcl))) {"}}, | [k]={{w,1949,"/// Check the given declaration statement is legal within a constexpr function\n/// body. C++11 [dcl.constexpr]p3,p4, and C++1y [dcl.constexpr]p3.\n///\n/// \\return true if the body is OK (maybe only as an extension), false if we\n/// have diagnosed a problem.\nstatic bool CheckConstexprDeclStmt(Sema &SemaRef, const FunctionDecl *Dcl, DeclStmt *DS, SourceLocation &Cxx1yLoc, Sema::CheckConstexprKind Kind) {\n // C++11 [dcl.constexpr]p3 and p4:\n // The definition of a constexpr function(p3) or constructor(p4) [...] shall\n // contain only\n for (const auto *DclIt : DS->decls()) {\n case Decl::Decomposition: {\n if (VD->isThisDeclarationADefinition()) {\n } else if (CheckLiteralType(SemaRef, Kind, VD->getLocation(), VD->getType(), diag::err_constexpr_local_var_non_literal_type, isa<CXXConstructorDecl>(Dcl))) {"}}, | ||
[o]={ | [o]={ | ||
Line 8,680: | Line 8,700: | ||
}, | }, | ||
["err_constexpr_main"]={ | ["err_constexpr_main"]={ | ||
[ | [e]="\'main\' is not allowed to be declared ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="\'main\' is not allowed to be declared %select{constexpr|consteval}0", | ||
[ | [b]=n, | ||
[ | [j]="\'main\' is not allowed to be declared (?:constexpr|consteval)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3f333f2edf49",1328335817,"Disallow constexpr main.","Disallow constexpr main."}, | ||
[k]={{ | [k]={{s,12090,"void Sema::CheckMain(FunctionDecl *FD, const DeclSpec &DS) {\n if (FD->isConstexpr()) {\n Diag(DS.getConstexprSpecLoc(), diag::err_constexpr_main) << FD->isConsteval() << FixItHint::CreateRemoval(DS.getConstexprSpecLoc());"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/cxx2a-consteval.cpp"]={"clang/test/SemaCXX/cxx2a-consteval.cpp:66:1: error: \'main\' is not allowed to be declared consteval"} | ["clang/test/SemaCXX/cxx2a-consteval.cpp"]={"clang/test/SemaCXX/cxx2a-consteval.cpp:66:1: error: \'main\' is not allowed to be declared consteval"} | ||
Line 8,695: | Line 8,715: | ||
}, | }, | ||
["err_constexpr_non_literal_param"]={ | ["err_constexpr_non_literal_param"]={ | ||
[ | [e]="... ...\'s A parameter type B is not a literal type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{constexpr|consteval}2 %select{function|constructor}1\'s %ordinal0 parameter type %3 is not a literal type", | ||
[ | [b]=n, | ||
[ | [j]="(?:constexpr|consteval) (?:function|constructor)\'s (.*?) parameter type (.*?) is not a literal type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={vb,1317436288,U,U}, | ||
[k]={{w,1730,"/// Check whether a function\'s parameter types are all literal types. If so,\n/// return true. If not, produce a suitable diagnostic and return false.\nstatic bool CheckConstexprParameterTypes(Sema &SemaRef, const FunctionDecl *FD, Sema::CheckConstexprKind Kind) {\n for (FunctionProtoType::param_type_iterator i = FT->param_type_begin(), e = FT->param_type_end(); i != e; ++i, ++ArgIndex) {\n if (CheckLiteralType(SemaRef, Kind, ParamLoc, *i, diag::err_constexpr_non_literal_param, ArgIndex + 1, PD->getSourceRange(), isa<CXXConstructorDecl>(FD), FD->isConsteval()))"}}, | [k]={{w,1730,"/// Check whether a function\'s parameter types are all literal types. If so,\n/// return true. If not, produce a suitable diagnostic and return false.\nstatic bool CheckConstexprParameterTypes(Sema &SemaRef, const FunctionDecl *FD, Sema::CheckConstexprKind Kind) {\n for (FunctionProtoType::param_type_iterator i = FT->param_type_begin(), e = FT->param_type_end(); i != e; ++i, ++ArgIndex) {\n if (CheckLiteralType(SemaRef, Kind, ParamLoc, *i, diag::err_constexpr_non_literal_param, ArgIndex + 1, PD->getSourceRange(), isa<CXXConstructorDecl>(FD), FD->isConsteval()))"}}, | ||
[o]={ | [o]={ | ||
Line 8,710: | Line 8,730: | ||
}, | }, | ||
["err_constexpr_non_literal_return"]={ | ["err_constexpr_non_literal_return"]={ | ||
[ | [e]="... function\'s return type A is not a literal type", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{constexpr|consteval}0 function\'s return type %1 is not a literal type", | ||
[ | [b]=n, | ||
[ | [j]="(?:constexpr|consteval) function\'s return type (.*?) is not a literal type", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={vb,1317436288,U,U}, | ||
[k]={{w,1743,"/// Check whether a function\'s return type is a literal type. If so, return\n/// true. If not, produce a suitable diagnostic and return false.\nstatic bool CheckConstexprReturnType(Sema &SemaRef, const FunctionDecl *FD, Sema::CheckConstexprKind Kind) {\n if (CheckLiteralType(SemaRef, Kind, FD->getLocation(), FD->getReturnType(), diag::err_constexpr_non_literal_return, FD->isConsteval()))"}}, | [k]={{w,1743,"/// Check whether a function\'s return type is a literal type. If so, return\n/// true. If not, produce a suitable diagnostic and return false.\nstatic bool CheckConstexprReturnType(Sema &SemaRef, const FunctionDecl *FD, Sema::CheckConstexprKind Kind) {\n if (CheckLiteralType(SemaRef, Kind, FD->getLocation(), FD->getReturnType(), diag::err_constexpr_non_literal_return, FD->isConsteval()))"}}, | ||
[o]={ | [o]={ | ||
Line 8,725: | Line 8,745: | ||
}, | }, | ||
["err_constexpr_redecl_mismatch"]={ | ["err_constexpr_redecl_mismatch"]={ | ||
[ | [e]="... declaration of A follows ... declaration", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{non-constexpr|constexpr|consteval}1 declaration of %0 follows %select{non-constexpr|constexpr|consteval}2 declaration", | ||
[ | [b]=n, | ||
[ | [j]="(?:non\\-constexpr|constexpr|consteval) declaration of (.*?) follows (?:non\\-constexpr|constexpr|consteval) declaration", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={vb,1317436288,U,U}, | ||
[k]={{w,672,"/// MergeCXXFunctionDecl - Merge two declarations of the same C++\n/// function, once we already know that they have the same\n/// type. Subroutine of MergeFunctionDecl. Returns true if there was an\n/// error, false otherwise.\nbool Sema::MergeCXXFunctionDecl(FunctionDecl *New, FunctionDecl *Old, Scope *S) {\n // C++11 [dcl.constexpr]p1: If any declaration of a function or function\n // template has a constexpr specifier then all its declarations shall\n // contain the constexpr specifier.\n if (New->getConstexprKind() != Old->getConstexprKind()) {\n Diag(New->getLocation(), diag::err_constexpr_redecl_mismatch) << New << static_cast<int>(New->getConstexprKind()) << static_cast<int>(Old->getConstexprKind());"}}, | [k]={{w,672,"/// MergeCXXFunctionDecl - Merge two declarations of the same C++\n/// function, once we already know that they have the same\n/// type. Subroutine of MergeFunctionDecl. Returns true if there was an\n/// error, false otherwise.\nbool Sema::MergeCXXFunctionDecl(FunctionDecl *New, FunctionDecl *Old, Scope *S) {\n // C++11 [dcl.constexpr]p1: If any declaration of a function or function\n // template has a constexpr specifier then all its declarations shall\n // contain the constexpr specifier.\n if (New->getConstexprKind() != Old->getConstexprKind()) {\n Diag(New->getLocation(), diag::err_constexpr_redecl_mismatch) << New << static_cast<int>(New->getConstexprKind()) << static_cast<int>(Old->getConstexprKind());"}}, | ||
[o]={ | [o]={ | ||
Line 8,740: | Line 8,760: | ||
}, | }, | ||
["err_constexpr_return_missing_expr"]={ | ["err_constexpr_return_missing_expr"]={ | ||
[ | [e]="non-void ... function A should return a value", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="non-void %select{constexpr|consteval}1 function %0 should return a value", | ||
[ | [b]=n, | ||
[ | [j]="non\\-void (?:constexpr|consteval) function (.*?) should return a value", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"2887ad35c58d",1418458376,"Sema: Constexpr functions must have return statements which have an expr","Sema: Constexpr functions must have return statements which have an expr"}, | ||
[k]={{ | [k]={{bb,4134,"StmtResult Sema::BuildReturnStmt(SourceLocation ReturnLoc, Expr *RetValExp, bool AllowRecovery) {\n if (FnRetType->isVoidType()) {\n } else if (!RetValExp && !HasDependentReturnType) {\n if ((FD && FD->isInvalidDecl()) || FnRetType->containsErrors()) {\n } else if (getLangOpts().CPlusPlus11 && FD && FD->isConstexpr()) {\n Diag(ReturnLoc, diag::err_constexpr_return_missing_expr) << FD << FD->isConsteval();"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/consteval-return-void.cpp"]={"clang/test/SemaCXX/consteval-return-void.cpp:3:23: error: non-void consteval function \'Fun\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:5:47: error: non-void consteval function \'FunT1\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:8:42: error: non-void consteval function \'FunT2<int>\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:12:30: error: non-void constexpr function \'operator+\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:13:30: error: non-void consteval function \'operator-\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:14:52: error: non-void constexpr function \'operator+\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:15:52: error: non-void consteval function \'operator-\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:19:47: error: non-void constexpr function \'operator*<int>\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:20:47: error: non-void consteval function \'operator/<int>\' should return a value"} | ["clang/test/SemaCXX/consteval-return-void.cpp"]={"clang/test/SemaCXX/consteval-return-void.cpp:3:23: error: non-void consteval function \'Fun\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:5:47: error: non-void consteval function \'FunT1\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:8:42: error: non-void consteval function \'FunT2<int>\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:12:30: error: non-void constexpr function \'operator+\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:13:30: error: non-void consteval function \'operator-\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:14:52: error: non-void constexpr function \'operator+\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:15:52: error: non-void consteval function \'operator-\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:19:47: error: non-void constexpr function \'operator*<int>\' should return a value","clang/test/SemaCXX/consteval-return-void.cpp:20:47: error: non-void consteval function \'operator/<int>\' should return a value"} | ||
Line 8,755: | Line 8,775: | ||
}, | }, | ||
["err_constexpr_static_mem_var_requires_init"]={ | ["err_constexpr_static_mem_var_requires_init"]={ | ||
[ | [e]="declaration of constexpr static data member A requires an initializer", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="declaration of constexpr static data member %0 requires an initializer", | ||
[ | [b]=n, | ||
[ | [j]="declaration of constexpr static data member (.*?) requires an initializer", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"eda3c8469827",1320704177,"constexpr: static data members declared constexpr are required to have an","constexpr: static data members declared constexpr are required to have an"}, | ||
[k]={{ | [k]={{s,13686,"void Sema::ActOnUninitializedDecl(Decl *RealDecl) {\n if (VarDecl *Var = dyn_cast<VarDecl>(RealDecl)) {\n // C++11 [class.static.data]p3: A static data member can be declared with\n // the constexpr specifier; if so, its declaration shall specify\n // a brace-or-equal-initializer.\n // C++11 [dcl.constexpr]p1: The constexpr specifier shall be applied only to\n // the definition of a variable [...] or the declaration of a static data\n // member.\n if (Var->isConstexpr() && !Var->isThisDeclarationADefinition() && !Var->isThisDeclarationADemotedDefinition()) {\n if (Var->isStaticDataMember()) {\n // C++1z removes the relevant rule; the in-class declaration is always\n // a definition there.\n if (!getLangOpts().CPlusPlus17 && !Context.getTargetInfo().getCXXABI().isMicrosoft()) {\n Diag(Var->getLocation(), diag::err_constexpr_static_mem_var_requires_init) << Var;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/class/class.static/class.static.data/p3.cpp"]={"clang/test/CXX/class/class.static/class.static.data/p3.cpp:10:24: error: declaration of constexpr static data member \'b\' requires an initializer","clang/test/CXX/class/class.static/class.static.data/p3.cpp:40:24: error: declaration of constexpr static data member \'b\' requires an initializer"} | ["clang/test/CXX/class/class.static/class.static.data/p3.cpp"]={"clang/test/CXX/class/class.static/class.static.data/p3.cpp:10:24: error: declaration of constexpr static data member \'b\' requires an initializer","clang/test/CXX/class/class.static/class.static.data/p3.cpp:40:24: error: declaration of constexpr static data member \'b\' requires an initializer"} | ||
Line 8,770: | Line 8,790: | ||
}, | }, | ||
["err_constexpr_tag"]={ | ["err_constexpr_tag"]={ | ||
[ | [e]="... cannot be marked ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{class|struct|interface|union|enum|enum class|enum struct}0 cannot be marked %select{<ERROR>|constexpr|consteval|constinit}1", | ||
[ | [b]=n, | ||
[ | [j]="(?:class|struct|interface|union|enum|enum class|enum struct) cannot be marked (?:constexpr|consteval|constinit)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"a77a0a6bf221",1313442247,"Track in the AST whether a function is constexpr.","Track in the AST whether a function is constexpr."}, | ||
[k]={{ | [k]={{s,5123,"/// ParsedFreeStandingDeclSpec - This method is invoked when a declspec with\n/// no declarator (e.g. \"struct foo;\") is parsed. It also accepts template\n/// parameters to cope with template friend declarations.\nDecl *Sema::ParsedFreeStandingDeclSpec(Scope *S, AccessSpecifier AS, DeclSpec &DS, const ParsedAttributesView &DeclAttrs, MultiTemplateParamsArg TemplateParams, bool IsExplicitInstantiation, RecordDecl *&AnonRecord) {\n if (DS.hasConstexprSpecifier()) {\n // C++0x [dcl.constexpr]p1: constexpr can only be applied to declarations\n // and definitions of functions and variables.\n // C++2a [dcl.constexpr]p1: The consteval specifier shall be applied only to\n // the declaration of a function or function template\n if (Tag)\n Diag(DS.getConstexprSpecLoc(), diag::err_constexpr_tag) << GetDiagnosticTypeSpecifierID(DS) << static_cast<int>(DS.getConstexprSpecifier());"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/cxx2a-consteval.cpp"]={"clang/test/SemaCXX/cxx2a-consteval.cpp:37:1: error: struct cannot be marked consteval"} | ["clang/test/SemaCXX/cxx2a-consteval.cpp"]={"clang/test/SemaCXX/cxx2a-consteval.cpp:37:1: error: struct cannot be marked consteval"} | ||
Line 8,785: | Line 8,805: | ||
}, | }, | ||
["err_constexpr_var_non_literal"]={ | ["err_constexpr_var_non_literal"]={ | ||
[ | [e]="constexpr variable cannot have non-literal type A", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="constexpr variable cannot have non-literal type %0", | ||
[ | [b]=n, | ||
[ | [j]="constexpr variable cannot have non\\-literal type (.*?)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"3607ffee5cca",1329105243,"Update constexpr implementation to match CWG\'s chosen approach for core issues","Update constexpr implementation to match CWG\'s chosen approach for core issues"}, | ||
[k]={{ | [k]={{s,8762,"void Sema::CheckVariableDeclarationType(VarDecl *NewVD) {\n if (NewVD->isConstexpr() && !T->isDependentType() && RequireLiteralType(NewVD->getLocation(), T, diag::err_constexpr_var_non_literal)) {"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/special/class.ctor/p6-0x.cpp"]={"clang/test/CXX/special/class.ctor/p6-0x.cpp:25:25: error: constexpr variable cannot have non-literal type \'const NonConstexpr3\'"} | ["clang/test/CXX/special/class.ctor/p6-0x.cpp"]={"clang/test/CXX/special/class.ctor/p6-0x.cpp:25:25: error: constexpr variable cannot have non-literal type \'const NonConstexpr3\'"} | ||
Line 8,800: | Line 8,820: | ||
}, | }, | ||
["err_constexpr_var_requires_const_destruction"]={ | ["err_constexpr_var_requires_const_destruction"]={ | ||
[ | [e]="constexpr variable A must have constant destruction", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="constexpr variable %0 must have constant destruction", | ||
[ | [b]=n, | ||
[ | [j]="constexpr variable (.*?) must have constant destruction", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"7c11da0cfd33",1567434909,tb,tb}, | ||
[k]={{w,15886,"void Sema::FinalizeVarWithDestructor(VarDecl *VD, const RecordType *Record) {\n // If the destructor is constexpr, check whether the variable has constant\n // destruction now.\n if (Destructor->isConstexpr()) {\n if (!VD->evaluateDestruction(Notes) && VD->isConstexpr() && HasConstantInit) {\n Diag(VD->getLocation(), diag::err_constexpr_var_requires_const_destruction) << VD;"}}, | [k]={{w,15886,"void Sema::FinalizeVarWithDestructor(VarDecl *VD, const RecordType *Record) {\n // If the destructor is constexpr, check whether the variable has constant\n // destruction now.\n if (Destructor->isConstexpr()) {\n if (!VD->evaluateDestruction(Notes) && VD->isConstexpr() && HasConstantInit) {\n Diag(VD->getLocation(), diag::err_constexpr_var_requires_const_destruction) << VD;"}}, | ||
[o]={ | [o]={ | ||
Line 8,815: | Line 8,835: | ||
}, | }, | ||
["err_constexpr_var_requires_const_init"]={ | ["err_constexpr_var_requires_const_init"]={ | ||
[ | [e]="constexpr variable A must be initialized by a constant expression", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="constexpr variable %0 must be initialized by a constant expression", | ||
[ | [b]=n, | ||
[ | [j]="constexpr variable (.*?) must be initialized by a constant expression", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"2316cd8b798b",1317323497,"constexpr: semantic checking for constexpr variables.","constexpr: semantic checking for constexpr variables."}, | ||
[k]={{ | [k]={{s,13830,"void Sema::ActOnUninitializedDecl(Decl *RealDecl) {\n if (VarDecl *Var = dyn_cast<VarDecl>(RealDecl)) {\n // Provide a specific diagnostic for uninitialized variable\n // definitions with incomplete array type.\n if (Type->isIncompleteArrayType()) {\n if (Var->isConstexpr())\n Diag(Var->getLocation(), diag::err_constexpr_var_requires_const_init) << Var;"},{s,14221,"void Sema::CheckCompleteVariableDeclaration(VarDecl *var) {\n // Check whether the initializer is sufficiently constant.\n if (getLangOpts().CPlusPlus && !type->isDependentType() && Init && !Init->isValueDependent() && (GlobalStorage || var->isConstexpr() || var->mightBeUsableInConstantExpressions(Context))) {\n if (HasConstInit) {\n } else if (var->isConstexpr()) {\n Diag(DiagLoc, diag::err_constexpr_var_requires_const_init) << var << Init->getSourceRange();"},{L,8530,"ExprResult InitializationSequence::Perform(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, MultiExprArg Args, QualType *ResultType) {\n if (!ZeroInitializationFixit.empty()) {\n // The initialization would have succeeded with this fixit. Since the fixit\n // is on the error, we need to build a valid AST in this case, so this isn\'t\n // handled in the Failed() branch above.\n if (!DestType->isRecordType() && VD && VD->isConstexpr()) {\n S.Diag(Kind.getLocation(), diag::err_constexpr_var_requires_const_init) << VD << FixItHint::CreateInsertion(ZeroInitializationFixitLoc, ZeroInitializationFixit);"},{L,9966,"bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, ArrayRef<Expr *> Args) {\n case FK_DefaultInitOfConst:\n if (Entity.getKind() == InitializedEntity::EK_Member && isa<CXXConstructorDecl>(S.CurContext)) {\n } else if (const auto *VD = dyn_cast_if_present<VarDecl>(Entity.getDecl()); VD && VD->isConstexpr()) {\n S.Diag(Kind.getLocation(), diag::err_constexpr_var_requires_const_init) << VD;"}}, | ||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/attr-weak.cpp"]={"clang/test/SemaCXX/attr-weak.cpp:47:16: error: constexpr variable \'weak_function_is_non_null\' must be initialized by a constant expression","clang/test/SemaCXX/attr-weak.cpp:49:16: error: constexpr variable \'weak_method_is_non_null\' must be initialized by a constant expression","clang/test/SemaCXX/attr-weak.cpp:56:16: error: constexpr variable \'virtual_weak_method_is_non_null\' must be initialized by a constant expression"} | ["clang/test/SemaCXX/attr-weak.cpp"]={"clang/test/SemaCXX/attr-weak.cpp:47:16: error: constexpr variable \'weak_function_is_non_null\' must be initialized by a constant expression","clang/test/SemaCXX/attr-weak.cpp:49:16: error: constexpr variable \'weak_method_is_non_null\' must be initialized by a constant expression","clang/test/SemaCXX/attr-weak.cpp:56:16: error: constexpr variable \'virtual_weak_method_is_non_null\' must be initialized by a constant expression"} | ||
Line 8,830: | Line 8,850: | ||
}, | }, | ||
["err_constexpr_virtual"]={ | ["err_constexpr_virtual"]={ | ||
[e]="virtual function cannot be constexpr", | |||
[d]=l, | |||
[f]=m, | |||
[h]="virtual function cannot be constexpr", | [h]="virtual function cannot be constexpr", | ||
[ | [b]=n, | ||
[ | [j]="virtual function cannot be constexpr", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={vb,1317436288,U,U}, | |||
[ | |||
[ | |||
[k]={{w,1814,"// Check whether a function declaration satisfies the requirements of a\n// constexpr function definition or a constexpr constructor definition. If so,\n// return true. If not, produce appropriate diagnostics (unless asked not to by\n// Kind) and return false.\n//\n// This implements C++11 [dcl.constexpr]p3,4, as amended by DR1360.\nbool Sema::CheckConstexprFunctionDefinition(const FunctionDecl *NewFD, CheckConstexprKind Kind) {\n if (!isa<CXXConstructorDecl>(NewFD)) {\n if (Method && Method->isVirtual()) {\n if (getLangOpts().CPlusPlus20) {\n } else {\n Diag(Method->getLocation(), diag::err_constexpr_virtual);"}}, | [k]={{w,1814,"// Check whether a function declaration satisfies the requirements of a\n// constexpr function definition or a constexpr constructor definition. If so,\n// return true. If not, produce appropriate diagnostics (unless asked not to by\n// Kind) and return false.\n//\n// This implements C++11 [dcl.constexpr]p3,4, as amended by DR1360.\nbool Sema::CheckConstexprFunctionDefinition(const FunctionDecl *NewFD, CheckConstexprKind Kind) {\n if (!isa<CXXConstructorDecl>(NewFD)) {\n if (Method && Method->isVirtual()) {\n if (getLangOpts().CPlusPlus20) {\n } else {\n Diag(Method->getLocation(), diag::err_constexpr_virtual);"}}, | ||
[o]={ | [o]={ | ||
Line 8,845: | Line 8,865: | ||
}, | }, | ||
["err_constexpr_virtual_base"]={ | ["err_constexpr_virtual_base"]={ | ||
[ | [e]="constexpr ... not allowed in ... with virtual base class", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="constexpr %select{member function|constructor}0 not allowed in %select{struct|interface|class}1 with virtual base %plural{1:class|:classes}2", | ||
[ | [b]=n, | ||
[ | [j]="constexpr (?:member function|constructor) not allowed in (?:struct|interface|class) with virtual base (?:class|classes)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={vb,1317436288,U,U}, | ||
[k]={{w,1789,"// Check whether a function declaration satisfies the requirements of a\n// constexpr function definition or a constexpr constructor definition. If so,\n// return true. If not, produce appropriate diagnostics (unless asked not to by\n// Kind) and return false.\n//\n// This implements C++11 [dcl.constexpr]p3,4, as amended by DR1360.\nbool Sema::CheckConstexprFunctionDefinition(const FunctionDecl *NewFD, CheckConstexprKind Kind) {\n if (MD && MD->isInstance()) {\n if (RD->getNumVBases()) {\n Diag(NewFD->getLocation(), diag::err_constexpr_virtual_base) << isa<CXXConstructorDecl>(NewFD) << getRecordDiagFromTagKind(RD->getTagKind()) << RD->getNumVBases();"}}, | [k]={{w,1789,"// Check whether a function declaration satisfies the requirements of a\n// constexpr function definition or a constexpr constructor definition. If so,\n// return true. If not, produce appropriate diagnostics (unless asked not to by\n// Kind) and return false.\n//\n// This implements C++11 [dcl.constexpr]p3,4, as amended by DR1360.\nbool Sema::CheckConstexprFunctionDefinition(const FunctionDecl *NewFD, CheckConstexprKind Kind) {\n if (MD && MD->isInstance()) {\n if (RD->getNumVBases()) {\n Diag(NewFD->getLocation(), diag::err_constexpr_virtual_base) << isa<CXXConstructorDecl>(NewFD) << getRecordDiagFromTagKind(RD->getTagKind()) << RD->getNumVBases();"}}, | ||
[o]={ | [o]={ | ||
Line 8,860: | Line 8,880: | ||
}, | }, | ||
["err_constexpr_vla"]={ | ["err_constexpr_vla"]={ | ||
[ | [e]="variably-modified type A cannot be used in a constexpr ...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="variably-modified type %0 cannot be used in a constexpr %select{function|constructor}1", | ||
[ | [b]=n, | ||
[ | [j]="variably\\-modified type (.*?) cannot be used in a constexpr (?:function|constructor)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={vb,1317436288,U,U}, | ||
[k]={{w,1890,"/// Check the given declaration statement is legal within a constexpr function\n/// body. C++11 [dcl.constexpr]p3,p4, and C++1y [dcl.constexpr]p3.\n///\n/// \\return true if the body is OK (maybe only as an extension), false if we\n/// have diagnosed a problem.\nstatic bool CheckConstexprDeclStmt(Sema &SemaRef, const FunctionDecl *Dcl, DeclStmt *DS, SourceLocation &Cxx1yLoc, Sema::CheckConstexprKind Kind) {\n // C++11 [dcl.constexpr]p3 and p4:\n // The definition of a constexpr function(p3) or constructor(p4) [...] shall\n // contain only\n for (const auto *DclIt : DS->decls()) {\n case Decl::TypeAlias: {\n if (TN->getUnderlyingType()->isVariablyModifiedType()) {\n // Don\'t allow variably-modified types in constexpr functions.\n if (Kind == Sema::CheckConstexprKind::Diagnose) {\n SemaRef.Diag(TL.getBeginLoc(), diag::err_constexpr_vla) << TL.getSourceRange() << TL.getType() << isa<CXXConstructorDecl>(Dcl);"}} | [k]={{w,1890,"/// Check the given declaration statement is legal within a constexpr function\n/// body. C++11 [dcl.constexpr]p3,p4, and C++1y [dcl.constexpr]p3.\n///\n/// \\return true if the body is OK (maybe only as an extension), false if we\n/// have diagnosed a problem.\nstatic bool CheckConstexprDeclStmt(Sema &SemaRef, const FunctionDecl *Dcl, DeclStmt *DS, SourceLocation &Cxx1yLoc, Sema::CheckConstexprKind Kind) {\n // C++11 [dcl.constexpr]p3 and p4:\n // The definition of a constexpr function(p3) or constructor(p4) [...] shall\n // contain only\n for (const auto *DclIt : DS->decls()) {\n case Decl::TypeAlias: {\n if (TN->getUnderlyingType()->isVariablyModifiedType()) {\n // Don\'t allow variably-modified types in constexpr functions.\n if (Kind == Sema::CheckConstexprKind::Diagnose) {\n SemaRef.Diag(TL.getBeginLoc(), diag::err_constexpr_vla) << TL.getSourceRange() << TL.getType() << isa<CXXConstructorDecl>(Dcl);"}} | ||
}, | }, | ||
["err_constexpr_wrong_decl_kind"]={ | ["err_constexpr_wrong_decl_kind"]={ | ||
[ | [e]="... can only be used in ... declarations", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="%select{<ERROR>|constexpr|consteval|constinit}0 can only be used in %select{|variable and function|function|variable}0 declarations", | ||
[ | [b]=n, | ||
[ | [j]="(?:constexpr|consteval|constinit) can only be used in (?:|variable and function|function|variable) declarations", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"796ed03b8412",1560502580,"[C++20] add Basic consteval specifier","[C++20] add Basic consteval specifier"}, | ||
[k]={{ | [k]={{s,5127,"/// ParsedFreeStandingDeclSpec - This method is invoked when a declspec with\n/// no declarator (e.g. \"struct foo;\") is parsed. It also accepts template\n/// parameters to cope with template friend declarations.\nDecl *Sema::ParsedFreeStandingDeclSpec(Scope *S, AccessSpecifier AS, DeclSpec &DS, const ParsedAttributesView &DeclAttrs, MultiTemplateParamsArg TemplateParams, bool IsExplicitInstantiation, RecordDecl *&AnonRecord) {\n if (DS.hasConstexprSpecifier()) {\n // C++0x [dcl.constexpr]p1: constexpr can only be applied to declarations\n // and definitions of functions and variables.\n // C++2a [dcl.constexpr]p1: The consteval specifier shall be applied only to\n // the declaration of a function or function template\n if (Tag)\n else\n Diag(DS.getConstexprSpecLoc(), diag::err_constexpr_wrong_decl_kind) << static_cast<int>(DS.getConstexprSpecifier());"},{s,7790,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n case ConstexprSpecKind::Consteval:\n Diag(D.getDeclSpec().getConstexprSpecLoc(), diag::err_constexpr_wrong_decl_kind) << static_cast<int>(D.getDeclSpec().getConstexprSpecifier());"},{s,9181,"static FunctionDecl *CreateNewFunctionDecl(Sema &SemaRef, Declarator &D, DeclContext *DC, QualType &R, TypeSourceInfo *TInfo, StorageClass SC, bool &IsVirtualOkay) {\n if (ConstexprKind == ConstexprSpecKind::Constinit) {\n SemaRef.Diag(D.getDeclSpec().getConstexprSpecLoc(), diag::err_constexpr_wrong_decl_kind) << static_cast<int>(ConstexprKind);"}}, | ||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:44:1: error: constinit can only be used in variable declarations","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:48:1: error: constinit can only be used in variable declarations","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:50:1: error: constinit can only be used in variable declarations"} | ["clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:44:1: error: constinit can only be used in variable declarations","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:48:1: error: constinit can only be used in variable declarations","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:50:1: error: constinit can only be used in variable declarations"} | ||
Line 8,887: | Line 8,907: | ||
}, | }, | ||
["err_constinit_added_too_late"]={ | ["err_constinit_added_too_late"]={ | ||
[e]="\'constinit\' specifier added after initialization of variable", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'constinit\' specifier added after initialization of variable", | [h]="\'constinit\' specifier added after initialization of variable", | ||
[ | [b]=n, | ||
[ | [j]="\'constinit\' specifier added after initialization of variable", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"7c11da0cfd33",1567434909,tb,tb}, | |||
[k]={{s,3172,"static void diagnoseMissingConstinit(Sema &S, const VarDecl *InitDecl, const ConstInitAttr *CIAttr, bool AttrBeforeInit) {\n if (AttrBeforeInit) {\n } else {\n S.Diag(CIAttr->getLocation(), CIAttr->isConstinit() ? diag::err_constinit_added_too_late : diag::warn_require_const_init_added_too_late) << FixItHint::CreateRemoval(SourceRange(CIAttr->getLocation()));"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:15:10: error: \'constinit\' specifier added after initialization of variable","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:40:1: error: \'constinit\' specifier added after initialization of variable","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:41:1: error: \'constinit\' specifier added after initialization of variable","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:42:1: error: \'constinit\' specifier added after initialization of variable"} | ["clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:15:10: error: \'constinit\' specifier added after initialization of variable","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:40:1: error: \'constinit\' specifier added after initialization of variable","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:41:1: error: \'constinit\' specifier added after initialization of variable","clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:42:1: error: \'constinit\' specifier added after initialization of variable"} | ||
Line 8,902: | Line 8,922: | ||
}, | }, | ||
["err_constinit_local_variable"]={ | ["err_constinit_local_variable"]={ | ||
[e]="local variable cannot be declared \'constinit\'", | |||
[d]=l, | |||
[f]=m, | |||
[h]="local variable cannot be declared \'constinit\'", | [h]="local variable cannot be declared \'constinit\'", | ||
[ | [b]=n, | ||
[ | [j]="local variable cannot be declared \'constinit\'", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"7c11da0cfd33",1567434909,tb,tb}, | |||
[k]={{s,7808,"NamedDecl *Sema::ActOnVariableDeclarator(Scope *S, Declarator &D, DeclContext *DC, TypeSourceInfo *TInfo, LookupResult &Previous, MultiTemplateParamsArg TemplateParamLists, bool &AddToScope, ArrayRef<BindingDecl *> Bindings) {\n case ConstexprSpecKind::Constinit:\n if (!NewVD->hasGlobalStorage())\n Diag(D.getDeclSpec().getConstexprSpecLoc(), diag::err_constinit_local_variable);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:10:3: error: local variable cannot be declared \'constinit\'"} | ["clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp"]={"clang/test/CXX/dcl.dcl/dcl.spec/dcl.constinit/p1.cpp:10:3: error: local variable cannot be declared \'constinit\'"} | ||
Line 8,917: | Line 8,937: | ||
}, | }, | ||
["err_constrained_non_templated_function"]={ | ["err_constrained_non_templated_function"]={ | ||
[e]="non-templated function cannot have a requires clause", | |||
[d]=l, | |||
[f]=m, | |||
[h]="non-templated function cannot have a requires clause", | [h]="non-templated function cannot have a requires clause", | ||
[ | [b]=n, | ||
[ | [j]="non\\-templated function cannot have a requires clause", | ||
[c]=a, | |||
[i]=p, | |||
[g]={"cb08f4aa4467",1620530452,Yb,Yb}, | |||
[ | [k]={{s,11984,"/// 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 if (getLangOpts().CPlusPlus) {\n // C++20: dcl.decl.general p4:\n // The optional requires-clause ([temp.pre]) in an init-declarator or\n // member-declarator shall be present only if the declarator declares a\n // templated function ([dcl.fct]).\n if (Expr *TRC = NewFD->getTrailingRequiresClause()) {\n if (!NewFD->getDescribedFunctionTemplate() && // -a template\n Diag(TRC->getBeginLoc(), diag::err_constrained_non_templated_function);"},{Fb,1415,"void Sema::ActOnStartOfLambdaDefinition(LambdaIntroducer &Intro, Declarator &ParamInfo, const DeclSpec &DS) {\n // C++20: dcl.decl.general p4:\n // The optional requires-clause ([temp.pre]) in an init-declarator or\n // member-declarator shall be present only if the declarator declares a\n // templated function ([dcl.fct]).\n if (Expr *TRC = Method->getTrailingRequiresClause()) {\n // Note: we only have to check if this is defined in a template entity, OR\n // if we are a template, since the rest don\'t apply. The requires clause\n // applies to the call operator, which we already know is a member function,\n // AND defined.\n if (!Method->getDescribedFunctionTemplate() && !Method->isTemplated()) {\n Diag(TRC->getBeginLoc(), diag::err_constrained_non_templated_function);"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/CXX/dcl/dcl.decl/p3.cpp"]={"clang/test/CXX/dcl/dcl.decl/p3.cpp:11:34: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:12:42: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:13:53: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:15:35: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:16:31: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:18:30: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:20:23: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:23:17: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:23:35: error: non-templated function cannot have a requires clause"} | ["clang/test/CXX/dcl/dcl.decl/p3.cpp"]={"clang/test/CXX/dcl/dcl.decl/p3.cpp:11:34: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:12:42: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:13:53: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:15:35: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:16:31: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:18:30: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:20:23: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:23:17: error: non-templated function cannot have a requires clause","clang/test/CXX/dcl/dcl.decl/p3.cpp:23:35: error: non-templated function cannot have a requires clause"} | ||
Line 8,932: | Line 8,952: | ||
}, | }, | ||
["err_constrained_virtual_method"]={ | ["err_constrained_virtual_method"]={ | ||
[e]="virtual function cannot have a requires clause", | |||
[d]=l, | |||
[f]=m, | |||
[h]="virtual function cannot have a requires clause", | [h]="virtual function cannot have a requires clause", | ||
[ | [b]=n, | ||
[ | [j]="virtual function cannot have a requires clause", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"349636d2bfc3",1575555459,ub,ub}, | |||
[k]={{s,11948,"/// 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 if (getLangOpts().CPlusPlus) {\n // Find any virtual functions that this function overrides.\n if (CXXMethodDecl *Method = dyn_cast<CXXMethodDecl>(NewFD)) {\n if (Method->isVirtual() && NewFD->getTrailingRequiresClause())\n Diag(NewFD->getTrailingRequiresClause()->getBeginLoc(), diag::err_constrained_virtual_method);"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/CXX/class.derived/class.virtual/p6.cpp"]={"clang/test/CXX/class.derived/class.virtual/p6.cpp:5:30: error: virtual function cannot have a requires clause","clang/test/CXX/class.derived/class.virtual/p6.cpp:7:30: error: virtual function cannot have a requires clause","clang/test/CXX/class.derived/class.virtual/p6.cpp:13:30: error: virtual function cannot have a requires clause","clang/test/CXX/class.derived/class.virtual/p6.cpp:17:54: error: virtual function cannot have a requires clause"} | ["clang/test/CXX/class.derived/class.virtual/p6.cpp"]={"clang/test/CXX/class.derived/class.virtual/p6.cpp:5:30: error: virtual function cannot have a requires clause","clang/test/CXX/class.derived/class.virtual/p6.cpp:7:30: error: virtual function cannot have a requires clause","clang/test/CXX/class.derived/class.virtual/p6.cpp:13:30: error: virtual function cannot have a requires clause","clang/test/CXX/class.derived/class.virtual/p6.cpp:17:54: error: virtual function cannot have a requires clause"} | ||
Line 8,947: | Line 8,967: | ||
}, | }, | ||
["err_constraint_depends_on_self"]={ | ["err_constraint_depends_on_self"]={ | ||
[ | [e]="satisfaction of constraint \'A\' depends on itself", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="satisfaction of constraint \'%0\' depends on itself", | ||
[ | [b]=n, | ||
[ | [j]="satisfaction of constraint \'(.*?)\' depends on itself", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={R,1625925174,B,B}, | ||
[k]={{"clang/lib/Sema/SemaConcept.cpp",309,"static bool DiagRecursiveConstraintEval(Sema &S, llvm::FoldingSetNodeID &ID, const NamedDecl *Templ, const Expr *E, const MultiLevelTemplateArgumentList &MLTAL) {\n // Note that we have to do this with our own collection, because there are\n // times where a constraint-expression check can cause us to need to evaluate\n // other constriants that are unrelated, such as when evaluating a recovery\n // expression, or when trying to determine the constexpr-ness of special\n // members. Otherwise we could just use the\n // Sema::InstantiatingTemplate::isAlreadyBeingInstantiated function.\n if (S.SatisfactionStackContains(Templ, ID)) {\n S.Diag(E->getExprLoc(), diag::err_constraint_depends_on_self) << const_cast<Expr *>(E) << E->getSourceRange();"}}, | [k]={{"clang/lib/Sema/SemaConcept.cpp",309,"static bool DiagRecursiveConstraintEval(Sema &S, llvm::FoldingSetNodeID &ID, const NamedDecl *Templ, const Expr *E, const MultiLevelTemplateArgumentList &MLTAL) {\n // Note that we have to do this with our own collection, because there are\n // times where a constraint-expression check can cause us to need to evaluate\n // other constriants that are unrelated, such as when evaluating a recovery\n // expression, or when trying to determine the constexpr-ness of special\n // members. Otherwise we could just use the\n // Sema::InstantiatingTemplate::isAlreadyBeingInstantiated function.\n if (S.SatisfactionStackContains(Templ, ID)) {\n S.Diag(E->getExprLoc(), diag::err_constraint_depends_on_self) << const_cast<Expr *>(E) << E->getSourceRange();"}}, | ||
[o]={ | [o]={ | ||
Line 8,962: | Line 8,982: | ||
}, | }, | ||
["err_constructor_bad_name"]={ | ["err_constructor_bad_name"]={ | ||
[ | [e]="missing return type for function A; did you mean the constructor name B?", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="missing return type for function %0; did you mean the constructor name %1?", | ||
[ | [b]=n, | ||
[ | [j]="missing return type for function (.*?); did you mean the constructor name (.*?)\\?", | ||
[ | [c]=a, | ||
[ | [i]=D, | ||
[ | [g]={"fb8b7b9a1c52",1381795226,"PR17567: Improve diagnostic for a mistyped constructor name. If we see something","PR17567: Improve diagnostic for a mistyped constructor name. If we see something"}, | ||
[k]={{ | [k]={{H,2877,"/// ParseImplicitInt - This method is called when we have an non-typename\n/// identifier in a declspec (which normally terminates the decl spec) when\n/// the declspec has no type specifier. In this case, the declspec is either\n/// malformed or is \"implicit int\" (in K&R and C89).\n///\n/// This method handles diagnosing this prettily and returns false if the\n/// declspec is done being processed. If it recovers and thinks there may be\n/// other pieces of declspec after it, it returns true.\n///\nbool Parser::ParseImplicitInt(DeclSpec &DS, CXXScopeSpec *SS, const ParsedTemplateInfo &TemplateInfo, AccessSpecifier AS, DeclSpecContext DSC, ParsedAttributes &Attrs) {\n // Determine whether this identifier could plausibly be the name of something\n // being declared (with a missing type).\n if (!isTypeSpecifier(DSC) && (!SS || DSC == DeclSpecContext::DSC_top_level || DSC == DeclSpecContext::DSC_class)) {\n case tok::l_paren: {\n // If we\'re in a context where we could be declaring a constructor,\n // check whether this is a constructor declaration with a bogus name.\n if (DSC == DeclSpecContext::DSC_class || (DSC == DeclSpecContext::DSC_top_level && SS)) {\n if (Actions.isCurrentClassNameTypo(II, SS)) {\n Diag(Loc, diag::err_constructor_bad_name) << Tok.getIdentifierInfo() << II << FixItHint::CreateReplacement(Tok.getLocation(), II->getName());"}}, | ||
[o]={ | [o]={ | ||
["clang/test/Parser/cxx-decl.cpp"]={"clang/test/Parser/cxx-decl.cpp:247:5: error: missing return type for function \'FooBar\'; did you mean the constructor name \'Foobar\'?","clang/test/Parser/cxx-decl.cpp:250:11: error: missing return type for function \'FooBar\'; did you mean the constructor name \'Foobar\'?"} | ["clang/test/Parser/cxx-decl.cpp"]={"clang/test/Parser/cxx-decl.cpp:247:5: error: missing return type for function \'FooBar\'; did you mean the constructor name \'Foobar\'?","clang/test/Parser/cxx-decl.cpp:250:11: error: missing return type for function \'FooBar\'; did you mean the constructor name \'Foobar\'?"} | ||
Line 8,977: | Line 8,997: | ||
}, | }, | ||
["err_constructor_byvalue_arg"]={ | ["err_constructor_byvalue_arg"]={ | ||
[e]="copy constructor must pass its first argument by reference", | |||
[d]=l, | |||
[f]=m, | |||
[h]="copy constructor must pass its first argument by reference", | [h]="copy constructor must pass its first argument by reference", | ||
[ | [b]=n, | ||
[ | [j]="copy constructor must pass its first argument by reference", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={E,1236199783,F,C}, | |||
[ | |||
[ | |||
[k]={{w,10792,"/// CheckConstructor - Checks a fully-formed constructor for\n/// well-formedness, issuing any diagnostics required. Returns true if\n/// the constructor declarator is invalid.\nvoid Sema::CheckConstructor(CXXConstructorDecl *Constructor) {\n // C++ [class.copy]p3:\n // A declaration of a constructor for a class X is ill-formed if\n // its first parameter is of type (optionally cv-qualified) X and\n // either there are no other parameters or else all other\n // parameters have default arguments.\n if (!Constructor->isInvalidDecl() && Constructor->hasOneParamOrDefaultArgs() && Constructor->getTemplateSpecializationKind() != TSK_ImplicitInstantiation) {\n if (Context.getCanonicalType(ParamType).getUnqualifiedType() == ClassTy) {\n Diag(ParamLoc, diag::err_constructor_byvalue_arg) << FixItHint::CreateInsertion(ParamLoc, ConstRef);"}}, | [k]={{w,10792,"/// CheckConstructor - Checks a fully-formed constructor for\n/// well-formedness, issuing any diagnostics required. Returns true if\n/// the constructor declarator is invalid.\nvoid Sema::CheckConstructor(CXXConstructorDecl *Constructor) {\n // C++ [class.copy]p3:\n // A declaration of a constructor for a class X is ill-formed if\n // its first parameter is of type (optionally cv-qualified) X and\n // either there are no other parameters or else all other\n // parameters have default arguments.\n if (!Constructor->isInvalidDecl() && Constructor->hasOneParamOrDefaultArgs() && Constructor->getTemplateSpecializationKind() != TSK_ImplicitInstantiation) {\n if (Context.getCanonicalType(ParamType).getUnqualifiedType() == ClassTy) {\n Diag(ParamLoc, diag::err_constructor_byvalue_arg) << FixItHint::CreateInsertion(ParamLoc, ConstRef);"}}, | ||
[o]={ | [o]={ | ||
Line 8,992: | Line 9,012: | ||
}, | }, | ||
["err_constructor_cannot_be"]={ | ["err_constructor_cannot_be"]={ | ||
[ | [e]="constructor cannot be declared \'A\'", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="constructor cannot be declared \'%0\'", | ||
[ | [b]=n, | ||
[ | [j]="constructor cannot be declared \'(.*?)\'", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={E,1236199783,F,C}, | ||
[k]={{w,10718,"/// CheckConstructorDeclarator - Called by ActOnDeclarator to check\n/// the well-formedness of the constructor declarator @p D with type @p\n/// R. If there are any errors in the declarator, this routine will\n/// emit diagnostics and set the invalid bit to true. In any case, the type\n/// will be updated to reflect a well-formed type for the constructor and\n/// returned.\nQualType Sema::CheckConstructorDeclarator(Declarator &D, QualType R, StorageClass &SC) {\n // C++ [class.ctor]p3:\n // A constructor shall not be virtual (10.3) or static (9.4). A\n // constructor can be invoked for a const, volatile or const\n // volatile object. A constructor shall not be declared const,\n // volatile, or const volatile (9.3.2).\n if (isVirtual) {\n if (!D.isInvalidType())\n Diag(D.getIdentifierLoc(), diag::err_constructor_cannot_be) << \"virtual\" << SourceRange(D.getDeclSpec().getVirtualSpecLoc()) << SourceRange(D.getIdentifierLoc());"},{w,10725,"/// CheckConstructorDeclarator - Called by ActOnDeclarator to check\n/// the well-formedness of the constructor declarator @p D with type @p\n/// R. If there are any errors in the declarator, this routine will\n/// emit diagnostics and set the invalid bit to true. In any case, the type\n/// will be updated to reflect a well-formed type for the constructor and\n/// returned.\nQualType Sema::CheckConstructorDeclarator(Declarator &D, QualType R, StorageClass &SC) {\n if (SC == SC_Static) {\n if (!D.isInvalidType())\n Diag(D.getIdentifierLoc(), diag::err_constructor_cannot_be) << \"static\" << SourceRange(D.getDeclSpec().getStorageClassSpecLoc()) << SourceRange(D.getIdentifierLoc());"}}, | [k]={{w,10718,"/// CheckConstructorDeclarator - Called by ActOnDeclarator to check\n/// the well-formedness of the constructor declarator @p D with type @p\n/// R. If there are any errors in the declarator, this routine will\n/// emit diagnostics and set the invalid bit to true. In any case, the type\n/// will be updated to reflect a well-formed type for the constructor and\n/// returned.\nQualType Sema::CheckConstructorDeclarator(Declarator &D, QualType R, StorageClass &SC) {\n // C++ [class.ctor]p3:\n // A constructor shall not be virtual (10.3) or static (9.4). A\n // constructor can be invoked for a const, volatile or const\n // volatile object. A constructor shall not be declared const,\n // volatile, or const volatile (9.3.2).\n if (isVirtual) {\n if (!D.isInvalidType())\n Diag(D.getIdentifierLoc(), diag::err_constructor_cannot_be) << \"virtual\" << SourceRange(D.getDeclSpec().getVirtualSpecLoc()) << SourceRange(D.getIdentifierLoc());"},{w,10725,"/// CheckConstructorDeclarator - Called by ActOnDeclarator to check\n/// the well-formedness of the constructor declarator @p D with type @p\n/// R. If there are any errors in the declarator, this routine will\n/// emit diagnostics and set the invalid bit to true. In any case, the type\n/// will be updated to reflect a well-formed type for the constructor and\n/// returned.\nQualType Sema::CheckConstructorDeclarator(Declarator &D, QualType R, StorageClass &SC) {\n if (SC == SC_Static) {\n if (!D.isInvalidType())\n Diag(D.getIdentifierLoc(), diag::err_constructor_cannot_be) << \"static\" << SourceRange(D.getDeclSpec().getStorageClassSpecLoc()) << SourceRange(D.getIdentifierLoc());"}}, | ||
[o]={ | [o]={ | ||
Line 9,007: | Line 9,027: | ||
}, | }, | ||
["err_constructor_redeclared"]={ | ["err_constructor_redeclared"]={ | ||
[e]="constructor cannot be redeclared", | |||
[d]=l, | |||
[f]=m, | |||
[h]="constructor cannot be redeclared", | [h]="constructor cannot be redeclared", | ||
[ | [b]=n, | ||
[ | [j]="constructor cannot be redeclared", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={E,1236199783,F,C}, | |||
[k]={{s,3999,"/// 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 if (getLangOpts().CPlusPlus) {\n if (OldMethod && NewMethod) {\n if (!isFriend && NewMethod->getLexicalDeclContext()->isRecord() && !IsClassScopeExplicitSpecialization) {\n // C++ [class.mem]p1:\n // [...] A member shall not be declared twice in the\n // member-specification, except that a nested class or member\n // class template can be declared and then later defined.\n if (!inTemplateInstantiation()) {\n if (isa<CXXConstructorDecl>(OldMethod))\n NewDiag = diag::err_constructor_redeclared;"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaOpenCLCXX/addrspace-constructors.clcpp"]={"clang/test/SemaOpenCLCXX/addrspace-constructors.clcpp:46:3: error: constructor cannot be redeclared"} | ["clang/test/SemaOpenCLCXX/addrspace-constructors.clcpp"]={"clang/test/SemaOpenCLCXX/addrspace-constructors.clcpp:46:3: error: constructor cannot be redeclared"} | ||
Line 9,022: | Line 9,042: | ||
}, | }, | ||
["err_constructor_return_type"]={ | ["err_constructor_return_type"]={ | ||
[e]="constructor cannot have a return type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="constructor cannot have a return type", | [h]="constructor cannot have a return type", | ||
[ | [b]=n, | ||
[ | [j]="constructor cannot have a return type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={E,1236199783,F,C}, | |||
[ | [k]={{s,9271,"static FunctionDecl *CreateNewFunctionDecl(Sema &SemaRef, Declarator &D, DeclContext *DC, QualType &R, TypeSourceInfo *TInfo, StorageClass SC, bool &IsVirtualOkay) {\n if (Name.getNameKind() == DeclarationName::CXXConstructorName) {\n } else if (Name.getNameKind() == DeclarationName::CXXDestructorName) {\n } else if (Name.getNameKind() == DeclarationName::CXXConversionFunctionName) {\n } else if (Name.getNameKind() == DeclarationName::CXXDeductionGuideName) {\n } else if (DC->isRecord()) {\n // If the name of the function is the same as the name of the record,\n // then this must be an invalid constructor that has a return type.\n // (The parser checks for a return type and makes the declarator a\n // constructor if it has no return type).\n if (Name.getAsIdentifierInfo() && Name.getAsIdentifierInfo() == cast<CXXRecordDecl>(DC)->getIdentifier()) {\n SemaRef.Diag(D.getIdentifierLoc(), diag::err_constructor_return_type) << SourceRange(D.getDeclSpec().getTypeSpecTypeLoc()) << SourceRange(D.getIdentifierLoc());"},{w,10734,"/// CheckConstructorDeclarator - Called by ActOnDeclarator to check\n/// the well-formedness of the constructor declarator @p D with type @p\n/// R. If there are any errors in the declarator, this routine will\n/// emit diagnostics and set the invalid bit to true. In any case, the type\n/// will be updated to reflect a well-formed type for the constructor and\n/// returned.\nQualType Sema::CheckConstructorDeclarator(Declarator &D, QualType R, StorageClass &SC) {\n if (unsigned TypeQuals = D.getDeclSpec().getTypeQualifiers()) {\n diagnoseIgnoredQualifiers(diag::err_constructor_return_type, TypeQuals, SourceLocation(), D.getDeclSpec().getConstSpecLoc(), D.getDeclSpec().getVolatileSpecLoc(), D.getDeclSpec().getRestrictSpecLoc(), D.getDeclSpec().getAtomicSpecLoc());"}}, | ||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/CXX/class/class.mem/p2.cpp"]={"clang/test/CXX/class/class.mem/p2.cpp:81:14: error: constructor cannot have a return type"} | ["clang/test/CXX/class/class.mem/p2.cpp"]={"clang/test/CXX/class/class.mem/p2.cpp:81:14: error: constructor cannot have a return type"} | ||
Line 9,037: | Line 9,057: | ||
}, | }, | ||
["err_continuation_class"]={ | ["err_continuation_class"]={ | ||
[e]="class extension has no primary class", | |||
[d]=l, | |||
[f]=m, | |||
[h]="class extension has no primary class", | [h]="class extension has no primary class", | ||
[ | [b]=n, | ||
[ | [j]="class extension has no primary class", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={E,1236199783,F,C}, | |||
[k]={{Y,429,"ObjCPropertyDecl *Sema::HandlePropertyInClassExtension(Scope *S, SourceLocation AtLoc, SourceLocation LParenLoc, FieldDeclarator &FD, Selector GetterSel, SourceLocation GetterNameLoc, Selector SetterSel, SourceLocation SetterNameLoc, const bool isReadWrite, unsigned &Attributes, const unsigned AttributesAsWritten, QualType T, TypeSourceInfo *TSI, tok::ObjCKeywordKind MethodImplKind) {\n // We need to look in the @interface to see if the @property was\n // already declared.\n if (!CCPrimary) {\n Diag(CDecl->getLocation(), diag::err_continuation_class);"}} | |||
[ | |||
[ | |||
[k]={{ | |||
}, | }, | ||
["err_continue_from_cond_var_init"]={ | ["err_continue_from_cond_var_init"]={ | ||
[e]="cannot jump from this continue statement to the loop increment; jump bypasses initialization of loop condition variable", | |||
[d]=l, | |||
[f]=m, | |||
[h]="cannot jump from this continue statement to the loop increment; jump bypasses initialization of loop condition variable", | [h]="cannot jump from this continue statement to the loop increment; jump bypasses initialization of loop condition variable", | ||
[ | [b]=n, | ||
[ | [j]="cannot jump from this continue statement to the loop increment; jump bypasses initialization of loop condition variable", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={sb,1590001902,T,T}, | |||
[k]={{bb,3337,"StmtResult Sema::ActOnContinueStmt(SourceLocation ContinueLoc, Scope *CurScope) {\n if (S->isConditionVarScope()) {\n return StmtError(Diag(ContinueLoc, diag::err_continue_from_cond_var_init));"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/SemaCXX/scope-check.cpp"]={"clang/test/SemaCXX/scope-check.cpp:643:20: error: cannot jump from this continue statement to the loop increment; jump bypasses initialization of loop condition variable"} | ["clang/test/SemaCXX/scope-check.cpp"]={"clang/test/SemaCXX/scope-check.cpp:643:20: error: cannot jump from this continue statement to the loop increment; jump bypasses initialization of loop condition variable"} | ||
Line 9,064: | Line 9,084: | ||
}, | }, | ||
["err_continue_not_in_loop"]={ | ["err_continue_not_in_loop"]={ | ||
[e]="\'continue\' statement not in loop statement", | |||
[d]=l, | |||
[f]=m, | |||
[h]="\'continue\' statement not in loop statement", | [h]="\'continue\' statement not in loop statement", | ||
[ | [b]=n, | ||
[ | [j]="\'continue\' statement not in loop statement", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{bb,3331,"StmtResult Sema::ActOnContinueStmt(SourceLocation ContinueLoc, Scope *CurScope) {\n if (!S) {\n return StmtError(Diag(ContinueLoc, diag::err_continue_not_in_loop));"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Parser/bad-control.c"]={"clang/test/Parser/bad-control.c:8:3: error: \'continue\' statement not in loop statement","clang/test/Parser/bad-control.c:23:10: error: \'continue\' statement not in loop statement"} | ["clang/test/Parser/bad-control.c"]={"clang/test/Parser/bad-control.c:8:3: error: \'continue\' statement not in loop statement","clang/test/Parser/bad-control.c:23:10: error: \'continue\' statement not in loop statement"} | ||
Line 9,079: | Line 9,099: | ||
}, | }, | ||
["err_conv_function_not_member"]={ | ["err_conv_function_not_member"]={ | ||
[e]="conversion function must be a non-static member function", | |||
[d]=l, | |||
[f]=m, | |||
[h]="conversion function must be a non-static member function", | [h]="conversion function must be a non-static member function", | ||
[ | [b]=n, | ||
[ | [j]="conversion function must be a non\\-static member function", | ||
[c]=a, | |||
[i]=p, | |||
[g]={v,1237025389,r,r}, | |||
[ | [k]={{s,9239,"static FunctionDecl *CreateNewFunctionDecl(Sema &SemaRef, Declarator &D, DeclContext *DC, QualType &R, TypeSourceInfo *TInfo, StorageClass SC, bool &IsVirtualOkay) {\n if (Name.getNameKind() == DeclarationName::CXXConstructorName) {\n } else if (Name.getNameKind() == DeclarationName::CXXDestructorName) {\n } else if (Name.getNameKind() == DeclarationName::CXXConversionFunctionName) {\n if (!DC->isRecord()) {\n SemaRef.Diag(D.getIdentifierLoc(), diag::err_conv_function_not_member);"},{w,10990,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // C++ [class.conv.fct]p1:\n // Neither parameter types nor return type can be specified. The\n // type of a conversion function (8.3.5) is \"function taking no\n // parameter returning conversion-type-id.\"\n if (SC == SC_Static) {\n if (!D.isInvalidType())\n Diag(D.getIdentifierLoc(), diag::err_conv_function_not_member) << SourceRange(D.getDeclSpec().getStorageClassSpecLoc()) << D.getName().getSourceRange();"}}, | ||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Zb]={"clang/test/SemaCXX/conversion-function.cpp:19:10: error: conversion function must be a non-static member function","clang/test/SemaCXX/conversion-function.cpp:22:1: error: conversion function must be a non-static member function"} | ||
} | } | ||
}, | }, | ||
["err_conv_function_redeclared"]={ | ["err_conv_function_redeclared"]={ | ||
[e]="conversion function cannot be redeclared", | |||
[d]=l, | |||
[f]=m, | |||
[h]="conversion function cannot be redeclared", | [h]="conversion function cannot be redeclared", | ||
[ | [b]=n, | ||
[ | [j]="conversion function cannot be redeclared", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[k]={{s,4003,"/// 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 if (getLangOpts().CPlusPlus) {\n if (OldMethod && NewMethod) {\n if (!isFriend && NewMethod->getLexicalDeclContext()->isRecord() && !IsClassScopeExplicitSpecialization) {\n // C++ [class.mem]p1:\n // [...] A member shall not be declared twice in the\n // member-specification, except that a nested class or member\n // class template can be declared and then later defined.\n if (!inTemplateInstantiation()) {\n if (isa<CXXConstructorDecl>(OldMethod))\n else if (isa<CXXDestructorDecl>(NewMethod))\n else if (isa<CXXConversionDecl>(NewMethod))\n NewDiag = diag::err_conv_function_redeclared;"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
[ | [Zb]={"clang/test/SemaCXX/conversion-function.cpp:52:3: error: conversion function cannot be redeclared","clang/test/SemaCXX/conversion-function.cpp:53:3: error: conversion function cannot be redeclared"} | ||
} | } | ||
}, | }, | ||
["err_conv_function_return_type"]={ | ["err_conv_function_return_type"]={ | ||
[e]="conversion function cannot have a return type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="conversion function cannot have a return type", | [h]="conversion function cannot have a return type", | ||
[ | [b]=n, | ||
[ | [j]="conversion function cannot have a return type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[ | |||
[ | |||
[k]={{w,11011,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n if (DS.hasTypeSpecifier() && !D.isInvalidType()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_return_type) << SourceRange(DS.getTypeSpecTypeLoc()) << SourceRange(D.getIdentifierLoc());"}}, | [k]={{w,11011,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n if (DS.hasTypeSpecifier() && !D.isInvalidType()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_return_type) << SourceRange(DS.getTypeSpecTypeLoc()) << SourceRange(D.getIdentifierLoc());"}}, | ||
[o]={ | [o]={ | ||
[ | [Zb]={"clang/test/SemaCXX/conversion-function.cpp:31:8: error: conversion function cannot have a return type"} | ||
} | } | ||
}, | }, | ||
["err_conv_function_to_array"]={ | ["err_conv_function_to_array"]={ | ||
[e]="conversion function cannot convert to an array type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="conversion function cannot convert to an array type", | [h]="conversion function cannot convert to an array type", | ||
[ | [b]=n, | ||
[ | [j]="conversion function cannot convert to an array type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[ | |||
[ | |||
[k]={{w,11120,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // C++ [class.conv.fct]p4:\n // The conversion-type-id shall not represent a function type nor\n // an array type.\n if (ConvType->isArrayType()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_to_array);"}}, | [k]={{w,11120,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // C++ [class.conv.fct]p4:\n // The conversion-type-id shall not represent a function type nor\n // an array type.\n if (ConvType->isArrayType()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_to_array);"}}, | ||
[o]={ | [o]={ | ||
[ | [Zb]={"clang/test/SemaCXX/conversion-function.cpp:41:3: error: conversion function cannot convert to an array type"} | ||
} | } | ||
}, | }, | ||
["err_conv_function_to_function"]={ | ["err_conv_function_to_function"]={ | ||
[e]="conversion function cannot convert to a function type", | |||
[d]=l, | |||
[f]=m, | |||
[h]="conversion function cannot convert to a function type", | [h]="conversion function cannot convert to a function type", | ||
[ | [b]=n, | ||
[ | [j]="conversion function cannot convert to a function type", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[ | |||
[ | |||
[k]={{w,11124,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // C++ [class.conv.fct]p4:\n // The conversion-type-id shall not represent a function type nor\n // an array type.\n if (ConvType->isArrayType()) {\n } else if (ConvType->isFunctionType()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_to_function);"}}, | [k]={{w,11124,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // C++ [class.conv.fct]p4:\n // The conversion-type-id shall not represent a function type nor\n // an array type.\n if (ConvType->isArrayType()) {\n } else if (ConvType->isFunctionType()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_to_function);"}}, | ||
[o]={ | [o]={ | ||
Line 9,154: | Line 9,174: | ||
}, | }, | ||
["err_conv_function_variadic"]={ | ["err_conv_function_variadic"]={ | ||
[e]="conversion function cannot be variadic", | |||
[d]=l, | |||
[f]=m, | |||
[h]="conversion function cannot be variadic", | [h]="conversion function cannot be variadic", | ||
[ | [b]=n, | ||
[ | [j]="conversion function cannot be variadic", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[ | |||
[ | |||
[k]={{w,11036,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // Make sure we don\'t have any parameters.\n if (Proto->getNumParams() > 0) {\n } else if (Proto->isVariadic()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_variadic);"}}, | [k]={{w,11036,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // Make sure we don\'t have any parameters.\n if (Proto->getNumParams() > 0) {\n } else if (Proto->isVariadic()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_variadic);"}}, | ||
[o]={ | [o]={ | ||
[ | [Zb]={"clang/test/SemaCXX/conversion-function.cpp:37:3: error: conversion function cannot be variadic"} | ||
} | } | ||
}, | }, | ||
["err_conv_function_with_complex_decl"]={ | ["err_conv_function_with_complex_decl"]={ | ||
[ | [e]="cannot specify any part of a return type in the declaration of a conversion function...", | ||
[ | [d]=l, | ||
[ | [f]=m, | ||
[ | [h]="cannot specify any part of a return type in the declaration of a conversion function%select{; put the complete type after \'operator\'|; use a typedef to declare a conversion to %1|; use an alias template to declare a conversion to %1|}0", | ||
[ | [b]=n, | ||
[ | [j]="cannot specify any part of a return type in the declaration of a conversion function(?:; put the complete type after \'operator\'|; use a typedef to declare a conversion to (.*?)|; use an alias template to declare a conversion to (.*?)|)", | ||
[ | [c]=a, | ||
[ | [i]=p, | ||
[ | [g]={"212fa2efb700",1271117071,"Diagnose declarations of conversion functions with declarators other than \'()\'.","Diagnose declarations of conversion functions with declarators other than \'()\'."}, | ||
[k]={{w,11021,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n if (DS.hasTypeSpecifier() && !D.isInvalidType()) {\n } else if (DS.getTypeQualifiers() && !D.isInvalidType()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_with_complex_decl) << SourceRange(D.getIdentifierLoc()) << 0;"},{w,11084,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // Diagnose \"&operator bool()\" and other such nonsense. This\n // is actually a gcc extension which we don\'t support.\n if (Proto->getReturnType() != ConvType) {\n auto &&DB = Diag(Loc, diag::err_conv_function_with_complex_decl);"}}, | [k]={{w,11021,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n if (DS.hasTypeSpecifier() && !D.isInvalidType()) {\n } else if (DS.getTypeQualifiers() && !D.isInvalidType()) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_with_complex_decl) << SourceRange(D.getIdentifierLoc()) << 0;"},{w,11084,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // Diagnose \"&operator bool()\" and other such nonsense. This\n // is actually a gcc extension which we don\'t support.\n if (Proto->getReturnType() != ConvType) {\n auto &&DB = Diag(Loc, diag::err_conv_function_with_complex_decl);"}}, | ||
[o]={ | [o]={ | ||
Line 9,184: | Line 9,204: | ||
}, | }, | ||
["err_conv_function_with_params"]={ | ["err_conv_function_with_params"]={ | ||
[e]="conversion function cannot have any parameters", | |||
[d]=l, | |||
[f]=m, | |||
[h]="conversion function cannot have any parameters", | [h]="conversion function cannot have any parameters", | ||
[ | [b]=n, | ||
[ | [j]="conversion function cannot have any parameters", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={v,1237025389,r,r}, | |||
[ | |||
[ | |||
[k]={{w,11030,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // Make sure we don\'t have any parameters.\n if (Proto->getNumParams() > 0) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_with_params);"}}, | [k]={{w,11030,"/// CheckConversionDeclarator - Called by ActOnDeclarator to check the\n/// well-formednes of the conversion function declarator @p D with\n/// type @p R. If there are any errors in the declarator, this routine\n/// will emit diagnostics and return true. Otherwise, it will return\n/// false. Either way, the type @p R will be updated to reflect a\n/// well-formed type for the conversion operator.\nvoid Sema::CheckConversionDeclarator(Declarator &D, QualType &R, StorageClass &SC) {\n // Make sure we don\'t have any parameters.\n if (Proto->getNumParams() > 0) {\n Diag(D.getIdentifierLoc(), diag::err_conv_function_with_params);"}}, | ||
[o]={ | [o]={ | ||
[ | [Zb]={"clang/test/SemaCXX/conversion-function.cpp:31:8: error: conversion function cannot have any parameters","clang/test/SemaCXX/conversion-function.cpp:34:3: error: conversion function cannot have any parameters"} | ||
} | } | ||
}, | }, | ||
["err_convertvector_incompatible_vector"]={ | ["err_convertvector_incompatible_vector"]={ | ||
[e]="first two arguments to __builtin_convertvector must have the same number of elements", | |||
[d]=l, | |||
[f]=m, | |||
[h]="first two arguments to __builtin_convertvector must have the same number of elements", | [h]="first two arguments to __builtin_convertvector must have the same number of elements", | ||
[ | [b]=n, | ||
[ | [j]="first two arguments to __builtin_convertvector must have the same number of elements", | ||
[c]=a, | |||
[ | [i]=p, | ||
[g]={"c4d7c82c7f73",1379474985,"Add the intrinsic __builtin_convertvector","Add the intrinsic __builtin_convertvector"}, | |||
[k]={{u,8546,"/// SemaConvertVectorExpr - Handle __builtin_convertvector\nExprResult Sema::SemaConvertVectorExpr(Expr *E, TypeSourceInfo *TInfo, SourceLocation BuiltinLoc, SourceLocation RParenLoc) {\n if (!SrcTy->isDependentType() && !DstTy->isDependentType()) {\n if (SrcElts != DstElts)\n return ExprError(Diag(BuiltinLoc, diag::err_convertvector_incompatible_vector) << E->getSourceRange());"}}, | |||
[ | |||
[ | |||
[k]={{ | |||
[o]={ | [o]={ | ||
["clang/test/Sema/convertvector.c"]={"clang/test/Sema/convertvector.c:7:10: error: first two arguments to __builtin_convertvector must have the same number of elements"} | ["clang/test/Sema/convertvector.c"]={"clang/test/Sema/convertvector.c:7:10: error: first two arguments to __builtin_convertvector must have the same number of elements"} |
edits