| ... | ... | @@ -13,6 +13,7 @@ const mem = std.mem; |
| 13 | 13 | const fmt = std.fmt; |
| 14 | 14 | const Allocator = std.mem.Allocator; |
| 15 | 15 | const Compilation = @import("Compilation.zig"); |
| 16 | const log = std.log.scoped(.cache); |
| 16 | 17 | |
| 17 | 18 | /// Be sure to call `Manifest.deinit` after successful initialization. |
| 18 | 19 | pub fn obtain(cache: *const Cache) Manifest { |
| ... | ... | @@ -478,6 +479,7 @@ pub const Manifest = struct { |
| 478 | 479 | } |
| 479 | 480 | |
| 480 | 481 | fn populateFileHash(self: *Manifest, ch_file: *File) !void { |
| 482 | log.debug("populateFileHash {s}", .{ch_file.path.?}); |
| 481 | 483 | const file = try fs.cwd().openFile(ch_file.path.?, .{}); |
| 482 | 484 | defer file.close(); |
| 483 | 485 | |
| ... | ... | @@ -581,7 +583,7 @@ pub const Manifest = struct { |
| 581 | 583 | .target, .target_must_resolve, .prereq => {}, |
| 582 | 584 | else => |err| { |
| 583 | 585 | try err.printError(error_buf.writer()); |
| 584 | | std.log.err("failed parsing {s}: {s}", .{ dep_file_basename, error_buf.items }); |
| 586 | log.err("failed parsing {s}: {s}", .{ dep_file_basename, error_buf.items }); |
| 585 | 587 | return error.InvalidDepFile; |
| 586 | 588 | }, |
| 587 | 589 | } |
| ... | ... | @@ -593,7 +595,7 @@ pub const Manifest = struct { |
| 593 | 595 | .prereq => |bytes| try self.addFilePost(bytes), |
| 594 | 596 | else => |err| { |
| 595 | 597 | try err.printError(error_buf.writer()); |
| 596 | | std.log.err("failed parsing {s}: {s}", .{ dep_file_basename, error_buf.items }); |
| 598 | log.err("failed parsing {s}: {s}", .{ dep_file_basename, error_buf.items }); |
| 597 | 599 | return error.InvalidDepFile; |
| 598 | 600 | }, |
| 599 | 601 | } |