Use case: WASM binary that depends on a Solana contract.
cargo build --target wasm32-wasip1
Leads to
error[E0512]: cannot transmute between types of different sizes, or dependently-sized types
--> invoke/src/instruction_stabilizer.rs:121:32
|
121 | accounts: unsafe { core::mem::transmute(accounts) },
| ^^^^^^^^^^^^^^^^^^^^
|
= note: source type: `instruction_stabilizer::StableVec<AccountMeta>` (96 bits)
= note: target type: `solana_program::solana_stable_layout::stable_vec::StableVec<AccountMeta>` (192 bits)
The reason seems to be that solana_stable_layout::stable_vec::StableVec uses u64 instead of usize since 2.2.0.
Use case: WASM binary that depends on a Solana contract.
Leads to
The reason seems to be that
solana_stable_layout::stable_vec::StableVecusesu64instead ofusizesince 2.2.0.