authorgravatar for sage@sagehane.comSage Hane <sage@sagehane.com> 2021-05-05 04:18:34+09:00
committergravatar for sage@sagehane.comSage Hane <sage@sagehane.com> 2021-05-05 04:19:08+09:00
log975cb9e9a9d4386b73c141459331a3f08904a46e
tree456b04d9b2c8e2085cee4801d083602f4d21f3f5
parent6490e571365ee9f9a6afc1236adae414cb93ae1e
signaturelock-open Commit is signed but in an unrecognized format.

std.zig: make the unrecognized C flag case non-fatal


1 files changed, 3 insertions(+), 4 deletions(-)

lib/std/zig/system.zig+3-4
......@@ -46,9 +46,6 @@ pub const NativePaths = struct {
4646 var it = mem.tokenize(nix_cflags_compile, " ");
4747 while (true) {
4848 const word = it.next() orelse break;
49 if (mem.startsWith(u8, word, "-frandom-seed=")) {
50 continue;
51 }
5249 if (mem.eql(u8, word, "-isystem")) {
5350 const include_path = it.next() orelse {
5451 try self.addWarning("Expected argument after -isystem in NIX_CFLAGS_COMPILE");
......@@ -56,8 +53,10 @@ pub const NativePaths = struct {
5653 };
5754 try self.addIncludeDir(include_path);
5855 } else {
56 if (mem.startsWith(u8, word, "-frandom-seed=")) {
57 continue;
58 }
5959 try self.addWarningFmt("Unrecognized C flag from NIX_CFLAGS_COMPILE: {s}", .{word});
60 break;
6160 }
6261 }
6362 } else |err| switch (err) {