]> granicus.if.org Git - clang/commit
Change -Wbind-to-temporary-copy from an ExtWarn to an Extension.
authorNico Weber <nicolasweber@gmx.de>
Thu, 18 Sep 2014 02:09:53 +0000 (02:09 +0000)
committerNico Weber <nicolasweber@gmx.de>
Thu, 18 Sep 2014 02:09:53 +0000 (02:09 +0000)
commit3bdb38bfc3244d28b03035034b78afcb7187b87c
tree711e8f7dc23592719e1707c696405d750c0a37a3
parent89b53e0a49c30942d4ef77218a6155e0699a3f00
Change -Wbind-to-temporary-copy from an ExtWarn to an Extension.

The reasoning is that this construct is accepted by all compilers and valid in
C++11, so it doesn't seem like a useful warning to have enabled by default.
Building with -pedantic, -Wbind-to-temporary-copy, or -Wc++98-compat still
shows the warning.

The motivation is that I built re2, and this was the only warning that was
emitted during the build. Both changing re2 to fix the warning and detecting
clang and suppressing the warning in re2's build seem inferior than just giving
the compiler a good default for this warning.

Also move the cxx98compat version of this warning to CXX98CompatPedantic, and
update tests accordingly.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@218008 91177308-0d34-0410-b5e6-96231b3b80d8
docs/UsersManual.rst
include/clang/Basic/DiagnosticGroups.td
include/clang/Basic/DiagnosticSemaKinds.td
test/CXX/dcl.decl/dcl.init/dcl.init.ref/p5-cxx03-extra-copy.cpp
test/SemaCXX/conversion-function.cpp
test/SemaCXX/cxx98-compat-flags.cpp
test/SemaCXX/cxx98-compat-pedantic.cpp
test/SemaCXX/cxx98-compat.cpp
test/SemaCXX/undefined-internal.cpp