stage2 AArch64: implement errUnion{Err,Payload} for registers

This commit is contained in:
joachimschmidt557
2022-12-29 12:21:31 +08:00
committed by Joachim Schmidt
parent 34887cf136
commit 1caf56c5fb
6 changed files with 139 additions and 41 deletions

View File

@@ -175,7 +175,6 @@ test "while with optional as condition with else" {
test "while with error union condition" {
if (builtin.zig_backend == .stage2_x86_64) return error.SkipZigTest;
if (builtin.zig_backend == .stage2_aarch64) return error.SkipZigTest;
if (builtin.zig_backend == .stage2_sparc64) return error.SkipZigTest; // TODO
numbers_left = 10;
@@ -258,7 +257,6 @@ fn returnWithImplicitCastFromWhileLoopTest() anyerror!void {
}
test "while on error union with else result follow else prong" {
if (builtin.zig_backend == .stage2_aarch64) return error.SkipZigTest;
if (builtin.zig_backend == .stage2_sparc64) return error.SkipZigTest; // TODO
const result = while (returnError()) |value| {
@@ -268,7 +266,6 @@ test "while on error union with else result follow else prong" {
}
test "while on error union with else result follow break prong" {
if (builtin.zig_backend == .stage2_aarch64) return error.SkipZigTest;
if (builtin.zig_backend == .stage2_sparc64) return error.SkipZigTest; // TODO
const result = while (returnSuccess(10)) |value| {