Skip to content

Commit

Permalink
Clang compatibility.
Browse files Browse the repository at this point in the history
  • Loading branch information
pleroy committed Oct 26, 2024
1 parent 1bff2f9 commit e47f51c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ CXX := clang++
COMPILER_OPTIONS := \
-std=c++1z -stdlib=libc++ -O3 -g \
-fPIC -fexceptions -ferror-limit=1 -fno-omit-frame-pointer \
-Wall -Wpedantic \
-Wall -Wpedantic -Wno-deprecated -Wno-gnu-anonymous-struct \
-DNDEBUG -Iinclude -Ideps/abseil-cpp

LIBRARY_TRANSLATION_UNITS := \
Expand Down
2 changes: 2 additions & 0 deletions src/binary64/cos/cos.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ SOFTWARE.

#pragma STDC FENV_ACCESS ON

#if defined(_MSC_VER)
#ifndef __builtin_clzl
#define __builtin_clzl(x) __lzcnt64(x)
#endif
Expand All @@ -61,6 +62,7 @@ SOFTWARE.
#ifndef __builtin_floor
#define __builtin_floor(x) std::floor(x)
#endif
#endif

/******************** code copied from dint.h and pow.[ch] *******************/

Expand Down
2 changes: 2 additions & 0 deletions src/binary64/sin/sin.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ SOFTWARE.

#pragma STDC FENV_ACCESS ON

#if defined(_MSC_VER)
#ifndef __builtin_clzl
#define __builtin_clzl(x) __lzcnt64(x)
#endif
Expand All @@ -61,6 +62,7 @@ SOFTWARE.
#ifndef __builtin_floor
#define __builtin_floor(x) std::floor(x)
#endif
#endif

/******************** code copied from dint.h and pow.[ch] *******************/

Expand Down

0 comments on commit e47f51c

Please sign in to comment.