Open Stargateur opened 3 years ago
I like the idea, but I am not sure on which level of abstraction this makes sense. I used this technique in another crate (imap-codec) and ended up with multiple string types e.g. IString, NString, Atom, ..., which were really useful, but created a lot boilerplate.
I think it is a powerful technique to increase the reliability of a library. But if we want to do that, I would propose to play around with it and see how well it works out. Maybe we could test how another library based on abnf-core, e.g., the abnf crate, would feel like using the typesafe variant?
Should we consider make the parser strongly typed:
Pro:
into_inner()
Con:
into_inner()
to get rid of the wrapper.Maybe as a feature ?