[clang] [Clang] include attribute scope in diagnostics (PR #144619)
Aaron Ballman via cfe-commits
cfe-commits at lists.llvm.org
Thu Jun 26 04:28:31 PDT 2025
================
@@ -506,7 +506,15 @@ void clang::FormatASTNodeDiagnosticArgument(
case DiagnosticsEngine::ak_attr: {
const Attr *At = reinterpret_cast<Attr *>(Val);
assert(At && "Received null Attr object!");
- OS << '\'' << At->getSpelling() << '\'';
+
+ OS << '\'';
+ if (At->hasScope()) {
----------------
AaronBallman wrote:
Do we still need `ak_attr` at all? `Attr` inherits from `AttributeCommonInfo`, so I think we end up handling `AttributeCommonInfo`, `ParsedAttr`, and `Attr` all the same way now, right?
https://github.com/llvm/llvm-project/pull/144619
More information about the cfe-commits
mailing list