File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -17,10 +17,12 @@ extern "C" {
17
17
# error "this header requires Py_BUILD_CORE define"
18
18
#endif
19
19
20
- #if defined(__clang__ ) || \
21
- (defined(__GNUC__ ) && \
22
- ((__GNUC__ >= 5 ) || (__GNUC__ == 4 ) && (__GNUC_MINOR__ >= 8 )))
23
- /* __builtin_bswap16() is available since GCC 4.8,
20
+ #if ((defined(__GNUC__ ) \
21
+ && ((__GNUC__ >= 5 ) || (__GNUC__ == 4 ) && (__GNUC_MINOR__ >= 8 ))) \
22
+ || (defined(__clang__ ) \
23
+ && (__clang_major__ >= 4 \
24
+ || (__clang_major__ == 3 && __clang_minor__ >= 2 ))))
25
+ /* __builtin_bswap16() is available since GCC 4.8 and clang 3.2,
24
26
__builtin_bswap32() is available since GCC 4.3,
25
27
__builtin_bswap64() is available since GCC 4.3. */
26
28
# define _PY_HAVE_BUILTIN_BSWAP
Original file line number Diff line number Diff line change
1
+ Fix ``pycore_bitutils.h `` header file to support old clang versions:
2
+ ``__builtin_bswap16() `` is not available in LLVM clang 3.0.
You can’t perform that action at this time.
0 commit comments