2 ms·
It's impossible for Option<T> to be the same size as T. Option is a tagged enum, where will the tag go?
by tathisit 5y ago
It's impossible for Option<T> to be the same size as T. Option is a tagged enum, where will the tag go?
- agolliver 5y agoLooks like it's only true for pointer types which cannot be null (so they can reuse null as the None tag) https://doc.rust-lang.org/std/option/ https://doc.rust-lang.org/std/option/