about summary refs log tree commit diff
path: root/src/libsyntax/parse
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2018-08-22 11:11:14 +0000
committerbors <bors@rust-lang.org>2018-08-22 11:11:14 +0000
commit674ef668f13c52a1fadbf01b24d8da1e12d15e70 (patch)
treee3fec554d0ba8fb806e969928278e30f2663093a /src/libsyntax/parse
parent71a1ef181683615f1c8da5efb3d8617c0b743009 (diff)
parent4fec615ebf604cf7ef952770650d93ad5b7b784e (diff)
downloadrust-674ef668f13c52a1fadbf01b24d8da1e12d15e70.tar.gz
rust-674ef668f13c52a1fadbf01b24d8da1e12d15e70.zip
Auto merge of #53424 - RalfJung:miri-refactor, r=oli-obk
CTFE engine refactor

* Value gets renamed to `Operand`, so that now `interpret::{Place, Operand}` are the "dynamic" versions of `mir::{Place, Operand}`.
* `Operand` and `Place` share the data for their "stuff is in memory"-base in a new type, `MemPlace`. This also makes it possible to give some more precise types in other areas. Both `Operand` and `MemPlace` have methods available to project into fields (and other kinds of projections) without causing further allocations.
* The type for "a `Scalar` or a `ScalarPair`" is called `Value`, and again used to give some more precise types.
* All of these have versions with an attached layout, so that we can more often drag the layout along instead of recomputing it. This lets us get rid of `PlaceExtra::Downcast`. `MPlaceTy` and `PlaceTy` can only be constructed in place.rs, making sure the layout is handled properly. (The same should eventually be done for `ValTy` and `OpTy`.)
 This is used to check, when copying an operand to a place, that the sizes match (which caught a bunch of bugs).
* All the high-level functions to write typed memory take a `Place`, and live in `place.rs`. All the high-level typed functions to read typed memory take an `Operand`, and live in `operands.rs`.
* Remove `cur_frame` and handling of signedess from memory (catching a bug in the float casting code).
* [Only functional change] Enable sanity check to recurse below dyn traits and slices.

r? @oli-obk

Cc @eddyb
Diffstat (limited to 'src/libsyntax/parse')
0 files changed, 0 insertions, 0 deletions