Enable -Wcast-qual for C++ files, where intentional qualifier-stripping can

be done with const_cast.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101798 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Dan Gohman 2010-04-19 18:33:28 +00:00
parent dacd479173
commit 3072b8aa97

View File

@ -633,6 +633,8 @@ CompileCommonOpts += -pedantic -Wno-long-long
endif
CompileCommonOpts += -Wall -W -Wno-unused-parameter -Wwrite-strings \
$(EXTRA_OPTIONS)
# Enable cast-qual for C++; the workaround is to use const_cast.
CXX.Flags += -Wcast-qual
ifeq ($(HOST_OS),HP-UX)
CompileCommonOpts := -D_REENTRANT -D_HPUX_SOURCE