zig
zig copied to clipboard
General-purpose programming language and toolchain for maintaining robust, optimal, and reusable software.
This PR implements `std.debug.walkStackWindows` as a replacement for `RtlCaptureStackBackTrace`. ### Context As part of debugging #12703 I was investigating why stack traces weren't appearing, and realized a simple test program...
* [ ] compile error for unused non-pub global variable * [x] compile error for unused local variable * [ ] compile error for unused non-pub function decl * [...
``` LLVM ERROR: Cannot select: 0x7fbada5323a8: v8f16,ch = X86ISD::VBROADCAST_LOAD 0x7fbae24e8678, 0x7fbae36d3cd0, behavior/vector.zig:252:18 @[ behavior/vector.zig:261:25 @[ behavior/vector.zig:283:20 ] ] 0x7fbae36d3cd0: i64 = X86ISD::WrapperRIP TargetConstantPool:i64 0 0x7fbae36d36f8: i64 = TargetConstantPool 0 In...
Closes #12821. Note: stage1 still does this.
Currently depends on #12807 to free up two Zir instruction slots, only the last commit is relevant to this PR. Example: ```zig const std = @import("std"); test { return error.SkipZigTest;...
Closes https://github.com/ziglang/zig/issues/12805
### Zig Version 0.10.0-dev.3844+f7784a081 ### Steps to Reproduce 1. Create `read-input.zig` file, in an empty folder, with these contents: ```zig const std = @import("std"); pub fn main() !void { var...
### Zig Version 0.10.0-dev.3981+60678f5ba ### Steps to Reproduce ```zig const std = @import("std"); pub fn main() void { // add explicit type annotation, like // `std.meta.Tuple(&.{ u7, u7, u7, u7...
Many parts of `std` still use stage1-style function pointers. This PR removes all instances of this, replacing them with the use of `std.meta.FnPtr`. Additionally, manually-written `if` statements have been replaced...