0
Fork 0
mirror of https://codeberg.org/ziglang/zig synced 2026-11-18 07:05:05 +00:00
zig/lib
Andrew Kelley 3264abe3d8 stage2: fixes for error union semantics
* Sema: avoid unnecessary safety checks when an error set is empty.
 * Sema: make zirErrorToInt handle comptime errors that are represented
   as integers.
 * Sema: make empty error sets properly integrate with
   typeHasOnePossibleValue.
 * Type: correct the ABI alignment and size of error unions which have
   both zero-bit error set and zero-bit payload. The previous code did
   not account for the fact that we still need to store a bit for
   whether there is an error.
 * LLVM: lower error unions possibly with the payload first or with the
   error code first, depending on alignment. Previously it always put
   the error code first and used a padding array.
 * LLVM: lower functions which have an empty error set as the return
   type the same as anyerror, so that they can be used where
   fn()anyerror function pointers are expected. In such functions, Zig
   will lower ret to returning zero instead of void.

As a result, one more behavior test is passing.
History 2022-05-24 15:34:52 -07:00
..
compiler_rt Simplify Copysign 2022-05-17 21:55:22 +01:00
docs flatten lib/std/special and improve "pkg inside another" logic 2022-05-06 22:41:00 -07:00
include update libcxx, libcxxabi, and C headers to release/13.x branch 2021-08-28 13:11:47 -07:00
init-exe init-exe: add note about log_level in ReleaseSmall and ReleaseFast build mode (#11626) 2022-05-14 12:56:58 +02:00
init-lib flatten lib/std/special and improve "pkg inside another" logic 2022-05-06 22:41:00 -07:00
libc Set macOS/iPhoneOS/tvOS/watchOS ABI to none (unspecified) by default 2022-05-22 17:45:02 +02:00
libcxx update libcxx, libcxxabi, and C headers to release/13.x branch 2021-08-28 13:11:47 -07:00
libcxxabi update libcxx, libcxxabi, and C headers to release/13.x branch 2021-08-28 13:11:47 -07:00
libunwind Import SPARCv9 libunwind 2022-02-13 17:16:22 +02:00
std stage2: fixes for error union semantics 2022-05-24 15:34:52 -07:00
tsan update libcxx, libcxxabi, libunwind, and tsan to llvm 13 rc1 2021-08-16 23:32:13 -07:00
build_runner.zig flatten lib/std/special and improve "pkg inside another" logic 2022-05-06 22:41:00 -07:00
c.zig target: Rename sparcv9 -> sparc64 2022-05-13 16:43:59 -04:00
compiler_rt.zig stage2: add runtime safety for unwrapping error 2022-05-16 17:42:51 -07:00
ssp.zig flatten lib/std/special and improve "pkg inside another" logic 2022-05-06 22:41:00 -07:00
test_runner.zig zig test: Add proper detection for Windows console 2022-05-17 14:22:10 +03:00