File tree Expand file tree Collapse file tree 3 files changed +5
-11
lines changed Expand file tree Collapse file tree 3 files changed +5
-11
lines changed Original file line number Diff line number Diff line change @@ -15,11 +15,7 @@ namespace LIBC_NAMESPACE_DECL {
1515namespace  cpp  {
1616
1717LIBC_INLINE constexpr  bool  is_constant_evaluated () {
18- #if  LIBC_HAS_BUILTIN(__builtin_is_constant_evaluated)
1918  return  __builtin_is_constant_evaluated ();
20- #else 
21-   return  false ;
22- #endif 
2319}
2420
2521} //  namespace cpp
Original file line number Diff line number Diff line change 1515#ifndef  LLVM_LIBC_SRC___SUPPORT_RPC_RPC_SERVER_H
1616#define  LLVM_LIBC_SRC___SUPPORT_RPC_RPC_SERVER_H 
1717
18+ #include  " src/__support/macros/properties/compiler.h" 
19+ 
1820//  Workaround for missing __has_builtin in < GCC 10.
1921#ifndef  __has_builtin
2022#define  __has_builtin (x ) 0 
2123#endif 
2224
2325//  Workaround for missing __builtin_is_constant_evaluated in < GCC 10.
24- #ifndef  __builtin_is_constant_evaluated
26+ //  Also this builtin is defined for GCC 9.
27+ #if  !(__has_builtin(__builtin_is_constant_evaluated) ||                        \
28+       (defined (LIBC_COMPILER_IS_GCC) && (LIBC_COMPILER_GCC_VER >= 900 )))
2529#define  __builtin_is_constant_evaluated (x ) 0 
2630#endif 
2731
Original file line number Diff line number Diff line change 4848#define  LIBC_PREFERED_TYPE (TYPE )
4949#endif 
5050
51- #ifndef  __has_builtin
52- #define  LIBC_HAS_BUILTIN (X ) 0 
53- #else 
54- #define  LIBC_HAS_BUILTIN (X ) __has_builtin(X)
55- #endif 
56- 
5751#endif  //  LLVM_LIBC_SRC___SUPPORT_MACROS_ATTRIBUTES_H
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments