rust/compiler/rustc_resolve/src
Michael Goulet 61c776ae0a
Rollup merge of #119638 - lukas-code:suggest-constructor-cycle-error, r=cjgillot
fix cyle error when suggesting to use associated function instead of constructor

Fixes https://github.com/rust-lang/rust/issues/119625.

The first commit fixes the infinite recursion and makes the cycle error actually show up. We do this by making the `Display` for `ty::Instance` impl  respect `with_no_queries` so that it can be used in query descriptions.

The second commit fixes the cycle error `resolver_for_lowering` -> `normalize` -> `resolve_instance` (for evaluating const) -> `lang_items` (for `drop_in_place`) -> `resolver_for_lowering` (for collecting lang items). We do this by simply skipping the suggestion when encountering an unnormalized type.
2024-01-05 23:41:43 -05:00
..
diagnostics Implement the unused_macro_rules lint 2022-05-05 19:13:00 +02:00
late Rollup merge of #119638 - lukas-code:suggest-constructor-cycle-error, r=cjgillot 2024-01-05 23:41:43 -05:00
build_reduced_graph.rs Remove Session methods that duplicate DiagCtxt methods. 2023-12-24 08:05:28 +11:00
check_unused.rs Rollup merge of #116905 - Fenex:refactor/compiler/resolve, r=petrochenkov 2023-10-26 17:45:43 +02:00
def_collector.rs Introduce closure_id method on CoroutineKind 2023-12-08 21:46:39 +00:00
diagnostics.rs Rollup merge of #119151 - Jules-Bertholet:no-foreign-doc-hidden-suggest, r=davidtwco 2024-01-05 20:39:50 +01:00
effective_visibilities.rs resolve: Replace visibility table in resolver outputs with query feeding 2023-12-18 02:26:55 +03:00
errors.rs tip for define macro name after macro_rules! 2023-12-06 23:19:39 +08:00
ident.rs Update to bitflags 2 in the compiler 2023-12-30 18:17:28 +01:00
imports.rs Remove Session methods that duplicate DiagCtxt methods. 2023-12-24 08:05:28 +11:00
late.rs fallback visibility for unexpected trait item 2024-01-04 02:02:57 +08:00
lib.rs Give DiagnosticBuilder a default type. 2023-12-23 13:23:10 +11:00
macros.rs Remove Session methods that duplicate DiagCtxt methods. 2023-12-24 08:05:28 +11:00
rustdoc.rs NFC don't convert types to identical types 2023-12-15 23:56:24 +01:00