From f968d56d96989d1c74664449f509d7d1b2e3010f Mon Sep 17 00:00:00 2001 From: Jimmi Holst Christensen Date: Wed, 14 Nov 2018 14:25:42 +0100 Subject: Added pub flag/option/positional init funcs to Param --- example/comptime-clap.zig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'example/comptime-clap.zig') diff --git a/example/comptime-clap.zig b/example/comptime-clap.zig index e44d9b1..3b7b42b 100644 --- a/example/comptime-clap.zig +++ b/example/comptime-clap.zig @@ -17,12 +17,12 @@ pub fn main() !void { // * A "Names" struct, which determins what names the parameter will have on the // commandline. Names.prefix inits a "Names" struct that has the "short" name // set to the first letter, and the "long" name set to the full name. - clap.Param(void).init({}, false, clap.Names.prefix("help")), - clap.Param(void).init({}, true, clap.Names.prefix("number")), + clap.Param(void).flag({}, clap.Names.prefix("help")), + clap.Param(void).option({}, clap.Names.prefix("number")), // Names.positional returns a "Names" struct where neither the "short" or "long" // name is set. - clap.Param(void).init({}, true, clap.Names.positional()), + clap.Param(void).positional({}), }; // We then initialize an argument iterator. We will use the OsIterator as it nicely -- cgit v1.2.3