Skip to content

Commit ef48aec

Browse files
authored
Fix name qualification in the entity_impl macro. (#10776)
Use `$crate` in the `entity_impl` macro for references to itself, so that they resolve even if `entity_impl` isn't imported into the global scope.
1 parent 6456114 commit ef48aec

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cranelift/entity/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ macro_rules! entity_impl {
190190
// Include basic `Display` impl using the given display prefix.
191191
// Display a `Block` reference as "block12".
192192
($entity:ident, $display_prefix:expr) => {
193-
entity_impl!($entity);
193+
$crate::entity_impl!($entity);
194194

195195
impl $crate::__core::fmt::Display for $entity {
196196
fn fmt(&self, f: &mut $crate::__core::fmt::Formatter) -> $crate::__core::fmt::Result {

0 commit comments

Comments
 (0)