From 35b16e545b4fce299edbc00c9a9754179fa51634 Mon Sep 17 00:00:00 2001 From: Laurenz Date: Sat, 17 Dec 2022 16:24:29 +0100 Subject: Document parameters in comment --- src/model/func.rs | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) (limited to 'src/model/func.rs') diff --git a/src/model/func.rs b/src/model/func.rs index 5b38b700..46befd77 100644 --- a/src/model/func.rs +++ b/src/model/func.rs @@ -232,12 +232,21 @@ pub struct ParamInfo { pub name: &'static str, /// Documentation for the parameter. pub docs: &'static str, - /// Is the parameter settable with a set rule? - pub settable: bool, - /// Can the name be omitted? - pub shorthand: bool, /// Valid values for the parameter. pub cast: CastInfo, + /// Is the parameter positional? + pub positional: bool, + /// Is the parameter named? + /// + /// Can be true even if `positional` is true if the parameter can be given + /// in both variants. + pub named: bool, + /// Is the parameter required? + pub required: bool, + /// Can the parameter be given any number of times? + pub variadic: bool, + /// Is the parameter settable with a set rule? + pub settable: bool, } /// A user-defined closure. -- cgit v1.2.3