Unify `general.Fallible`, `general.Optional` and `authenticationsystem.Response`
Several operations can fail, some of them for several reasons. Ad-Hoc error reporting isn't a scalable solution, so this should be made a sensible generic system.
TODO:
-
Fully Define a Sum Type / Tagged Union to represent Rusts's Error
, Haskell'sEither
, etc. Currently namedFallible
-
Do a bit more research about what name would be the most compatible, and if a plain struct does all we need.
-
-
Redefine Optional(T)
type asFallible(T, :Void)
because DRY?- (Should be backwards compatible since non-generic structs can be made generic as long as the original types aren't changed)
-
Research: Make the authentication Response
type contain aFallible
instead?- (Ok and Error type of Response both are
:group
because they may send last SASL data, still sensible to move?)
- (Ok and Error type of Response both are
-
Check all methods if they may fail in expected, consistent ways, move them to use Fallible Data types. - NOTE: Moving a field into a new group/union is a backwards-compatible change.
Edited by Nadja von Reitzenstein Čerpnjak