[llvm] [clang] [clang] report inlining decisions with -Wattribute-{warning|error} (PR #73552)

Nick Desaulniers via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 27 11:16:07 PST 2023


================
@@ -93,6 +93,8 @@ def err_fe_backend_error_attr :
 def warn_fe_backend_warning_attr :
   Warning<"call to '%0' declared with 'warning' attribute: %1">, BackendInfo,
   InGroup<BackendWarningAttributes>;
+def note_fe_backend_in : Note<"called by function '%0'">;
----------------
nickdesaulniers wrote:

All of the diagnostics for backend warnings are defined in this file. (see existing lines 66-95).

As is, this note is emitted alongside the err/warn from existing lines 91-95, so it makes sense to put the new notes immediately after those existing definitions.

If my newly added backend warning notes belong in a new file, then all of the above belong in a new file.  But that seems orthogonal to my patch.

https://github.com/llvm/llvm-project/pull/73552


More information about the cfe-commits mailing list