Skip to content

Commit

Permalink
Bug 1484184 - Remove now unused _RAISE macro check to deal with MSVC …
Browse files Browse the repository at this point in the history
…2017 15.8. r=froydnj

--HG--
extra : source : b38403f36056d301321c128be96ee60d14739859
  • Loading branch information
vyv03354 committed Aug 16, 2018
1 parent 66fa613 commit 3d01e51
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 34 deletions.
7 changes: 3 additions & 4 deletions memory/mozalloc/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,9 @@ if CONFIG['WRAP_STL_INCLUDES']:
EXPORTS.mozilla += ['throw_gcc.h']
elif CONFIG['CC_TYPE'] in ('msvc', 'clang-cl'):
DEFINES['_HAS_EXCEPTIONS'] = 0
if CONFIG['MOZ_MSVC_STL_WRAP_RAISE']:
SOURCES += [
'msvc_raise_wrappers.cpp',
]
SOURCES += [
'msvc_raise_wrappers.cpp',
]

if CONFIG['OS_TARGET'] == 'WINNT':
# Keep this file separate to avoid #include'ing windows.h everywhere.
Expand Down
32 changes: 2 additions & 30 deletions old-configure.in
Original file line number Diff line number Diff line change
Expand Up @@ -281,35 +281,8 @@ case "$target" in

unset _MSVC_VER_FILTER

AC_CACHE_CHECK(for overridable _RAISE,
ac_cv_have__RAISE,
[
AC_LANG_SAVE
AC_LANG_CPLUSPLUS
_SAVE_CXXFLAGS="$CXXFLAGS"
CXXFLAGS="${CXXFLAGS} -D_HAS_EXCEPTIONS=0"
AC_TRY_COMPILE([#include <xstddef>
#undef _RAISE
#define _RAISE(x) externallyDefinedFunction((x).what())
#include <vector>
],
[std::vector<int> v; return v.at(1);],
ac_cv_have__RAISE="no",
ac_cv_have__RAISE="yes")
CXXFLAGS="$_SAVE_CXXFLAGS"
AC_LANG_RESTORE
])
if test "$ac_cv_have__RAISE" = "yes"; then
WRAP_STL_INCLUDES=1
MOZ_MSVC_STL_WRAP_RAISE=1
AC_DEFINE(MOZ_MSVC_STL_WRAP_RAISE)
else
AC_MSG_ERROR([Gecko exception wrapping doesn't understand your your MSVC/SDK. Please file a bug describing this error and your build configuration.])
fi

if test "$WRAP_STL_INCLUDES" = "1"; then
STL_FLAGS="-I${DIST}/stl_wrappers"
fi
WRAP_STL_INCLUDES=1
STL_FLAGS="-I${DIST}/stl_wrappers"
CFLAGS="$CFLAGS -D_HAS_EXCEPTIONS=0"
CXXFLAGS="$CXXFLAGS -D_HAS_EXCEPTIONS=0"
else
Expand Down Expand Up @@ -395,7 +368,6 @@ AC_SUBST(GNU_CXX)

AC_SUBST_LIST(STL_FLAGS)
AC_SUBST(WRAP_STL_INCLUDES)
AC_SUBST(MOZ_MSVC_STL_WRAP_RAISE)

dnl ========================================================
dnl Checks for programs.
Expand Down

0 comments on commit 3d01e51

Please sign in to comment.