================ @@ -885,16 +885,19 @@ bool Sema::DiagnoseUninstantiableTemplate(SourceLocation PointOfInstantiation, /// that the template parameter 'PrevDecl' is being shadowed by a new /// declaration at location Loc. Returns true to indicate that this is /// an error, and false otherwise. -void Sema::DiagnoseTemplateParameterShadow(SourceLocation Loc, Decl *PrevDecl) { +void Sema::DiagnoseTemplateParameterShadow(SourceLocation Loc, Decl *PrevDecl, + bool IssueWarning) { ---------------- AaronBallman wrote:
The javadocs don't help too much because they're in the source file rather than attached to the declaration (so they don't show up in all IDEs, like Visual Studio). We should move them to the header file. I would recommend we change the logic slightly and name the parameter `SupportedAsExtension`. Then the diagnostic selection becomes `SupportedAsExtension ? (MSVC ? msvc_ext_diag : generic_ext_diag) : err_diag` and it's easier for the caller to reason about whether this shadowing should be supported as an extension or not in any given case. WDYT? https://github.com/llvm/llvm-project/pull/79683 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits