We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ab95f8f commit cc96f37Copy full SHA for cc96f37
registry/src/lib.rs
@@ -37,7 +37,7 @@ impl<R: 'static> Registry<R> {
37
pub fn add<I: Registrant<R> + 'static>(&mut self) {
38
let data = Arc::new(RegistrantData {
39
names: I::names(),
40
- argct: I::argct(),
+ argct: I::Args::argct(),
41
help_meta: I::help_meta(),
42
help_msg: I::help_msg(),
43
init: Box::new(I::init),
@@ -196,10 +196,6 @@ pub trait Registrant<R> {
196
197
fn init2(a: <Self::Args as RegistryArgs>::Val) -> R;
198
199
- fn argct() -> usize {
200
- return Self::Args::argct();
201
- }
202
-
203
fn init(args: &[&str]) -> ValidationResult<R> {
204
return Result::Ok(Self::init2(Self::Args::parse(args)?));
205
}
0 commit comments