Skip to content

Commit 53623d5

Browse files
committed
Merge branch 'main-dev' of https://github.com/ashvardanian/StringZilla into main-dev
2 parents 9b8c466 + 78bbc11 commit 53623d5

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

include/stringzilla/find.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -311,13 +311,17 @@ SZ_PUBLIC sz_cptr_t sz_find_byteset_serial(sz_cptr_t text, sz_size_t length, sz_
311311
}
312312

313313
SZ_PUBLIC sz_cptr_t sz_rfind_byteset_serial(sz_cptr_t text, sz_size_t length, sz_byteset_t const *set) {
314+
#if !defined(_MSC_VER)
314315
#pragma GCC diagnostic push
315316
#pragma GCC diagnostic ignored "-Warray-bounds"
317+
#endif
316318
sz_cptr_t const end = text;
317319
for (text += length; text != end;)
318320
if (sz_byteset_contains(set, *(text -= 1))) return text;
319321
return SZ_NULL_CHAR;
322+
#if !defined(_MSC_VER)
320323
#pragma GCC diagnostic pop
324+
#endif
321325
}
322326

323327
/* Find the first occurrence of a @b single-character needle in an arbitrary length haystack.

include/stringzilla/types.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -990,9 +990,11 @@ SZ_PUBLIC void sz_sequence_from_null_terminated_strings(sz_cptr_t *start, sz_siz
990990

991991
#pragma region Helper Functions
992992

993+
#if !defined(_MSC_VER)
993994
#pragma GCC diagnostic push
994995
#pragma GCC diagnostic ignored "-Wconversion"
995996
#pragma GCC visibility push(hidden)
997+
#endif
996998

997999
/*
9981000
**********************************************************************************************************************
@@ -1246,6 +1248,7 @@ SZ_INTERNAL __mmask64 sz_u64_clamp_mask_until_(sz_size_t n) {
12461248
#pragma GCC pop_options
12471249
#endif
12481250
#endif
1251+
#endif
12491252

12501253
/**
12511254
* @brief Byte-level equality comparison between two 64-bit integers.
@@ -1417,7 +1420,9 @@ SZ_INTERNAL void sz_memory_free_fixed_(sz_ptr_t start, sz_size_t length, void *h
14171420
sz_unused_(start && length && handle);
14181421
}
14191422

1423+
#if !defined(_MSC_VER)
14201424
#pragma GCC visibility pop
1425+
#endif
14211426
#pragma endregion
14221427

14231428
#pragma region Serial Implementation
@@ -1490,7 +1495,9 @@ SZ_PUBLIC void sz_sequence_from_null_terminated_strings(sz_cptr_t *start, sz_siz
14901495
#pragma endregion
14911496

14921497
#ifdef __cplusplus
1498+
#if !defined(_MSC_VER)
14931499
#pragma GCC diagnostic pop
1500+
#endif
14941501
}
14951502
#endif // __cplusplus
14961503

0 commit comments

Comments
 (0)