4 ms·
What I do instead (given the excellent sibling replies about how it's not that simple) is store the value in a `u64` and then provide a method to decode it into
by Rusky 8y ago
What I do instead (given the excellent sibling replies about how it's not that simple) is store the value in a `u64` and then provide a method to decode it into a non-layout-optimized enum. Since that enum is not stored anywhere but the stack, it can be optimized out if the decoding is inlined: https://github.com/rpjohnst/dejavu/blob/a768ce515b3a110542aacb7f8560c627b8c6be0e/src/vm/value.rs https://github.com/rpjohnst/dejavu/blob/a768ce515b3a110542aa...