From 9bff7f332b86a18ff2f34e5c59ebdad5336e9850 Mon Sep 17 00:00:00 2001 From: Komari Spaghetti Date: Sat, 17 Jul 2021 10:43:05 +0000 Subject: Use debug.print instead of deprecated debug.warn in examples fixes comment on #11 --- example/streaming-clap.zig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'example/streaming-clap.zig') diff --git a/example/streaming-clap.zig b/example/streaming-clap.zig index 5f7f219..9ed38dd 100644 --- a/example/streaming-clap.zig +++ b/example/streaming-clap.zig @@ -44,13 +44,13 @@ pub fn main() !void { }) |arg| { // arg.param will point to the parameter which matched the argument. switch (arg.param.id) { - 'h' => debug.warn("Help!\n", .{}), - 'n' => debug.warn("--number = {s}\n", .{arg.value.?}), + 'h' => debug.print("Help!\n", .{}), + 'n' => debug.print("--number = {s}\n", .{arg.value.?}), // arg.value == null, if arg.param.takes_value == .none. // Otherwise, arg.value is the value passed with the argument, such as "-a=10" // or "-a 10". - 'f' => debug.warn("{s}\n", .{arg.value.?}), + 'f' => debug.print("{s}\n", .{arg.value.?}), else => unreachable, } } -- cgit v1.2.3