zig
zig copied to clipboard
General-purpose programming language and toolchain for maintaining robust, optimal, and reusable software.
### Zig Version 0.10.0-dev.1261+6f986298c ### Steps to Reproduce ```zig const std = @import("std"); pub fn main() !void { var value: u4 = undefined; std.debug.print("u4={}, usize={}\n", .{ value, @as(usize, value), });...
### Zig Version 0.9.1 ### Steps to Reproduce Unpack this project, and run make: [Test.zip](https://github.com/ziglang/zig/files/8354489/Test.zip) ### Expected Behavior On 0.9.0, the result is a .elf file with a symbol table...
### Zig Version zig-bin-0.9.1 ### Steps to Reproduce Best on live example ``` >>> Emerging (1 of 2) sys-fs/ncdu-2.1::core-kit * Fetching files in the background. * To view fetch progress,...
### Zig Version 0.10.0-dev.1434+676652865 ### Steps to Reproduce I am running [Linux on a MacBook Pro](https://asahilinux.org/) which uses 16 KiB pages; however, Zig's std lib always assumes 4 KiB pages...
### Zig Version 0.9.1 ### Steps to Reproduce 1. code `main.zig`: ```zig const std = @import("std"); const StreamServer = std.net.StreamServer; const Address = std.net.Address; pub fn main() anyerror!void { var...
### Zig Version 0.10.0-dev.1736+93e11b824 ### Steps to Reproduce zig cc -fsanitize=address hello.c Tried on "Apple M1 Pro macOS Monterey 12.3.1" as well as "Intel Core i7 macOS Catalina 10.15.7" ###...
Currently, creating dynamically-sized containers with initial values can be verbose enough to distract from the business logic of the code Literal values of `[]u32` -> `struct { bar: ArrayList(u32) }`...
Hi, I am using zig to cross compile a go module (go-fitz) on my Mac. The compiler options used are as below : `GOOS=linux GOARCH=amd64 CGO_ENABLED=1 CC="zig cc -target x86_64-linux"...
### Zig Version 0.10.0-dev.2981+7090f0471 ### Steps to Reproduce ndk version 24. ```sh zig cc -target aarch64-linux-android --sysroot=/ndk/toolchains/llvm/prebuilt/darwin-x86_64/sysroot -I/ndk/toolchains/llvm/prebuilt/darwin-x86_64/sysroot/usr/include -Iinclude -c utf8_range/range2-neon.c -o range2-neon.c.o ``` ### Expected Behavior expect it work...
Hello, I'm getting a segfault when executing the following trivial program: ```zig const std = @import("std"); const stdout = std.io.getStdOut().writer(); extern fn add(a: c_int, b: c_int) c_int; pub fn main()...