aboutsummaryrefslogtreecommitdiff
path: root/exercises
diff options
context:
space:
mode:
authorDave Gauer <dave@ratfactor.com>2021-06-30 19:55:18 -0400
committerDave Gauer <dave@ratfactor.com>2021-06-30 19:55:18 -0400
commitcc5c413cfcad8efe8540a6d6a8afe9d80d86a273 (patch)
treefe81b139f5c46f93b8ebe3b55f36d3c99d6de81d /exercises
parent7b37431b6bb5143dc82f1b1b95a3d5073e289404 (diff)
downloadziglings-cc5c413cfcad8efe8540a6d6a8afe9d80d86a273.tar.gz
ziglings-cc5c413cfcad8efe8540a6d6a8afe9d80d86a273.tar.bz2
ziglings-cc5c413cfcad8efe8540a6d6a8afe9d80d86a273.tar.xz
ziglings-cc5c413cfcad8efe8540a6d6a8afe9d80d86a273.zip
methods not namespaced
Diffstat (limited to 'exercises')
-rw-r--r--exercises/075_quiz8.zig4
1 files changed, 2 insertions, 2 deletions
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", .{});