From cc5c413cfcad8efe8540a6d6a8afe9d80d86a273 Mon Sep 17 00:00:00 2001 From: Dave Gauer Date: Wed, 30 Jun 2021 19:55:18 -0400 Subject: methods not namespaced --- exercises/075_quiz8.zig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'exercises') diff --git a/exercises/075_quiz8.zig b/exercises/075_quiz8.zig index 14fab18..ff5e569 100644 --- a/exercises/075_quiz8.zig +++ b/exercises/075_quiz8.zig @@ -81,7 +81,7 @@ const TripItem = union(enum) { place: *const Place, path: *const Path, - fn print(self: TripItem) void { + fn printMe(self: TripItem) void { switch (self) { .place => |p| print("{s}", .{p.name}), .path => |p| print("--{}->", .{p.dist}), @@ -201,7 +201,7 @@ fn printTrip(trip: []?TripItem) void { while (i > 0) { i -= 1; if (trip[i] == null) continue; - trip[i].?.print(); + trip[i].?.printMe(); } print("\n", .{}); -- cgit v1.2.3-ZIG