std.builtin.returnError: disable runtime safety

This commit is contained in:
Andrew Kelley 2022-07-07 17:45:28 -07:00
parent cbc85f4516
commit e5e9e5a7aa

View File

@ -858,6 +858,7 @@ pub fn panicOutOfBounds(index: usize, len: usize) noreturn {
pub noinline fn returnError(maybe_st: ?*StackTrace) void {
@setCold(true);
@setRuntimeSafety(false);
const st = maybe_st orelse return;
addErrRetTraceAddr(st, @returnAddress());
}