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
A crate feature might not work, because features get merged. So if a crate A use scale-codec without this feature and B use A and scale-codec with the feature then A won't compile no?
Maybe a new optional attribute: codec::ensure_explicit_indices or codec::disallow_implicit_indices.
It will if done the way I suggest: by generating compile-time warning. Dependencies will compile just fine with warnings or not, but anything in crate/workspace will refuse to compile if warnings are denied in the project.
I think it would be valuable to make an enum variant index required in derived code.
The way to approach this might be to have a separate feature that would generate a compile-time warning when
#[codec(index = something)]
is missing.This is important in blockchain environment where some data structures can evolve over time and refactoring can accidentally break things.
The text was updated successfully, but these errors were encountered: