diff options
| author | bors <bors@rust-lang.org> | 2020-11-04 14:26:03 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2020-11-04 14:26:03 +0000 |
| commit | 75f1db1102076e416e1154b241b4fc95c01c0d7b (patch) | |
| tree | da3aff37cbe521b14bfc86b1cdb3cab26ceb3b95 /compiler/rustc_error_codes/src | |
| parent | 601c13c6fda6a7db423c974797e36c79a9a0c0ac (diff) | |
| parent | 332750f9ebea6ff8a20b020772b60ccac637982e (diff) | |
| download | rust-75f1db1102076e416e1154b241b4fc95c01c0d7b.tar.gz rust-75f1db1102076e416e1154b241b4fc95c01c0d7b.zip | |
Auto merge of #77227 - oli-obk:const_val_🌳_prelude, r=RalfJung
Refactorings in preparation for const value trees
cc #72396
This PR changes the `Scalar::Bits { data: u128, size: u8 }` variant to `Scalar::Bits(ScalarInt)` where `ScalarInt` contains the same information, but is `repr(packed)`. The reason for using a packed struct is to allow enum variant packing to keep the original size of `Scalar` instead of adding another word to its size due to padding.
Other than that the PR just gets rid of all the inspection of the internal fields of `Scalar::Bits` which were frankly scary. These fields have invariants that we need to uphold and we can't do that without making the fields private.
r? `@ghost`
Diffstat (limited to 'compiler/rustc_error_codes/src')
0 files changed, 0 insertions, 0 deletions
