-
-
Notifications
You must be signed in to change notification settings - Fork 7
Description
One thing which might be worth thinking about is whether the difference in data model allow deser to implement Spanned,
In the following comment dtolnay says serde's model is not necessarily byte oriented.
serde-rs/serde#1811 (comment)
if deser's model is, perhaps it could be worth including.
A few serde serializer/deserializer implementations implement it directly.
https://crates.io/crates/json-spanned-value
https://docs.rs/toml/latest/toml/struct.Spanned.html
But even with these, there are for instance odd interactions with Default.
Presumably a span for a default element could be one of None for an optional span type, or alternately the Span of any enclosing element?
Anyhow, it seemed worth thinking about perhaps, but doesn't seem to be essential.