CI updates

This commit is contained in:
Markus F.X.J. Oberhumer
2025-04-09 11:32:13 +02:00
parent 071579b5b6
commit d23484b9db
7 changed files with 49 additions and 20 deletions
+2 -2
View File
@@ -413,10 +413,10 @@ constexpr bool mem_eq(const unsigned char *a, const unsigned char *b, std::size_
return n == 0 || (*a == *b && mem_eq(a + 1, b + 1, n - 1));
}
constexpr bool mem_eq(const char *a, const unsigned char *b, std::size_t n) noexcept {
return n == 0 || (*a == *b && mem_eq(a + 1, b + 1, n - 1));
return n == 0 || ((uchar) *a == *b && mem_eq(a + 1, b + 1, n - 1));
}
constexpr bool mem_eq(const unsigned char *a, const char *b, std::size_t n) noexcept {
return n == 0 || (*a == *b && mem_eq(a + 1, b + 1, n - 1));
return n == 0 || (*a == (uchar) *b && mem_eq(a + 1, b + 1, n - 1));
}
constexpr void mem_set(char *p, char c, std::size_t n) noexcept {
+20 -8
View File
@@ -34,14 +34,6 @@
#endif
#endif
// aligned_alloc() was added in glibc-2.16
#if !defined(_LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION) && defined(__cplusplus)
#if defined(__GLIBC__) && defined(__GLIBC_MINOR__) && (__GLIBC__ + 0 == 2) && \
(__GLIBC_MINOR__ + 0 > 0) && (__GLIBC_MINOR__ + 0 < 16)
#define _LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION
#endif
#endif // _LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION
// libc++ hardenining
#if defined(__cplusplus) && 0 // TODO later
@@ -65,4 +57,24 @@
#endif // TODO later
// aligned_alloc() was added in glibc-2.16
#if !defined(_LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION) && defined(__cplusplus)
#if defined(__GLIBC__) && defined(__GLIBC_MINOR__) && (__GLIBC__ + 0 == 2) && \
(__GLIBC_MINOR__ + 0 > 0) && (__GLIBC_MINOR__ + 0 < 16)
#define _LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION
#endif
#endif // _LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION
#if defined(_LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION) && defined(__cplusplus)
#if defined(__has_include)
#if __has_include(<__config>)
#include <__config>
#undef _LIBCPP_HAS_LIBRARY_ALIGNED_ALLOCATION
#undef _LIBCPP_HAS_ALIGNED_ALLOCATION
#define _LIBCPP_HAS_LIBRARY_ALIGNED_ALLOCATION 0
#define _LIBCPP_HAS_ALIGNED_ALLOCATION 0
#endif
#endif
#endif
/* vim:set ts=4 sw=4 et: */