about summary refs log tree commit diff
path: root/src/librustc_mir/interpret
AgeCommit message (Collapse)AuthorLines
2019-10-27Panicking infra uses &core::panic::Location.Adam Perry-10/+11
This allows us to remove `static_panic_msg` from the SSA<->LLVM boundary, along with its fat pointer representation for &str. Also changes the signature of PanicInfo::internal_contructor to avoid copying. Closes #65856.
2019-10-25Don't cast directly from `&[T; N]` to `*const T`Matthew Jasper-1/+3
Instead coerce to `*const [T; N]` and then cast.
2019-10-23Rollup merge of #65704 - RalfJung:exact-size, r=oli-obkMazdak Farrokhzad-3/+4
relax ExactSizeIterator bound on write_bytes Too many iterators don't have that bound. Instead we do run-time checks. r? @oli-obk
2019-10-23Rollup merge of #65657 - nnethercote:rm-InternedString-properly, r=eddybMazdak Farrokhzad-1/+1
Remove `InternedString` This PR removes `InternedString` by converting all occurrences to `Symbol`. There are a handful of places that need to use the symbol chars instead of the symbol index, e.g. for stable sorting; local conversions `LocalInternedString` is used in those places. r? @eddyb
2019-10-22relax ExactSizeIterator bound on write_bytes: too many iterators don't have ↵Ralf Jung-3/+4
that bound
2019-10-22add commentsRalf Jung-2/+2
2019-10-22bring back some Debug instances for MiriRalf Jung-2/+2
2019-10-21Rollup merge of #65660 - varkor:canonical-const-to-bound-const, r=eddybMazdak Farrokhzad-2/+2
Rename `ConstValue::Infer(InferConst::Canonical(..))` to `ConstValue::Bound(..)` It already has the right form, so this is just a renaming. Fixes https://github.com/rust-lang/rust/issues/65655. r? @eddyb
2019-10-21Rollup merge of #65647 - nnethercote:rm-unnecessary-traits, r=CentrilMazdak Farrokhzad-6/+6
Remove unnecessary trait bounds and derivations This PR removes unnecessary trait bounds and derivations from many types. r? @nikomatsakis
2019-10-21Rename `ConstValue::Infer(InferConst::Canonical(..))` to `ConstValue::Bound(..)`varkor-2/+2
2019-10-21Remove many unnecessary trait derivations.Nicholas Nethercote-6/+6
2019-10-21Convert fields within `DefPathData` from `InternedString` to `Symbol`.Nicholas Nethercote-1/+1
It's a full conversion, except in `DefKey::compute_stable_hash()` where a `Symbol` now is converted to an `InternedString` before being hashed. This was necessary to avoid test failures.
2019-10-20miri add write_bytes method to Memory doing bounds-checks and supporting ↵Ralf Jung-1/+20
iterators
2019-10-18Don't ICE when evaluating writes to uninhabited enum variantsWesley Wiser-10/+16
2019-10-18Review nitOliver Scherer-1/+1
Co-Authored-By: Ralf Jung <post@ralfj.de>
2019-10-18Adjust const eval code to reflect `offset_from` docsOliver Scherer-6/+1
2019-10-17Rollup merge of #65319 - RalfJung:memory, r=CentrilMazdak Farrokhzad-17/+6
InterpCx: make memory field public I made this field private forever ago because I thought sealing things might be nice. But with the `memory_mut` getter it doesn't actually seal anything, and it's not like we need to invalidate caches on writes to memory or so. And moreover, having to use the getters leads to some annoying borrow checking interactions. So, let's just make it public (again). r? @oli-obk
2019-10-14Auto merge of #64987 - oli-obk:code_reuse_prevents_bugs, r=eddybbors-8/+5
Compute the layout of uninhabited structs fixes #64506 r? @eddyb
2019-10-11InterpCx: make memory field publicRalf Jung-17/+6
2019-10-11Make <*const/mut T>::offset_from `const fn`Oliver Scherer-1/+55
2019-10-09miri calls resolve_for_fn_ptr when reifying.Adam Perry-1/+8
2019-10-09Add InstanceDef::ReifyShim for track_caller functions.Adam Perry-0/+1
2019-10-05Rollup merge of #65100 - csmoe:generator, r=nikomatsakisTyler Mandry-6/+9
Replace GeneratorSubsts with SubstsRef Closes #42340 r? @nikomatsakis
2019-10-05Rollup merge of #65066 - ↵Tyler Mandry-0/+7
wesleywiser:fix_const_prop_ice_on_polymorphic_promoted_mir, r=oli-obk [const-prop] Fix ICE when trying to eval polymorphic promoted MIR Fixes #64908 r? @oli-obk cc @nikomatsakis @pnkfelix
2019-10-04[const-prop] Fix ICE when trying to eval polymorphic promoted MIRWesley Wiser-0/+7
2019-10-04clean up GeneratorSubstscsmoe-6/+9
2019-10-04Rollup merge of #64817 - csmoe:closure, r=nikomatsakisMazdak Farrokhzad-1/+1
Replace ClosureSubsts with SubstsRef Addresses https://github.com/rust-lang/rust/issues/42340 part 3 https://github.com/rust-lang/rust/pull/59312 might benefit from this clean up. r? @nikomatsakis
2019-10-03generate ClosureSubsts from SubstsRefcsmoe-1/+1
2019-10-02Compute the layout of uninhabited structsOliver Scherer-8/+5
2019-09-29remove indexed_vec re-export from rustc_data_structurescsmoe-2/+2
2019-09-29remove ClosureSubsts with SubstsRefcsmoe-2/+2
2019-09-29Rollup merge of #64824 - Mark-Simulacrum:no-stable-hasher-result-everywhere, ↵Mazdak Farrokhzad-4/+4
r=michaelwoerister No StableHasherResult everywhere This removes the generic parameter on `StableHasher`, instead moving it to the call to `finish`. This has the side-effect of making all `HashStable` impls nicer, since we no longer need the verbose `<W: StableHasherResult>` that previously existed -- often forcing line wrapping. This is done for two reasons: * we should avoid false "generic" dependency on the result of StableHasher * we don't need to codegen two/three copies of all the HashStable impls when they're transitively used to produce a fingerprint, u64, or u128. I haven't measured, but this might actually make our artifacts somewhat smaller too. * Easier to understand/read/write code -- the result of the stable hasher is irrelevant when writing a hash impl.
2019-09-28Auto merge of #64419 - wesleywiser:const_prop_use_ecx, r=oli-obkbors-4/+27
Deduplicate some code between miri and const prop r? @oli-obk
2019-09-28Switch over all StableHash impls to new formatMark Rousskov-4/+4
2019-09-28Allow reading non-mutable statics in const propWesley Wiser-6/+5
2019-09-27Introduce a `ConstPropMachine`Wesley Wiser-12/+22
This allows us to avoid changing things directly in the miri engine just for const prop.
2019-09-27Work around for #64506Wesley Wiser-1/+5
2019-09-27Move Ref-from-arg checking from `step.rs` to `const_prop.rs`Wesley Wiser-19/+2
2019-09-27Respond to code review feedback and fix tidyWesley Wiser-2/+4
2019-09-27[const-prop] Replace `Ref` handling with use of `InterpCx`Wesley Wiser-2/+19
2019-09-27[const-prop] Replace `Use` handling with use of `InterpCx`Wesley Wiser-1/+1
2019-09-27[const-prop] Replace `eval_place()` with use of `InterpCx`Wesley Wiser-3/+11
2019-09-26Rename `Pat.node` to `Pat.kind`varkor-1/+1
2019-09-26Rename `subst::Kind` to `subst::GenericArg`varkor-3/+3
2019-09-26Auto merge of #64513 - varkor:sty-begone, r=eddybbors-32/+32
Rename `TyS.sty` to `TyS.kind` Fixes https://github.com/rust-lang/rust/issues/64353. r? @eddyb
2019-09-25Rename `sty` to `kind`varkor-29/+29
2019-09-25Rename non-`TyS` uses of `sty`varkor-3/+3
2019-09-25Formatgnzlbg-2/+1
2019-09-25Test errorsgnzlbg-15/+10
2019-09-25Refactorgnzlbg-58/+52