Open seanyoung opened 1 year ago
Maybe relevant, I've tried to formalize the Serde/Rust type model and bincode serialization format here: https://github.com/solana-foundation/specs/pull/17
+1 to this as many programs are moving to a mixture of borsh and parts of the account that are zero copy
The serialization types I have used or seen in the wild are: Message Pack Flatbuffers Bebop Borsh POD(bytemuck) Bincode Mixture of POD and Borsh usually with a borsh header
spl_token uses bincode for serialization. We should have a field for serialization format. The default should be borsh.
I would like to avoid proliferation of serialization formats. Each new format will require work for each support language (both on-chain and client side).
People love to invent new serialization formats though.