ReviewOS

also looking at this

zig-utils/zig-regex

Migrate to zig 0.16

#5
Closed illya-laifu wants to merge zig-0.16-migrations into main
13 files +222 -239
tests/thread_safety.zigmodified+4-3
Changes to tests/thread_safety.zig
@@ -191,7 +191,8 @@ test "RegexCache basic operations" {
191191
192192test "thread-safe allocator with concurrent matching" {
193193 // Use thread-safe allocator for concurrent access
194 var gpa = std.heap.GeneralPurposeAllocator(.{ .thread_safe = true }){};
194 var gpa = std.heap.DebugAllocator(.{ .thread_safe = true }){};
195 // TODO: can use this for leak detection
195196 defer _ = gpa.deinit();
196197 const allocator = gpa.allocator();
197198
@@ -222,7 +223,7 @@ test "thread-safe allocator with concurrent matching" {
222223}
223224
224225test "concurrent matching different patterns" {
225 var gpa = std.heap.GeneralPurposeAllocator(.{ .thread_safe = true }){};
226 var gpa = std.heap.DebugAllocator(.{ .thread_safe = true }){};
226227 defer _ = gpa.deinit();
227228 const allocator = gpa.allocator();
228229
@@ -272,7 +273,7 @@ test "concurrent matching different patterns" {
272273}
273274
274275test "stress test: many threads many matches" {
275 var gpa = std.heap.GeneralPurposeAllocator(.{ .thread_safe = true }){};
276 var gpa = std.heap.DebugAllocator(.{ .thread_safe = true }){};
276277 defer _ = gpa.deinit();
277278 const allocator = gpa.allocator();
278279