From be3677216a472b0d87abbf80f4d5eba5ed053f8b Mon Sep 17 00:00:00 2001 From: Archbirdplus Date: Mon, 15 Jul 2024 01:29:11 -0700 Subject: [PATCH] page size: fix failure to implicitly cast slice All that changed was that I turned a slice of page_size length to pageSize() length. I'm not sure why Zig fails to implicitly cast the pageSize() length slice now, but an explicit cast should fix this. --- lib/std/debug.zig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/std/debug.zig b/lib/std/debug.zig index 8795586bbe78..f8ae954063cd 100644 --- a/lib/std/debug.zig +++ b/lib/std/debug.zig @@ -689,7 +689,7 @@ pub const StackIterator = struct { // The only error this function can throw is ERROR_INVALID_PARAMETER. // supply an address that invalid i'll be thrown. - const rc = windows.VirtualQuery(aligned_memory, &memory_info, aligned_memory.len) catch { + const rc = windows.VirtualQuery(@ptrCast(aligned_memory), &memory_info, aligned_memory.len) catch { return false; };