summaryrefslogtreecommitdiffstats
path: root/libcxx/docs
diff options
context:
space:
mode:
authorLouis Dionne <ldionne@apple.com>2019-08-13 11:12:28 +0000
committerLouis Dionne <ldionne@apple.com>2019-08-13 11:12:28 +0000
commit86dd28a5471480cd7a8cb5ad4801599ac0a0ac20 (patch)
tree0e60db66f9898c354bd534cfb43cc76f8d57506c /libcxx/docs
parente7b350a5d11bce823fc3254ab6a084186e15d4f0 (diff)
downloadbcm5719-llvm-86dd28a5471480cd7a8cb5ad4801599ac0a0ac20.tar.gz
bcm5719-llvm-86dd28a5471480cd7a8cb5ad4801599ac0a0ac20.zip
[libc++] Use [[nodiscard]] for lock_guard, as an extension
Summary: D64914 added support for applying [[nodiscard]] to constructors. This commit uses that capability to flag incorrect uses of std::lock_guard where one forgets to actually create a variable for the lock_guard. rdar://45790820 Reviewers: mclow.lists, EricWF Subscribers: christof, jkorous, dexonsmith, libcxx-commits, Quuxplusone, lebedev.ri Tags: #libc Differential Revision: https://reviews.llvm.org/D65900 llvm-svn: 368664
Diffstat (limited to 'libcxx/docs')
-rw-r--r--libcxx/docs/UsingLibcxx.rst1
1 files changed, 1 insertions, 0 deletions
diff --git a/libcxx/docs/UsingLibcxx.rst b/libcxx/docs/UsingLibcxx.rst
index 56c98af5586..05721bf271a 100644
--- a/libcxx/docs/UsingLibcxx.rst
+++ b/libcxx/docs/UsingLibcxx.rst
@@ -345,3 +345,4 @@ which no dialect declares as such (See the second form described above).
* ``search``
* ``unique``
* ``upper_bound``
+* ``lock_guard``'s constructors
OpenPOWER on IntegriCloud