about summary refs log tree commit diff
path: root/src/libstd
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2013-04-22 11:09:50 -0700
committerbors <bors@rust-lang.org>2013-04-22 11:09:50 -0700
commit8205f73ce6201c4cf2780df04ea4ffb1949bbe9b (patch)
tree3d65545b4607f66b70812622324a1eaf5f999928 /src/libstd
parentaee2567eca278c0632de09138977aa13ad0f46fd (diff)
parentedc1324e7e665080e6695625ba6a5ede3e32f5a8 (diff)
downloadrust-8205f73ce6201c4cf2780df04ea4ffb1949bbe9b.tar.gz
rust-8205f73ce6201c4cf2780df04ea4ffb1949bbe9b.zip
auto merge of #6001 : jld/rust/enum-nullable, r=pcwalton
Specifically: all enums with two variants, where one has zero size (and thus at most one inhabitant) and the other has a field where the null value would not be allowed (such as a safe pointer), are now represented by storing a null pointer in the field in question.

This is a generalization of representing `Option<~T>`, `Option<@T>`, and `Option<&T>` with nullable pointers, thus fixing Tony Hoare's “billion dollar mistake”.
Diffstat (limited to 'src/libstd')
0 files changed, 0 insertions, 0 deletions