Browse Source

Use `__clang__` as identifying mark of `clang` insted of `USECLANG`

Elliot Saba 9 năm trước cách đây
mục cha
commit
9c45e36809
2 tập tin đã thay đổi với 2 bổ sung7 xóa
  1. 0 5
      test/Makefile
  2. 2 2
      test/libm-test.c

+ 0 - 5
test/Makefile

@@ -11,11 +11,6 @@ all: test-double test-float # test-double-system test-float-system
 
 bench: bench-syslibm bench-openlibm
 
-ifeq ($(USECLANG),1)
-CPPFLAGS += -DUSECLANG=1
-endif
-
-
 test-double: test-double.c libm-test.c libm-test-ulps.h
 	$(CC) $(CPPFLAGS) $(CFLAGS) $(CFLAGS_add_TARGET_$(ARCH)) $(LDFLAGS) [email protected] -D__BSD_VISIBLE -I ../include -I../src $(OPENLIBM_LIB) -o $@
 

+ 2 - 2
test/libm-test.c

@@ -410,7 +410,7 @@ test_single_exception (const char *test_name,
 {
 /* Don't perform these checks if we're compiling with clang, because clang
    doesn't bother to set floating-point exceptions properly */
-#ifndef USECLANG
+#ifndef __clang__
 #ifndef TEST_INLINE
   int ok = 1;
   if (exception & exc_flag)
@@ -448,7 +448,7 @@ test_single_exception (const char *test_name,
     ++noErrors;
 
 #endif
-#endif // USECLANG
+#endif // __clang__
 }