[clang] [CIR] Implement 'weak-ref' lowering (PR #238538)
Andy Kaylor via cfe-commits
cfe-commits at lists.llvm.org
Tue Nov 3 17:49:47 PST 2026
================
@@ -1323,7 +1326,7 @@ CIRGenModule::getOrCreateCIRGlobal(StringRef mangledName, mlir::Type ty,
return entry;
}
- mlir::Location loc = getLoc(d->getSourceRange());
+ mlir::Location loc = d ? getLoc(d->getSourceRange()) : theModule->getLoc();
----------------
andykaylor wrote:
Oof! Could we pass in a location for the case where `d` is null?
https://github.com/llvm/llvm-project/pull/238538
More information about the cfe-commits
mailing list