Closed prabhpreet closed 3 months ago
I would prefer if we just completely replaced the
derive_*
fields and replaced them with these*_attributes
fields instead. Having them spread across different implementations seems messy.
I agree this is better, I'll remove the derive_*
fields, will be a breaking change
Alternatively, are there some common-sense attributes that you think should be applied to states/events?
My motivation was to customize the structs when serializing using serde. Since this is also targeted towards no_std
, maybe it is better for the users to decide?
Breaking changes are fine. We've done lots of them recently, and I try to release as often as required :) The migration tends to be quite easy.
@ryan-summers Made the changes including tests, and docs, please feel free to review/edit
Use
states_attr
andevents_attr
to add custom attributes (eg. #[allow(...)])Example: