File tree Expand file tree Collapse file tree 1 file changed +11
-9
lines changed Expand file tree Collapse file tree 1 file changed +11
-9
lines changed Original file line number Diff line number Diff line change @@ -638,17 +638,19 @@ impl fmt::Display for Error {
638638 }
639639}
640640
641- #[ cfg( any ( feature = "std" , test ) ) ]
641+ #[ cfg( feature = "std" ) ]
642642impl std:: error:: Error for Error {
643- fn description ( & self ) -> & str {
643+ fn source ( & self ) -> Option < & ( dyn std:: error:: Error + ' static ) > {
644+ use self :: Error :: * ;
645+
644646 match * self {
645- Error :: MissingSeparator => "missing human-readable separator" ,
646- Error :: InvalidChecksum => "invalid checksum" ,
647- Error :: InvalidLength => "invalid length" ,
648- Error :: InvalidChar ( _) => "invalid character" ,
649- Error :: InvalidData ( _ ) => "invalid data point" ,
650- Error :: InvalidPadding => "invalid padding" ,
651- Error :: MixedCase => "mixed-case strings not allowed" ,
647+ MissingSeparator
648+ | InvalidChecksum
649+ | InvalidLength
650+ | InvalidChar ( _)
651+ | InvalidData ( _ )
652+ | InvalidPadding
653+ | MixedCase => None
652654 }
653655 }
654656}
You can’t perform that action at this time.
0 commit comments