about summary refs log tree commit diff
path: root/compiler/rustc_middle/src/ty/adjustment.rs
AgeCommit message (Collapse)AuthorLines
2023-09-18Remove unused `Lift` derives.Nicholas Nethercote-4/+4
I found these by commenting out all `Lift` derives and then adding back the ones that were necessary to successfully compile.
2023-07-07Rename `adjustment::PointerCast` and variants using it to `PointerCoercion`Nilstrieb-2/+2
It makes it sound like the `ExprKind` and `Rvalue` are supposed to represent all pointer related casts, when in reality their just used to share a some enum variants. Make it clear there these are only coercion to make it clear why only some pointer related "casts" are in the enum.
2023-07-05Move `TyCtxt::mk_x` to `Ty::new_x` where applicableBoxy-1/+1
2023-03-30Update `ty::VariantDef` to use `IndexVec<FieldIdx, FieldDef>`Scott McMurray-1/+2
And while doing the updates for that, also uses `FieldIdx` in `ProjectionKind::Field` and `TypeckResults::field_indices`. There's more places that could use it (like `rustc_const_eval` and `LayoutS`), but I tried to keep this PR from exploding to *even more* places. Part 2/? of https://github.com/rust-lang/compiler-team/issues/606
2022-12-14Let `mk_fn_def` take an iterator instead to simplify some call sitesOli Scherer-1/+1
2022-11-23Simplify creation of `AutoBorrowMutability`Maybe Waffle-0/+12
2022-11-21Allow iterators instead of requiring slices that will get turned into iteratorsOli Scherer-1/+1
2022-11-21Reduce the amount of passed-around arguments that will get merged into one ↵Oli Scherer-4/+3
later anyway
2022-10-14Make dyn* cast into a coercionMichael Goulet-0/+3
2022-09-15derive various Lift impl instead of hand rolling themOli Scherer-4/+4
2022-07-05Add #[derive(TypeVisitable)]Alan Egerton-4/+6
2022-05-02fix most compiler/ doctestsElliot Roberts-1/+1
2021-12-15Remove `in_band_lifetimes` from `rustc_middle`Aaron Hill-1/+1
See #91867 This was mostly straightforward. In several places, I take advantage of the fact that lifetimes are non-hygenic: a macro declares the 'tcx' lifetime, which is then used in types passed in as macro arguments.
2021-05-24Add some backticks to the `rustc_middle::ty::adjustment::Adjustment` docsScott McMurray-5/+5
A few `[i32]`s are getting picked up as intra-doc links, rather than showing as slices, making the sentence quite confusing.
2021-02-21New pass to deduplicate blocksSimon Vandel Sillesen-1/+1
2020-09-21Reduce boilerplate with the matches! macroLingMan-4/+1
Replaces simple bool `match`es of the form match $expr { $pattern => true _ => false } and their inverse with invocations of the matches! macro.
2020-09-10Note when a a move/borrow error is caused by a deref coercionAaron Hill-0/+4
Fixes #73268 When a deref coercion occurs, we may end up with a move error if the base value has been partially moved out of. However, we do not indicate anywhere that a deref coercion is occuring, resulting in an error message with a confusing span. This PR adds an explicit note to move errors when a deref coercion is involved. We mention the name of the type that the deref-coercion resolved to, as well as the `Deref::Target` associated type being used.
2020-08-30mv compiler to compiler/mark-0/+195