3 ms·
The point is that you only have to do it once, when defining the object. Everything else then happens via the From and Into implementations, which the compiler
by zozbot234 3y ago
The point is that you only have to do it once, when defining the object. Everything else then happens via the From and Into implementations, which the compiler will generally be smart enough to inline. So it'll be just as efficient as working on the underlying u8.
- brigadier132 3y agoYou have to do it once for each subset of variants your state machine requires. Which if you enumerate them all is 2^N from implementations.