Skip to content

Commit 69f1d1d

Browse files
committed
Merge pull request opencv#8296 from ville-v:master
2 parents 47c4dcc + 0c1bcf3 commit 69f1d1d

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

modules/core/include/opencv2/core/cvdef.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -438,7 +438,7 @@ Cv64suf;
438438

439439
#ifdef CV_XADD
440440
// allow to use user-defined macro
441-
#elif defined __GNUC__
441+
#elif defined __GNUC__ || defined __clang__
442442
# if defined __clang__ && __clang_major__ >= 3 && !defined __ANDROID__ && !defined __EMSCRIPTEN__ && !defined(__CUDACC__)
443443
# ifdef __ATOMIC_ACQ_REL
444444
# define CV_XADD(addr, delta) __c11_atomic_fetch_add((_Atomic(int)*)(addr), delta, __ATOMIC_ACQ_REL)

modules/core/include/opencv2/core/fast_math.hpp

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,12 +54,14 @@
5454
* fast math *
5555
\****************************************************************************************/
5656

57-
#if defined __BORLANDC__
58-
# include <fastmath.h>
59-
#elif defined __cplusplus
57+
#ifdef __cplusplus
6058
# include <cmath>
6159
#else
62-
# include <math.h>
60+
# ifdef __BORLANDC__
61+
# include <fastmath.h>
62+
# else
63+
# include <math.h>
64+
# endif
6365
#endif
6466

6567
#ifdef HAVE_TEGRA_OPTIMIZATION

0 commit comments

Comments
 (0)