Skip to content

Commit d1527e3

Browse files
committed
1. Fix accident (forgot to undo temporary change). 2. Special-case __EMSCRIPTEN__ in exo_planet_c_api.cpp
1 parent 1b28837 commit d1527e3

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

tests/exo_planet_c_api.cpp

+7-3
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,17 @@
33
// In production situations it is totally fine to build with
44
// C++ Exception Handling enabled. However, here we want to ensure that
55
// C++ Exception Handling is not required.
6-
#ifdef __cpp_exceptions
6+
#ifdef __EMSCRIPTEN__
7+
// Too much trouble making the required cmake changes.
8+
#else
9+
# ifdef __cpp_exceptions
710
// https://isocpp.org/std/standing-documents/sd-6-sg10-feature-test-recommendations#__cpp_exceptions
811
# error This test is meant to be built with C++ Exception Handling disabled, but __cpp_exceptions is defined.
9-
#endif
10-
#ifndef __EXCEPTIONS
12+
# endif
13+
# ifdef __EXCEPTIONS
1114
// https://gcc.gnu.org/onlinedocs/cpp/Common-Predefined-Macros.html
1215
# error This test is meant to be built with C++ Exception Handling disabled, but __EXCEPTIONS is defined.
16+
# endif
1317
#endif
1418

1519
// THIS MUST STAY AT THE TOP!

0 commit comments

Comments
 (0)