[llvm] r284364 - ADT: Use LLVM_NODISCARD instead of LLVM_ATTRIBUTE_UNUSED_RESULT for StringRef
Zachary Turner via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 28 09:02:13 PST 2016
On Sun, Nov 27, 2016 at 10:54 PM Justin Bogner <mail at justinbogner.com>
wrote:
> Personally, I'd put it on `int` if I could. I don't see a problem with
> adding nodiscard to any of those types.
>
In that case how about adding a warning to clang, such as
-wunused-result-strict that warns any time a return value is ignored,
regardless of the presence of this attribute?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161128/3c2096c3/attachment.html>
More information about the llvm-commits
mailing list