[clang] [clang] Generate note on declaration for nodiscard-related attributes (PR #112289)
via cfe-commits
cfe-commits at lists.llvm.org
Tue Oct 15 08:12:19 PDT 2024
Sirraide wrote:
> There seems to exist a discrepancy between `[[deprecated]]` and `[[nodiscard]]`. The former generates a warning on the usage of the function, together with a note on the declaration of the function. In contrast, the latter only generates a warning.
As I said, I feel like that might be by design, though.
> No new test cases are added, as I felt that adding expected-notes on existing test cases already serves as testing for this PR.
Yeah, there are already enough tests for this.
https://github.com/llvm/llvm-project/pull/112289
More information about the cfe-commits
mailing list