about summary refs log tree commit diff
path: root/src/librustc/ty/fold.rs
AgeCommit message (Collapse)AuthorLines
2020-03-30rustc -> rustc_middle part 1Mazdak Farrokhzad-1010/+0
2020-03-23add missing visit_constsBastian Kauschke-5/+15
2020-03-01Clean up TypeFlagsMatthew Jasper-4/+2
* Reorder flags to group similar ones together * Make some flags more granular * Compute `HAS_FREE_LOCAL_NAMES` from the other flags * Remove `HAS_TY_CLOSURE` * Add some more doc comments
2020-03-01Fix use of `has_infer_types`Matthew Jasper-3/+3
* Add a new method `has_infer_types_or_consts` that's used instead most of the time, since there's generally no reason to only consider types. * Remove use of `has_closure_types`, because closures are no longer implicitly linked to the `InferCtxt`.
2020-02-14Add fast path to eq_opaque_type_and_typeMatthew Jasper-0/+3
2020-02-14Erase regions in opaque types in typeckMatthew Jasper-0/+4
2020-02-13Constness -> enum Const { Yes(Span), No }Mazdak Farrokhzad-1/+2
Same idea for `Unsafety` & use new span for better diagnostics.
2020-01-20Add `constness` field to `ty::Predicate::Trait`Dylan MacKenzie-0/+9
2020-01-05Remove rustc_hir reexports in rustc::hir.Mazdak Farrokhzad-1/+1
2020-01-04canonicalize FxHash{Map,Set} importsMazdak Farrokhzad-1/+1
2019-12-22Format the worldMark Rousskov-128/+107
2019-11-17Auto merge of #66384 - cjgillot:typefoldable, r=Zoxcbors-2/+1
Derive TypeFoldable using a proc-macro A new proc macro is added in librustc_macros. It is used to derive TypeFoldable inside librustc and librustc_traits. For now, the macro uses the `'tcx` lifetime implicitly, and does not allow for a more robust selection of the adequate lifetime. The Clone-based TypeFoldable implementations are not migrated. Closes #65674
2019-11-13Retire BraceStructTypeFoldableImpl and TupleStructTypeFoldableImpl.Camille GILLOT-2/+1
2019-11-12Create intermediate enum ty::ConstKind.Camille GILLOT-6/+5
2019-10-21Rollup merge of #65660 - varkor:canonical-const-to-bound-const, r=eddybMazdak Farrokhzad-12/+11
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-1/+0
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-12/+11
2019-10-21Remove many unnecessary trait derivations.Nicholas Nethercote-1/+0
2019-10-20Fix resolve_type_vars_with_obligations not resolving const inferenceben-0/+3
variables.
2019-10-07correct bug in the "has escaping regions" visitorNiko Matsakis-7/+9
Existing code could overlook types/substitutions that are embedded in (e.g.) an unevaluated constant.
2019-09-25Rename `sty` to `kind`varkor-3/+3
2019-09-07Aggregation of cosmetic changes made during work on REPL PRs: librustcAlexander Regueiro-2/+2
2019-08-11Remove `is_self` and `has_self_ty` methodsMatthew Jasper-3/+0
2019-06-26Don't use lift to detect local typesJohn Kåre Alsaker-0/+4
2019-06-14Run `rustfmt --file-lines ...` for changes from previous commits.Eduard-Mihai Burtescu-6/+1
2019-06-14Unify all uses of 'gcx and 'tcx.Eduard-Mihai Burtescu-33/+33
2019-06-12Run `rustfmt --file-lines ...` for changes from previous commits.Eduard-Mihai Burtescu-30/+37
2019-06-12rustc: replace `TyCtxt<'tcx, 'gcx, 'tcx>` with `TyCtxt<'gcx, 'tcx>`.Eduard-Mihai Burtescu-17/+17
2019-06-12Fix fallout from `deny(unused_lifetimes)`.Eduard-Mihai Burtescu-5/+5
2019-06-12rustc: replace `TyCtxt<'a, 'gcx, 'tcx>` with `TyCtxt<'tcx, 'gcx, 'tcx>`.Eduard-Mihai Burtescu-22/+22
2019-05-25Remove unnecessary secondary recursionOliver Scherer-1/+1
2019-05-01Fix rebase from LazyConst removalvarkor-16/+16
2019-05-01Add `ConstValue::Placeholder`varkor-1/+5
2019-05-01Implement fold_const for BoundVarReplacervarkor-14/+58
2019-05-01impl fold_const for ShifterGabriel Smith-6/+24
Signed-off-by: Gabriel Smith <ga29smith@gmail.com>
2019-05-01impl visit_const for HasEscapingVarsVisitorGabriel Smith-0/+12
Signed-off-by: Gabriel Smith <ga29smith@gmail.com>
2019-05-01Add stubs for `fold_const`varkor-0/+8
Co-Authored-By: Gabriel Smith <yodaldevoid@users.noreply.github.com>
2019-05-01Add generic consts to `BottomUpFolder`varkor-7/+15
Co-Authored-By: Gabriel Smith <yodaldevoid@users.noreply.github.com>
2019-05-01Auto merge of #60195 - varkor:commontypes-to-common, r=eddybbors-1/+1
Split `CommonTypes` into `CommonTypes` and `CommonLifetimes` The so-called "`CommonTypes`" contains more than just types. r? @eddyb
2019-04-28Fix lint findings in librustcflip1995-5/+5
2019-04-25Update existing usagesvarkor-1/+1
2019-03-16Revert the `LazyConst` PROliver Scherer-10/+6
2019-03-05Add const type flagsvarkor-9/+10
Co-Authored-By: Gabriel Smith <yodaldevoid@users.noreply.github.com>
2019-02-12Auto merge of #58341 - alexreg:cosmetic-2-doc-comments, r=steveklabnikbors-22/+24
Cosmetic improvements to doc comments This has been factored out from https://github.com/rust-lang/rust/pull/58036 to only include changes to documentation comments (throughout the rustc codebase). r? @steveklabnik Once you're happy with this, maybe we could get it through with r=1, so it doesn't constantly get invalidated? (I'm not sure this will be an issue, but just in case...) Anyway, thanks for your advice so far!
2019-02-11Remove two dead functions.Nicholas Nethercote-25/+0
2019-02-10rustc: doc commentsAlexander Regueiro-22/+24
2019-02-05move librustc to 2018Mark Mansi-3/+3
2019-01-05Rollup merge of #57314 - wiktorkuchta:master, r=Centrilkennytm-1/+1
Fix repeated word typos Inspired by #57295 (I skipped 'be be' because of it) and my [PR in another repo ](https://github.com/e-maxx-eng/e-maxx-eng/pull/389) Not a stupid `sed`, I actually tried to fix case by case.
2019-01-04Update src/librustc/ty/fold.rsArtem Varaksa-1/+1
Co-Authored-By: wiktorkuchta <35867657+wiktorkuchta@users.noreply.github.com>
2019-01-03Fix repeated word typosWiktor Kuchta-1/+1
Found with `git grep -P '\b([a-z]+)\s+\1\b'`