- withdrawable -> unlocked
"withdrawable" was a bad name, since these funds - while unlocked -
are not necessarily withdrawable if the voter is currently engaged in
a vote.
- only_deposit -> only_unlocked
Locked funds are technically also deposited. Make it clearer that this
is talking about the unlocked parts of the funds on the account.
Previously the configure_voting_mint() instruction could only be run
once per index. Now it's allowed to call it again to change a mint's
parameters.
This will directly be useful for Mango, which will likely start out
configuring the MNGO voting mint without lockup vote scaling and then
later enable it, when the ui is ready.
- Make Registrar zero-copy. While it was using borsh for serialization,
the array of voting mint configs couldn't be serialized without
unaligned references.
- Reorganize all zero_copy fields such that switching to repr(C) would
not make a difference. (just for safety in case that happens)
- Add static asserts on the sizes of all account structs, so any changes
are visible very early.
- Add padding to structs that didn't have it yet.