rust/compiler/rustc_resolve/src
bors 83965efe6a Auto merge of #133274 - ehuss:macro_rules-edition-from-pm, r=compiler-errors
Use edition of `macro_rules` when compiling the macro

This changes the edition assigned to a macro_rules macro when it is compiled to use the edition of where the macro came from instead of the local crate's edition.

This fixes a problem when a macro_rules macro is created by a proc-macro. Previously that macro would be tagged with the local edition, which would cause problems with using the correct edition behavior inside the macro. For example, the check for unsafe attributes would cause errors in 2024 when using proc-macros from older editions.

This is partially related to https://github.com/rust-lang/rust/issues/132906. Unfortunately this is only a half fix for that issue. It fixes the error that happens in 2024, but does not fix the lint firing in 2021. I'm still trying to think of some way to fix that, but I'm running low on ideas.
2024-11-27 04:54:08 +00:00
..
late Refactor where predicates, and reserve for attributes support 2024-11-25 16:38:35 +08:00
build_reduced_graph.rs Make WalkItemKind::walk signature compatible between Visitor versions 2024-11-15 17:01:53 -03:00
check_unused.rs compiler: use is_none_or where it is clearly better 2024-10-16 23:50:13 -07:00
def_collector.rs Use edition of macro_rules when compiling the macro 2024-11-20 17:28:47 -08:00
diagnostics.rs Rollup merge of #132949 - clubby789:macro-rules-attr-derive, r=fmease 2024-11-23 20:19:53 +08:00
effective_visibilities.rs Reformat using the new identifier sorting from rustfmt 2024-09-22 19:11:29 -04:00
errors.rs Diagnostic for using macro_rules macro as attr/derive 2024-11-22 16:49:10 +00:00
ident.rs Store resolution for self and crate root module segments 2024-11-20 18:57:02 +00:00
imports.rs Reformat using the new identifier sorting from rustfmt 2024-09-22 19:11:29 -04:00
late.rs Refactor where predicates, and reserve for attributes support 2024-11-25 16:38:35 +08:00
lib.rs Remove Resolver::empty_disambiguator. 2024-11-14 12:08:20 +11:00
macros.rs Rollup merge of #131375 - klensy:clone_on_ref_ptr, r=cjgillot 2024-10-29 03:11:39 -07:00
rustdoc.rs Handle librustdoc cases of rustc::potential_query_instability lint 2024-10-06 10:39:03 +03:00