fix some preprocessor directive

Apparently using `#if defined(X) or defined(Y)` did not
trouve the compilers, but Swig was confused by the "or".

* spot/misc/common.hh, spot/tl/formula.hh: Use || instead.
This commit is contained in:
Alexandre Duret-Lutz 2024-02-06 14:11:42 +01:00
parent 27b8e5aa73
commit 342360f8ca
2 changed files with 2 additions and 2 deletions

View file

@ -67,7 +67,7 @@
// Else use SPOT_ASSERT so the assert() are removed from user's // Else use SPOT_ASSERT so the assert() are removed from user's
// builds. // builds.
#define spot_assert__ assert #define spot_assert__ assert
#if defined(SPOT_BUILD) or defined(SPOT_DEBUG) #if defined(SPOT_BUILD) || defined(SPOT_DEBUG)
#define SPOT_ASSERT(x) spot_assert__(x) #define SPOT_ASSERT(x) spot_assert__(x)
#else #else
// Do not replace by SPOT_ASSUME(x), as x can have some costly // Do not replace by SPOT_ASSUME(x), as x can have some costly

View file

@ -59,7 +59,7 @@
// The strong_X operator was introduced in Spot 2.8.2 to fix an issue // The strong_X operator was introduced in Spot 2.8.2 to fix an issue
// with from_ltlf(). As adding a new operator is a backward // with from_ltlf(). As adding a new operator is a backward
// incompatibility, causing new warnings from the compiler. // incompatibility, causing new warnings from the compiler.
#if defined(SPOT_BUILD) or defined(SPOT_USES_STRONG_X) #if defined(SPOT_BUILD) || defined(SPOT_USES_STRONG_X)
// Use #if SPOT_HAS_STRONG_X in code that need to be backward // Use #if SPOT_HAS_STRONG_X in code that need to be backward
// compatible with older Spot versions. // compatible with older Spot versions.
# define SPOT_HAS_STRONG_X 1 # define SPOT_HAS_STRONG_X 1