about summary refs log tree commit diff
path: root/compiler/rustc_middle/src/lib.rs
AgeCommit message (Collapse)AuthorLines
2022-02-25Switch bootstrap cfgsMark Rousskov-1/+1
2022-02-16Move ty::print methods to Drop-based scope guardsMark Rousskov-0/+1
2022-02-01add a rustc::query_stability lintlcnr-0/+1
2022-01-09rustc_middle: Rename `Export` to `ModChild` and add some commentsVadim Petrochenkov-0/+1
Also rename `module_exports`/`export_map` to `module_reexports`/`reexport_map` for clarity.
2021-12-15Remove `in_band_lifetimes` from `rustc_middle`Aaron Hill-1/+0
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-12-14Stabilize iter::zip.PFPoitras-1/+0
2021-12-13Avoid cloning refcounted types during foldingAlan Egerton-0/+1
2021-11-29std: Stabilize the `thread_local_const_init` featureAlex Crichton-1/+0
This commit is intended to follow the stabilization disposition of the FCP that has now finished in #84223. This stabilizes the ability to flag thread local initializers as `const` expressions which enables the macro to generate more efficient code for accessing it, notably removing runtime checks for initialization. More information can also be found in #84223 as well as the tests where the feature usage was removed in this PR. Closes #84223
2021-11-26Unwrap the results of type foldersLeSeulArtichaut-0/+1
Co-authored-by: Alan Egerton <eggyal@gmail.com>
2021-11-22Use `derive_default_enum` in the compilerJacob Pratt-0/+1
2021-10-28Revert "Add rustc lint, warning when iterating over hashmaps"Mark Rousskov-1/+0
2021-10-24Rollup merge of #89558 - lcnr:query-stable-lint, r=estebankMatthias Krüger-0/+1
Add rustc lint, warning when iterating over hashmaps r? rust-lang/wg-incr-comp
2021-10-16Adopt let_else across the compilerest31-0/+1
This performs a substitution of code following the pattern: let <id> = if let <pat> = ... { identity } else { ... : ! }; To simplify it to: let <pat> = ... { identity } else { ... : ! }; By adopting the let_else feature.
2021-10-15allow `potential_query_instability` everywherelcnr-0/+1
2021-10-05Auto merge of #89266 - cjgillot:session-ich, r=michaelwoeristerbors-1/+0
Move ICH to rustc_query_system Based on https://github.com/rust-lang/rust/pull/89183 The StableHashingContext does not need to be in rustc_middle. This PR moves it to rustc_query_system. This will avoid a dependency between rustc_ast_lowering and rustc_middle in https://github.com/rust-lang/rust/pull/89124.
2021-10-04Rollup merge of #87993 - kornelski:try_reserve_stable, r=joshtriplettJubilee-1/+0
Stabilize try_reserve Stabilization PR for the [`try_reserve` feature](https://github.com/rust-lang/rust/issues/48043#issuecomment-898040475).
2021-10-04Stabilize try_reserveKornel-1/+0
2021-10-03Fully remove rustc_middle::ich.Camille GILLOT-1/+0
2021-10-02Remove various unused feature gatesbjorn3-2/+0
2021-09-12Gather module items after lowering.Camille GILLOT-0/+1
2021-09-08Bump stage0 compiler to 1.56Mark Rousskov-1/+0
2021-09-07Rename rustc_mir to rustc_const_eval.Camille GILLOT-1/+1
2021-09-07Move the dataflow framework to its own crate.Camille GILLOT-0/+2
2021-09-02rustc_target: move `LayoutOf` to `ty::layout`.Eduard-Mihai Burtescu-0/+1
2021-08-25Use if-let guards in the codebaseLéo Lanteri Thauvin-0/+2
2021-08-18Remove box syntax from rustc_middleest31-1/+0
2021-08-07Auto merge of #87408 - kornelski:try_reserve_error, r=yaahcbors-0/+1
Hide allocator details from TryReserveError I think there's [no need for TryReserveError to carry detailed information](https://github.com/rust-lang/rust/issues/48043#issuecomment-825139280), but I wouldn't want that issue to delay stabilization of the `try_reserve` feature. So I'm proposing to stabilize `try_reserve` with a `TryReserveError` as an opaque structure, and if needed, expose error details later. This PR moves the `enum` to an unstable inner `TryReserveErrorKind` that lives under a separate feature flag. `TryReserveErrorKind` could possibly be left as an implementation detail forever, and the `TryReserveError` get methods such as `allocation_size() -> Option<usize>` or `layout() -> Option<Layout>` instead, or the details could be dropped completely to make try-reserve errors just a unit struct, and thus smaller and cheaper.
2021-08-05use zeroed allocation instead of eagerly initializing the memoryThe8472-0/+2
2021-07-24Hide allocator details from TryReserveErrorKornel-0/+1
2021-07-14use NonZeroU64 for AllocId to restore old type sizesRalf Jung-0/+1
2021-06-29Support allocation failures when interperting MIRSmitty-0/+1
Note that this breaks Miri. Closes #79601
2021-06-14stabilize `int_error_matching`Ethan Brierley-1/+0
2021-05-31Remove unused feature gatesbjorn3-2/+0
2021-05-26Specialize implementationsJacob Pratt-0/+1
Implementations in stdlib are now optimized as they were before.
2021-05-25Auto merge of #84985 - pietroalbini:bootstrap-1.54, r=Mark-Simulacrumbors-1/+0
Bump bootstrap compiler to beta 1.53.0 This PR bumps the bootstrap compiler to version 1.53.0 beta, as part of our usual release process (this was supposed to be Wednesday's step, but creating the beta release took longer than expected). The PR also includes the "Bootstrap: skip rustdoc fingerprint for building docs" commit, see the reasoning [on Zulip](https://zulip-archive.rust-lang.org/241545trelease/88450153betabootstrap.html). r? `@Mark-Simulacrum`
2021-05-24remove cfg(bootstrap)Pietro Albini-1/+0
2021-05-22Move THIR structure definitions to `rustc_middle`LeSeulArtichaut-0/+1
2021-05-02Use new thread-local const-initMark Rousskov-0/+1
Let's see if this gives us any speedup - some of the TLS state modified in this commit *is* pretty heavily accessed, so we can hope!
2021-04-18fix feature use in rustc libsRalf Jung-1/+0
2021-04-07Auto merge of #81047 - glittershark:stabilize-cmp-min-max-by, r=kodrausbors-1/+0
Stabilize cmp_min_max_by I would like to propose cmp::{min_by, min_by_key, max_by, max_by_key} for stabilization. These are relatively simple and seemingly uncontroversial functions and have been unchanged in unstable for a while now. Closes: #64460
2021-04-07Stabilize cmp_min_max_byGriffin Smith-1/+0
I would like to propose cmp::{min_by, min_by_key, max_by, max_by_key} for stabilization. These are relatively simple and seemingly uncontroversial functions and have been unchanged in unstable for a while now.
2021-03-26Use iter::zip in compiler/Josh Stone-0/+1
2021-03-22Auto merge of #79278 - mark-i-m:stabilize-or-pattern, r=nikomatsakisbors-1/+1
Stabilize or_patterns (RFC 2535, 2530, 2175) closes #54883 This PR stabilizes the or_patterns feature in Rust 1.53. This is blocked on the following (in order): - [x] The crater run in https://github.com/rust-lang/rust/pull/78935#issuecomment-731564021 - [x] The resolution of the unresolved questions and a second crater run (https://github.com/rust-lang/rust/pull/78935#issuecomment-735412705) - It looks like we will need to pursue some sort of edition-based transition for `:pat`. - [x] Nomination and discussion by T-lang - [x] Implement new behavior for `:pat` based on consensus (https://github.com/rust-lang/rust/pull/80100). - [ ] An FCP on stabilization EDIT: Stabilization report is in https://github.com/rust-lang/rust/pull/79278#issuecomment-772815177
2021-03-19Stabilize `assoc_char_funcs` and `assoc_char_consts`bstrie-1/+0
2021-03-19stabilize or_patternsmark-1/+1
2021-03-18Remove unwrap_none/expect_none from compiler/.Mara Bos-1/+1
2021-02-19Split DepKindStruct in two.Camille GILLOT-0/+1
2020-12-19docs: Fix outdated crate referencepierwill-1/+1
2020-11-14Introduce `TypeVisitor::BreakTy`LeSeulArtichaut-0/+1
2020-11-04Split the "raw integer bytes" part out of `Scalar`Oliver Scherer-0/+1