about summary refs log tree commit diff
path: root/compiler/rustc_mir_build/src/thir/mod.rs
AgeCommit message (Collapse)AuthorLines
2025-01-31Remove the `thir_{tree,flat}` hooks.Nicholas Nethercote-1/+1
They were downgraded from queries in #123995 but they can just be vanilla functions because they are not called in `rustc_middle`.
2023-02-26Move THIR printing to rustc_mir_build.Camille GILLOT-3/+1
2022-05-20Remove `crate` visibility usage in compilerJacob Pratt-3/+3
2021-09-09move thir visitor to rustc_middleEllen-1/+0
2021-05-22Make THIR building a stealable queryLeSeulArtichaut-1/+0
2021-05-22Move THIR structure definitions to `rustc_middle`LeSeulArtichaut-426/+0
2021-05-19Store THIR in `IndexVec`s instead of an `Arena`LeSeulArtichaut-79/+133
2021-05-11[WIP] Create a `Visitor` for the THIRLeSeulArtichaut-0/+1
2021-04-06Use AnonConst for asm! constantsAmanieu d'Antras-1/+2
2021-03-15Fix error after rebaseRoxane-1/+1
2021-03-15Add comments with examples and testsRoxane-1/+1
2021-03-14Use the correct FakeReadCauseRoxane-2/+2
2021-03-14Introduce new fake readsRoxane-0/+1
2021-03-11Make THIR data structures publicLeSeulArtichaut-39/+40
2021-03-09Make arena allocation for the THIR workLeSeulArtichaut-76/+79
2021-03-09Remove `Clone` impl for `thir::Expr`LeSeulArtichaut-10/+10
2021-03-09[WIP] Eagerly construct bodies of THIRLeSeulArtichaut-149/+62
2021-03-06Change x64 size checks to not apply to x32.Harald van Dijk-1/+1
Rust contains various size checks conditional on target_arch = "x86_64", but these checks were never intended to apply to x86_64-unknown-linux-gnux32. Add target_pointer_width = "64" to the conditions.
2021-01-07Reintroduce hir::ExprKind::IfCaio-0/+5
2020-12-06Introduce if-let guards in the THIRLeSeulArtichaut-0/+1
2020-11-17Remove THIR::ExprKind::SelfRefAman Arora-2/+0
ExprKind::SelfRef was used to express accessing `self` in the desugared Closure/Generator struct when lowering captures in THIR. Since we handle captures in MIR now, we don't need `ExprKind::Self`.
2020-11-17Move capture lowering from THIR to MIRAman Arora-0/+8
This allows us to: - Handle precise Places captured by a closure directly in MIR. Handling captures in MIR is easier since we can rely on/ tweak PlaceBuilder to generate `mir::Place`s that resemble how we store captures (`hir::Place`). - Allows us to handle `let _ = x` case when feature `capture_disjoint_fields` is enabled directly in MIR. This is required to be done in MIR since patterns are desugared in MIR.
2020-10-16Lower inline const down to MIRSantiago Pastorino-0/+3
2020-09-07Add CONST_ITEM_MUTATION lintAaron Hill-0/+4
Fixes #74053 Fixes #55721 This PR adds a new lint `CONST_ITEM_MUTATION`. Given an item `const FOO: SomeType = ..`, this lint fires on: * Attempting to write directly to a field (`FOO.field = some_val`) or array entry (`FOO.array_field[0] = val`) * Taking a mutable reference to the `const` item (`&mut FOO`), including through an autoderef `FOO.some_mut_self_method()` The lint message explains that since each use of a constant creates a new temporary, the original `const` item will not be modified.
2020-08-30mv compiler to compiler/mark-0/+448