]> git.lizzy.rs Git - rust.git/blobdiff - compiler/rustc_codegen_llvm/src/attributes.rs
Rollup merge of #101503 - spastorino:add-debug-calls, r=compiler-errors
[rust.git] / compiler / rustc_codegen_llvm / src / attributes.rs
index aabbe8ac276d7ca7233618dcee8c3944da1fecdc..b38684a63e410d103150011d9ab452dfde04503d 100644 (file)
@@ -386,7 +386,8 @@ pub fn from_fn_attrs<'ll, 'tcx>(
     ) {
         let span = cx
             .tcx
-            .get_attr(instance.def_id(), sym::target_feature)
+            .get_attrs(instance.def_id(), sym::target_feature)
+            .next()
             .map_or_else(|| cx.tcx.def_span(instance.def_id()), |a| a.span);
         let msg = format!(
             "the target features {} must all be either enabled or disabled together",