Skip to content
Commit 7ab570ec authored by Justin Lebar's avatar Justin Lebar
Browse files

[ADT] Warn on unused results from ArrayRef and StringRef functions that read...

[ADT] Warn on unused results from ArrayRef and StringRef functions that read like they might mutate.

Summary:
Functions like "slice" and "drop_front" sound like they might mutate the
underlying object, but they don't.  Warning on unused results would have
saved me an hour yesterday, and I'm sure I'm not the only one.

LLVM and Clang are clean wrt this warning after D22540.

Reviewers: majnemer

Subscribers: sanjoy, chandlerc, llvm-commits

Differential Revision: https://reviews.llvm.org/D22541

llvm-svn: 276058
parent ea9598b1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment