Bug 1124033 - Replace blanket disabling of VS2015 warnings with C5026 and C5027; r?ehsan
Wv:18 was added in
bug 1119072 as a quick way to get the tree building
with VS2015. Now that we're closer to rolling out VS2015 support, we
want to expose its new warnings.
This patch replaces the blanket disabling of new warnings in VS2015 with
just disabling C5026 and C5027, which relate to symbols being implicitly
defined as deleted.
MozReview-Commit-ID: 8uniydfNJns
--- a/js/src/old-configure.in
+++ b/js/src/old-configure.in
@@ -293,20 +293,21 @@ case "$target" in
_CC_SUITE=12
MSVC_C_RUNTIME_DLL=msvcr120.dll
MSVC_CXX_RUNTIME_DLL=msvcp120.dll
elif test "$_CC_MAJOR_VERSION" = "19"; then
_CC_SUITE=14
MSVC_C_RUNTIME_DLL=vcruntime140.dll
MSVC_CXX_RUNTIME_DLL=msvcp140.dll
- # -Wv:18 disables all warnings introduced after VS2013
- # See http://blogs.msdn.com/b/vcblog/archive/2014/11/12/improvements-to-warnings-in-the-c-compiler.aspx
- CFLAGS="$CFLAGS -Wv:18"
- CXXFLAGS="$CXXFLAGS -Wv:18"
+ # C5026: move constructor was implicitly defined as deleted
+ CXXFLAGS="$CXXFLAGS -wd5026"
+
+ # C5027: move assignment operator was implicitly defined as deleted
+ CXXFLAGS="$CXXFLAGS -wd5027"
# -Zc:sizedDealloc- disables C++14 global sized deallocation (see bug 1160146)
CXXFLAGS="$CXXFLAGS -Zc:sizedDealloc-"
# Disable C++11 thread-safe statics due to crashes on XP (bug 1204752)
# See https://connect.microsoft.com/VisualStudio/feedback/details/1789709/visual-c-2015-runtime-broken-on-windows-server-2003-c-11-magic-statics
CXXFLAGS="$CXXFLAGS -Zc:threadSafeInit-"
else
--- a/old-configure.in
+++ b/old-configure.in
@@ -435,20 +435,21 @@ case "$target" in
MSVC_C_RUNTIME_DLL=vcruntime140.dll
MSVC_CXX_RUNTIME_DLL=msvcp140.dll
MOZ_CHECK_HEADER(dia2.h, MSVC_HAS_DIA_SDK=1)
if test -n "$MSVC_HAS_DIA_SDK"; then
AC_DEFINE(MSVC_HAS_DIA_SDK)
fi
- # -Wv:18 disables all warnings introduced after VS2013
- # See http://blogs.msdn.com/b/vcblog/archive/2014/11/12/improvements-to-warnings-in-the-c-compiler.aspx
- CFLAGS="$CFLAGS -Wv:18"
- CXXFLAGS="$CXXFLAGS -Wv:18"
+ # C5026: move constructor was implicitly defined as deleted
+ CXXFLAGS="$CXXFLAGS -wd5026"
+
+ # C5027: move assignment operator was implicitly defined as deleted
+ CXXFLAGS="$CXXFLAGS -wd5027"
# -Zc:sizedDealloc- disables C++14 global sized deallocation (see bug 1160146)
CXXFLAGS="$CXXFLAGS -Zc:sizedDealloc-"
# Disable C++11 thread-safe statics due to crashes on XP (bug 1204752)
# See https://connect.microsoft.com/VisualStudio/feedback/details/1789709/visual-c-2015-runtime-broken-on-windows-server-2003-c-11-magic-statics
CXXFLAGS="$CXXFLAGS -Zc:threadSafeInit-"