================
@@ -9950,6 +9950,8 @@ def warn_ret_stack_addr_ref : Warning<
 def warn_ret_local_temp_addr_ref : Warning<
   "returning %select{address of|reference to}0 local temporary object">,
   InGroup<ReturnStackAddress>;
+def err_ret_local_temp_addr_ref : Error<
+  "returning %select{address of|reference to}0 local temporary object">;
----------------
erichkeane wrote:

```suggestion
  warn_ret_local_temp_addr_ref.Text>;
```

(or something like that?  Either way, the messages are intentionally the same, 
would be nice to just share the text).

https://github.com/llvm/llvm-project/pull/89942
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to