Function charSignedness [src]

Default signedness of char for the native C compiler for this target Note that char signedness is implementation-defined and many compilers provide an option to override the default signedness e.g. GCC's -funsigned-char / -fsigned-char

Prototype

pub fn charSignedness(target: Target) std.builtin.Signedness

Parameters

target: Target

Source

pub fn charSignedness(target: Target) std.builtin.Signedness { if (target.os.tag.isDarwin() or target.os.tag == .windows or target.os.tag == .uefi) return .signed; return switch (target.cpu.arch) { .arm, .armeb, .thumb, .thumbeb, .aarch64, .aarch64_be, .arc, .csky, .hexagon, .msp430, .powerpc, .powerpcle, .powerpc64, .powerpc64le, .s390x, .riscv32, .riscv64, .xcore, .xtensa, => .unsigned, else => .signed, }; }