fix build with clang 8

This commit is contained in:
daan 2020-02-13 20:34:35 -08:00
parent 3b08f585bb
commit f0aca8abcd
2 changed files with 9 additions and 10 deletions

View File

@ -99,7 +99,7 @@ extern "C" {
#ifdef NDEBUG
#define mi_declx(tp,name,attrs,...) mi_decl_export tp name(__VA_ARGS__) attrs
#define mi_declx(tp,name,attrs,...) tp name(__VA_ARGS__) attrs
#else
typedef struct mi_source_s {
@ -581,4 +581,3 @@ template<class T1, class T2> bool operator!=(const mi_stl_allocator<T1>&, const
#endif // MIMALLOC_H

View File

@ -465,7 +465,7 @@ bool _mi_free_delayed_block(mi_block_t* block) {
}
// Bytes available in a block
inline size_t mi_usable_size(const void* p) mi_attr_noexcept {
size_t mi_usable_size(const void* p) mi_attr_noexcept {
if (p==NULL) return 0;
const mi_segment_t* const segment = _mi_ptr_segment(p);
const mi_page_t* const page = _mi_segment_page_of(segment, p);