From b10f2e4210f721a5ea9dc6a251b2f5cb4cdea11c Mon Sep 17 00:00:00 2001 From: Hanno Braun Date: Thu, 2 Jun 2022 17:44:41 +0200 Subject: [PATCH] Print label in `Handle`'s `Debug` implementation --- crates/fj-kernel/src/shape/stores.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/crates/fj-kernel/src/shape/stores.rs b/crates/fj-kernel/src/shape/stores.rs index 69c00c8aa..f69a2f66f 100644 --- a/crates/fj-kernel/src/shape/stores.rs +++ b/crates/fj-kernel/src/shape/stores.rs @@ -214,7 +214,10 @@ where T: fmt::Debug, { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { - f.debug_tuple("Handle").field(&self.get()).finish() + f.debug_struct("Handle") + .field("shape", &self.store.label.as_deref().unwrap_or("unnamed")) + .field("object", &self.get()) + .finish() } }