about summary refs log tree commit diff
path: root/compiler/rustc_resolve/src
AgeCommit message (Collapse)AuthorLines
2022-09-27Properly formatting the multipart suggestionstoozy-1/+1
2022-09-27rustc_typeck to rustc_hir_analysislcnr-2/+2
2022-09-26Using multipart suggestionstoozy-12/+19
2022-09-26Trying to suggest additional lifetime parameterstoozy-8/+32
2022-09-26remove cfg(bootstrap)Pietro Albini-1/+0
2022-09-25Only generate closure def id for async fns with bodyMichael Goulet-3/+7
2022-09-26trivial fix on fallbackyukang-3/+1
2022-09-26more code refactor on smart_resolve_report_errorsyukang-175/+207
2022-09-25Rollup merge of #102161 - compiler-errors:issue-102138, r=tmandryMatthias Krüger-36/+37
Resolve async fn signature even without body (e.g., in trait) Fixes #102138 This "bail if no body" behavior was introduced in #69539 to fix #69401, but that ICE does not reproduce any more. The error message changes a bit, but that's all, and I don't think it's a particularly diagnostic bad regression.
2022-09-24Auto merge of #102040 - TaKO8Ki:separate-definitions-and-hir-owners, r=cjgillotbors-16/+16
Separate definitions and HIR owners in the type system Fixes #83158 r? `@cjgillot`
2022-09-24Only record extra lifetime params for async trait fn with no bodyMichael Goulet-38/+40
2022-09-24Resolve async fn signature even without body (in trait)Michael Goulet-3/+2
2022-09-24separate definitions and `HIR` ownersTakayuki Maeda-16/+16
fix a ui test use `into` fix clippy ui test fix a run-make-fulldeps test implement `IntoQueryParam<DefId>` for `OwnerId` use `OwnerId` for more queries change the type of `ParentOwnerIterator::Item` to `(OwnerId, OwnerNode)`
2022-09-24Rollup merge of #102109 - petrochenkov:addids, r=oli-obkMatthias Krüger-10/+30
resolve: Set effective visibilities for imports more precisely Instead of setting them for all primary and additional IDs of the import, only set them for the binding's true ID.
2022-09-22resolve: Set effective visibilities for imports more preciselyVadim Petrochenkov-10/+30
Instead of setting them for all primary and additional IDs of the import, only set them for the binding's true ID.
2022-09-22Fix a typo in error messageFrank Steffahn-1/+1
2022-09-21add trivial commentsyukang-2/+3
2022-09-21code refactoring smart_resolve_report_errorsyukang-173/+261
2022-09-20Add the `#[derive_const]` attributeDeadbeef-1/+1
2022-09-17Rollup merge of #101713 - Bryanskiy:AccessLevels, r=petrochenkovMatthias Krüger-6/+6
change AccessLevels representation Part of RFC (https://github.com/rust-lang/rust/issues/48054). This patch implements effective visibility table with basic methods and change AccessLevels table representation according to it. r? ``@petrochenkov``
2022-09-15Only enable the let_else feature on bootstrapest31-1/+1
On later stages, the feature is already stable. Result of running: rg -l "feature.let_else" compiler/ src/librustdoc/ library/ | xargs sed -s -i "s#\\[feature.let_else#\\[cfg_attr\\(bootstrap, feature\\(let_else\\)#"
2022-09-14change AccessLevels representationBryanskiy-6/+6
2022-09-14Auto merge of #101709 - nnethercote:simplify-visitors-more, r=cjgillotbors-13/+9
Simplify visitors more A successor to #100392. r? `@cjgillot`
2022-09-12Remove unused argument from `visit_poly_trait_ref`.Nicholas Nethercote-6/+2
2022-09-12Remove unused span argument from `walk_fn`.Nicholas Nethercote-1/+1
2022-09-12Remove `path_span` argument to the `visit_path_segment` methods.Nicholas Nethercote-6/+6
The `visit_path_segment` method of both the AST and HIR visitors has a `path_span` argument that isn't necessary. This commit removes it. There are two very small and inconsequential functional changes. - One call to `NodeCollector::insert` now is passed a path segment identifier span instead of a full path span. This span is only used in a panic message printed in the case of an internal compiler bug. - Likewise, one call to `LifetimeCollectVisitor::record_elided_anchor` now uses a path segment identifier span instead of a full path span. This span is used to make some `'_` lifetimes.
2022-09-11Avoid `Iterator::last`KaDiWa-2/+2
2022-09-09Handle generic parameters.Camille GILLOT-5/+1
2022-09-09Make async fn in traits workMichael Goulet-1/+1
2022-09-09Lower RPITIT to ImplTraitPlaceholder itemMichael Goulet-1/+2
2022-09-09RPITIT placeholder itemsMichael Goulet-0/+4
2022-09-08Rollup merge of #101545 - TaKO8Ki:remove-unnecessary-partialord-ord, r=oli-obkDylan DPC-21/+2
Remove unnecessary `PartialOrd` and `Ord`
2022-09-08Rollup merge of #101498 - petrochenkov:visparam, r=cjgillotDylan DPC-34/+45
rustc: Parameterize `ty::Visibility` over used ID It allows using `LocalDefId` instead of `DefId` when possible, and also encode cheaper `Visibility<DefIndex>` into metadata.
2022-09-08remove unnecessary `PartialOrd` and `Ord`Takayuki Maeda-21/+2
2022-09-07Add instrument and debug callsSantiago Pastorino-0/+3
2022-09-07rustc: Parameterize `ty::Visibility` over used IDVadim Petrochenkov-34/+45
It allows using `LocalDefId` instead of `DefId` when possible, and also encode cheaper `Visibility<DefIndex>` into metadata.
2022-09-06Auto merge of #101241 - camsteffen:refactor-binding-annotations, r=cjgillotbors-7/+7
`BindingAnnotation` refactor * `ast::BindingMode` is deleted and replaced with `hir::BindingAnnotation` (which is moved to `ast`) * `BindingAnnotation` is changed from an enum to a tuple struct e.g. `BindingAnnotation(ByRef::No, Mutability::Mut)` * Associated constants added for convenience `BindingAnnotation::{NONE, REF, MUT, REF_MUT}` One goal is to make it more clear that `BindingAnnotation` merely represents syntax `ref mut` and not the actual binding mode. This was especially confusing since we had `ast::BindingMode`->`hir::BindingAnnotation`->`thir::BindingMode`. I wish there were more symmetry between `ByRef` and `Mutability` (variant) naming (maybe `Mutable::Yes`?), and I also don't love how long the name `BindingAnnotation` is, but this seems like the best compromise. Ideas welcome.
2022-09-06Rollup merge of #101447 - cjgillot:no-remap-resolver, r=spastorinoYuki Okushi-8/+0
Remove generics_def_id_map from the resolver. This is internal state for lowering. This does not belong in the resolver. r? ``@spastorino``
2022-09-05Remove generics_def_id_map from the resolver.Camille GILLOT-8/+0
2022-09-05Rollup merge of #101391 - matthiaskrgr:perf0309, r=oli-obkDylan DPC-1/+1
more clippy::perf fixes
2022-09-03more clippy::perf fixesMatthias Krüger-1/+1
2022-09-03Do not call object_lifetime_default on lifetime params.Camille GILLOT-16/+22
2022-09-02Refactor and re-use BindingAnnotationCameron Steffen-7/+7
2022-09-02Rollup merge of #100147 - Bryanskiy:private-in-public, r=petrochenkovGuillaume Gomez-123/+80
optimization of access level table construction Refactoring which was mentioned in #87487
2022-09-01Auto merge of #98960 - cjgillot:entry-kind, r=estebankbors-1/+1
Remove EntryKind from metadata. This PR continues the refactor of metadata emission to be more systematic, iterating on definitions and filtering based on each definition's `DefKind`. This allows to remove the large `EntryKind` enum, replaced by linear tables in metadata.
2022-09-01Always import all tracing macros for the entire crate instead of piecemeal ↵Oli Scherer-15/+4
by module
2022-09-01Directly use the `instrument` macro instead of its full pathOli Scherer-27/+27
2022-09-01Auto merge of #100707 - dzvon:fix-typo, r=davidtwcobors-3/+3
Fix a bunch of typo This PR will fix some typos detected by [typos]. I only picked the ones I was sure were spelling errors to fix, mostly in the comments. [typos]: https://github.com/crate-ci/typos
2022-08-31access_levels.rs refactorBryanskiy-123/+80
2022-08-31Fix a bunch of typoDezhi Wu-3/+3
This PR will fix some typos detected by [typos]. I only picked the ones I was sure were spelling errors to fix, mostly in the comments. [typos]: https://github.com/crate-ci/typos