zig

fork of https://codeberg.org/ziglang/zig
Log | Files | Refs | README | LICENSE

commit 59dd7a0fbd5c06b89eea965b5fbc3f25e3eb21db (tree)
parent 0aeeff0d9434b37bb870e192091a563fc2a8dfce
Author: George Thayamkery <george.thayamkery@gmail.com>
Date:   Thu, 30 May 2024 11:49:30 -0500

not android check on std.debug.getContext

have_getcontext must be false for android, this makes sure that
std.debug.getContext wont call the non-existant function (and thus hit a
compileError)

Diffstat:
Mlib/std/debug.zig | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/std/debug.zig b/lib/std/debug.zig @@ -228,8 +228,8 @@ pub fn relocateContext(context: *ThreadContext) void { }; } -pub const have_getcontext = @hasDecl(posix.system, "getcontext") and - native_os != .openbsd and native_os != .haiku and +pub const have_getcontext = native_os != .openbsd and native_os != .haiku and + !builtin.target.isAndroid() and (native_os != .linux or switch (builtin.cpu.arch) { .x86, .x86_64,