authorgravatar for leroycepearson@geemili.xyzLeRoyce Pearson <leroycepearson@geemili.xyz> 2020-03-06 21:59:58-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2020-05-25 13:48:43-04:00
loge75a6e514444849ca32de88511804c888137b9a1
tree73c92fb5c3f31c09e06b7219a41a99d8aca56145
parent50cbf1f3aa636badec64bcd6d1905cd3c8d67c16

Rename `cache_file` -> `addFile`


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

lib/std/cache_hash.zig+3-3
......@@ -117,7 +117,7 @@ pub const CacheHash = struct {
117117 }
118118 }
119119
120 pub fn cache_file(self: *@This(), file_path: []const u8) !void {
120 pub fn addFile(self: *@This(), file_path: []const u8) !void {
121121 debug.assert(self.manifest_file == null);
122122
123123 var cache_hash_file = try self.files.addOne();
......@@ -344,7 +344,7 @@ test "cache file and the recall it" {
344344 ch.add(true);
345345 ch.add(@as(u16, 1234));
346346 ch.add("1234");
347 try ch.cache_file("test.txt");
347 try ch.addFile("test.txt");
348348
349349 // There should be nothing in the cache
350350 debug.assert((try ch.hit(&digest1)) == false);
......@@ -358,7 +358,7 @@ test "cache file and the recall it" {
358358 ch.add(true);
359359 ch.add(@as(u16, 1234));
360360 ch.add("1234");
361 try ch.cache_file("test.txt");
361 try ch.addFile("test.txt");
362362
363363 // Cache hit! We just "built" the same file
364364 debug.assert((try ch.hit(&digest2)) == true);