[PATCH] D48912: [libc++] Add deprecated attributes to many deprecated components

Roman Lebedev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 4 12:50:51 PDT 2018


lebedev.ri added a comment.

In https://reviews.llvm.org/D48912#1151731, @mclow.lists wrote:

> Like the "don't discard return values" patch that is currently under review (https://reviews.llvm.org/D45179), this needs to be opt-in - otherwise people will complain (loudly).
>  I am in favor of doing this - just not by default.




In https://reviews.llvm.org/D48912#1151733, @mclow.lists wrote:

> So if someone defines (say) `_LIBCXX_DEPRECATION_WARNINGS` in their build flags, they get the warnings. Otherwise, not.


I'm not sure this is a good/correct example.
libcxx **does** warn **by default** about nodiscard, it's not opt-in.
What https://reviews.llvm.org/D45179 does, is allows users to opt-in into nodiscard warnings with *earlier* `-std=c++xy` versions.


Repository:
  rL LLVM

https://reviews.llvm.org/D48912





More information about the llvm-commits mailing list