dtolnay / erased-serde

Type-erased Serialize, Serializer and Deserializer traits
Apache License 2.0
709 stars 36 forks source link

Can this library be used with `bincode`, `serder_yaml` and `avro_rs`? #26

Closed seladb closed 5 years ago

seladb commented 5 years ago

If I understand the documentation correctly, this library only works with serde libraries that have a Serializer object that implements the serde::ser::Serializer trait.

However in bincode, serder_yaml and avro_rs there are no such objects. Can this library be used with them?

dtolnay commented 5 years ago

Unfortunately it cannot... We require there to be a Serializer / Deserializer exposed publicly.

seladb commented 5 years ago

Thanks! Maybe I can open issues for these 3 libraries to expose this object. I'll close this issue now

seladb commented 5 years ago

BTW, for bincode there is already an open issue: https://github.com/TyOverby/bincode/issues/242

Apparently this is not easy for them to implement that without impacting on performance.

There is also an open issue for serde_yaml: https://github.com/dtolnay/serde-yaml/issues/44