From 7679f93f688452b2236d20b49f92569b8d56e20d Mon Sep 17 00:00:00 2001 From: Chris Boesch Date: Tue, 21 Nov 2023 15:01:22 +0100 Subject: Converted var to const if there is no mutation in var. This is checked from compiler version 0.12.0-dev.1664 --- exercises/055_unions.zig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'exercises/055_unions.zig') diff --git a/exercises/055_unions.zig b/exercises/055_unions.zig index 6339fc8..794f2df 100644 --- a/exercises/055_unions.zig +++ b/exercises/055_unions.zig @@ -53,8 +53,8 @@ const AntOrBee = enum { a, b }; pub fn main() void { // We'll just make one bee and one ant to test them out: - var ant = Insect{ .still_alive = true }; - var bee = Insect{ .flowers_visited = 15 }; + const ant = Insect{ .still_alive = true }; + const bee = Insect{ .flowers_visited = 15 }; std.debug.print("Insect report! ", .{}); -- cgit v1.2.3