| author | |
| committer | |
| log | dc7608da973291aafb7a58f33eb65dc3389c123d |
| tree | ed48626044e19fc8b78e17bf37441d71eda78508 |
| parent | fc001110b4f4c271217ae6ce973c80a33925ca3b |
Avoids a compile error from start.zig:
	/home/kivikakk/zig/build/lib/zig/std/start.zig:265:28: error:
	expected type 'u8', found 'i8'
			 return result;
				 ^
	/home/kivikakk/zig/build/lib/zig/std/start.zig:265:28: note:
	unsigned 8-bit int cannot represent all possible signed 8-bit
	values
			 return result;1 files changed, 2 insertions(+), 2 deletions(-)
lib/std/start.zig+2-2| ... | ... | @@ -248,7 +248,7 @@ pub fn callMain() u8 { |
| 248 | 248 | return 0; |
| 249 | 249 | }, |
| 250 | 250 | .Int => |info| { |
| 251 | if (info.bits != 8) { | |
| 251 | if (info.bits != 8 or info.is_signed) { | |
| 252 | 252 | @compileError(bad_main_ret); |
| 253 | 253 | } |
| 254 | 254 | return root.main(); |
| ... | ... | @@ -264,7 +264,7 @@ pub fn callMain() u8 { |
| 264 | 264 | switch (@typeInfo(@TypeOf(result))) { |
| 265 | 265 | .Void => return 0, |
| 266 | 266 | .Int => |info| { |
| 267 | if (info.bits != 8) { | |
| 267 | if (info.bits != 8 or info.is_signed) { | |
| 268 | 268 | @compileError(bad_main_ret); |
| 269 | 269 | } |
| 270 | 270 | return result; |