alexcrichton transferred Issue #544:
The verifier functions have an API that could probably be simplified. Functions which return
VerifierStepResultmust by convention also take an out-paramVerifierErrorsthat will contain non-fatal errors.Moreover, the
TinVerifierStepResult<T>seems to always be set to(), so it's unused.It seems the out param is redundant with the error that's present in the
ResulthiddenVerifierStepResult. I think slightly modifying the interface ofVerifierStepResultwould avoid this out param:
- let the
Oktype beVerifierErrors, in case we only have non-fatal errors (they could be called "warnings").- let the
Errtype stay the same (VerifierErrorstoo), and contain non-fatal and fatal errors, if there was at least one fatal error.Then we wouldn't need the
errorsoutparam anymore, which looks cleaner and "more Rusty". It might mean that a few users of thefatal!etc macros would need to have their ownerrorsvariable, but that seems OK.Thoughts?
Last updated: Dec 06 2025 at 06:05 UTC