rust/compiler/rustc_metadata/src
Josh Triplett 0b855bcdc9 Switch to a bitflags MacroKinds to support macros with more than one kind
Review everything that uses `MacroKind`, and switch anything that could
refer to more than one kind to use `MacroKinds`.

Add a new `SyntaxExtensionKind::MacroRules` for `macro_rules!` macros,
using the concrete `MacroRulesMacroExpander` type, and have it track
which kinds it can handle. Eliminate the separate optional `attr_ext`,
now that a `SyntaxExtension` can handle multiple macro kinds.

This also avoids the need to downcast when calling methods on
`MacroRulesMacroExpander`, such as `get_unused_rule`.

Integrate macro kind checking into name resolution's
`sub_namespace_match`, so that we only find a macro if it's the right
type, and eliminate the special-case hack for attributes.
2025-08-12 09:24:45 -07:00
..
rmeta Switch to a bitflags MacroKinds to support macros with more than one kind 2025-08-12 09:24:45 -07:00
creader.rs Support multiple crate versions in --extern-html-root-url 2025-07-28 13:34:03 +01:00
dependency_format.rs Rollup merge of #140809 - bjorn3:panic_runtime_cleanup, r=petrochenkov 2025-06-27 22:13:01 +02:00
errors.rs generate elf symbol version in raw-dylib 2025-07-24 19:04:00 +08:00
foreign_modules.rs Retire hir::ForeignItemRef. 2025-07-13 13:50:00 +00:00
fs.rs Move metadata object generation for dylibs to the linker code 2025-06-03 10:04:34 +00:00
lib.rs Remove unused feature gates 2025-06-28 23:36:46 +00:00
locator.rs use let chains in hir, lint, mir 2025-07-28 06:10:14 +05:00
native_libs.rs Add target_env = "macabi" and target_env = "sim" 2025-08-08 13:29:46 +02:00