From 4c75f834e7195d05ca4f358aa093003e60380be7 Mon Sep 17 00:00:00 2001 From: joachimschmidt557 Date: Tue, 25 May 2021 10:34:02 +0800 Subject: Re-enable building the self-hosted compiler for 32-bit targets --- src/main.zig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/main.zig') diff --git a/src/main.zig b/src/main.zig index 4b8f30b109..455f19cccc 100644 --- a/src/main.zig +++ b/src/main.zig @@ -3642,7 +3642,7 @@ pub fn cmdAstCheck( if (stat.size > max_src_size) return error.FileTooBig; - const source = try arena.allocSentinel(u8, stat.size, 0); + const source = try arena.allocSentinel(u8, @intCast(usize, stat.size), 0); const amt = try f.readAll(source); if (amt != stat.size) return error.UnexpectedEndOfFile; @@ -3778,7 +3778,7 @@ pub fn cmdChangelist( .root_decl = null, }; - const source = try arena.allocSentinel(u8, stat.size, 0); + const source = try arena.allocSentinel(u8, @intCast(usize, stat.size), 0); const amt = try f.readAll(source); if (amt != stat.size) return error.UnexpectedEndOfFile; @@ -3818,7 +3818,7 @@ pub fn cmdChangelist( if (new_stat.size > max_src_size) return error.FileTooBig; - const new_source = try arena.allocSentinel(u8, new_stat.size, 0); + const new_source = try arena.allocSentinel(u8, @intCast(usize, new_stat.size), 0); const new_amt = try new_f.readAll(new_source); if (new_amt != new_stat.size) return error.UnexpectedEndOfFile; -- cgit v1.2.3