Skip to content

Commit cfdefc6

Browse files
authored
Include struct name in formatted input-field index (#819)
1 parent 7bfeebe commit cfdefc6

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/input/input_field.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use std::marker::PhantomData;
33
use std::sync::Arc;
44

55
use crate::function::VerifyResult;
6-
use crate::ingredient::{fmt_index, Ingredient};
6+
use crate::ingredient::Ingredient;
77
use crate::input::{Configuration, IngredientImpl, Value};
88
use crate::table::memo::MemoTableTypes;
99
use crate::zalsa::IngredientIndex;
@@ -61,7 +61,13 @@ where
6161
}
6262

6363
fn fmt_index(&self, index: crate::Id, fmt: &mut fmt::Formatter<'_>) -> fmt::Result {
64-
fmt_index(C::FIELD_DEBUG_NAMES[self.field_index], index, fmt)
64+
write!(
65+
fmt,
66+
"{input}.{field}({id:?})",
67+
input = C::DEBUG_NAME,
68+
field = C::FIELD_DEBUG_NAMES[self.field_index],
69+
id = index
70+
)
6571
}
6672

6773
fn debug_name(&self) -> &'static str {

0 commit comments

Comments
 (0)