We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8f29948 commit dd6466bCopy full SHA for dd6466b
src/client/legacy/client.rs
@@ -52,7 +52,6 @@ struct Config {
52
}
53
54
/// Client errors
55
-#[derive(Debug)]
56
pub struct Error {
57
kind: ErrorKind,
58
source: Option<Box<dyn StdError + Send + Sync>>,
@@ -1566,6 +1565,17 @@ impl fmt::Debug for Builder {
1566
1565
1567
// ==== impl Error ====
1568
+impl fmt::Debug for Error {
1569
+ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1570
+ let mut f = f.debug_tuple("hyper_util::client::legacy::Error");
1571
+ f.field(&self.kind);
1572
+ if let Some(ref cause) = self.cause {
1573
+ f.field(cause);
1574
+ }
1575
+ f.finish()
1576
1577
+}
1578
+
1579
impl fmt::Display for Error {
1580
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1581
write!(f, "client error ({:?})", self.kind)
0 commit comments