Advisories for Cargo/Soroban-Sdk-Macros package

2026

The rs-soroban-sdk #[contractimpl] macro calls inherent function instead of trait function when names collide

The #[contractimpl] macro contains a bug in how it wires up function calls. In Rust, you can define functions on a type in two ways: Directly on the type as an inherent function: impl MyContract { fn value() { … } } Through a trait impl Trait for MyContract { fn value() { … } } These are two separate functions that happen to share the same name. Rust has …