================
@@ -14127,6 +14093,15 @@ void Sema::AddInitializerToDecl(Decl *RealDecl, Expr
*Init, bool DirectInit) {
return;
}
+ // handleAliasAttr() runs before the initializer is attached to the VarDecl,
+ // so it cannot determine that an extern declaration with an initializer is a
+ // definition. Diagnose the conflict now that an initializer is present and
----------------
AaronBallman wrote:
Yeah, Eli and I were in agreement; the alias attribute makes it a definition
rather than a declaration. I think these are related issues though and probably
should be handled together. But I don't insist; this is still forward progress
even if it doesn't solve all the issues, but if you elect not to solve it,
please be sure to file an issue so we track the bug.
https://github.com/llvm/llvm-project/pull/223124
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits