[clang] [CIR][ABI] Add restrict, nonnull, and ReturnsNonNull attributes (PR #188281)
via cfe-commits
cfe-commits at lists.llvm.org
Wed Apr 15 10:58:48 PDT 2026
================
@@ -698,6 +704,36 @@ void CIRGenModule::constructFunctionArgumentAttributes(
builder.getI64IntegerAttr(
getNaturalPointeeTypeAlignment(argType).getQuantity()));
}
+
+ // Source-level parameter attributes (restrict, nonnull). These
+ // require the FunctionDecl to access ParmVarDecl info.
+ if (fd) {
+ unsigned paramIdx = &argAttrList - argAttrs.data();
----------------
adams381 wrote:
Fixed by the same restructuring -- ParmVarDecl now comes from the zip loop directly.
https://github.com/llvm/llvm-project/pull/188281
More information about the cfe-commits
mailing list