SIGN IN SIGN UP
bevyengine / bevy UNCLAIMED

A refreshingly simple data-driven game engine built in Rust

0 0 59 Rust

Use absolute paths in declarative macros (#24261)

# Objective

- Improve declarative macro hygiene.
- Fix declarative macros using non-imported items.
  - `AnimatedField` is unqualified in the `animated_field` macro.
  - `offset_of` is unqualified in the `impl_atomic_pod` macro.
- `format` is unqualified in `hash_error` macro (requires import in
`no_std`).

## Solution

- Qualify unqualified items and use absolute paths in every public
(`#[macro_export]`) `macro_rules`.
- Re-export `format` in `bevy_reflect::__macro_exports::alloc_utils`.

## Testing

- Ran `cargo run -p ci -- compile`
D
DavidCrossman committed
9dfc7a6d33596cf9e087228da9ebf2c8fcbbb816
Parent: 10db67e
Committed by GitHub <noreply@github.com> on 5/21/2026, 9:47:16 AM