You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the LidoInstruction enum uses a generated borsh serializer. This makes it difficult to know for any external non-Rust program to parse the instruction bytes, which is an obstacle for e.g. block explorers to integrate.
It is possible to select a discriminant explicitly for each of the enum variants. This is a good idea anyway to have a stable interface across versions. At the moment it is only possible for enum variants without fields, and LidoInstruction does have a few variants with fields. However, from Rust 1.56 onwards this should be possible. We should investigate whether it’s possible to use that. Or maybe we should just write serializers by hand, or generate the enum with some IDL that can also generate serializers for other languages (similar to what Anchor does).
The text was updated successfully, but these errors were encountered:
Currently the
LidoInstruction
enum uses a generated borsh serializer. This makes it difficult to know for any external non-Rust program to parse the instruction bytes, which is an obstacle for e.g. block explorers to integrate.It is possible to select a discriminant explicitly for each of the enum variants. This is a good idea anyway to have a stable interface across versions. At the moment it is only possible for enum variants without fields, and
LidoInstruction
does have a few variants with fields. However, from Rust 1.56 onwards this should be possible. We should investigate whether it’s possible to use that. Or maybe we should just write serializers by hand, or generate the enum with some IDL that can also generate serializers for other languages (similar to what Anchor does).The text was updated successfully, but these errors were encountered: