From 5a0681948baea7277b8d3418a4fe2ba134559559 Mon Sep 17 00:00:00 2001 From: Chris Boesch Date: Wed, 2 Aug 2023 23:29:02 +0200 Subject: changed struct name 'class' into 'role' --- exercises/038_structs2.zig | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'exercises/038_structs2.zig') diff --git a/exercises/038_structs2.zig b/exercises/038_structs2.zig index af7eb1f..b9d84aa 100644 --- a/exercises/038_structs2.zig +++ b/exercises/038_structs2.zig @@ -8,7 +8,7 @@ // const std = @import("std"); -const Class = enum { +const Role = enum { wizard, thief, bard, @@ -16,7 +16,7 @@ const Class = enum { }; const Character = struct { - class: Class, + role: Role, gold: u32, health: u8, experience: u32, @@ -27,7 +27,7 @@ pub fn main() void { // Glorp the Wise chars[0] = Character{ - .class = Class.wizard, + .role = Role.wizard, .gold = 20, .health = 100, .experience = 10, @@ -35,7 +35,7 @@ pub fn main() void { // Please add "Zump the Loud" with the following properties: // - // class bard + // role bard // gold 10 // health 100 // experience 20 -- cgit v1.2.3-70-g09d2