Skip to content

Commit

Permalink
Always use absolute paths in generated proc macro code
Browse files Browse the repository at this point in the history
This makes the code more robust and fixes the `unused_qualifications`
warning that happens when the user imports `use enumflags2::*;`
  • Loading branch information
davidzeng0 authored and meithecatte committed Jun 4, 2024
1 parent f08cd33 commit e01808b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions enumflags_derive/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -239,8 +239,8 @@ fn check_flag(type_name: &Ident, flag: &Flag, bits: u8) -> Result<Option<TokenSt
const _:
<<[(); (
(#type_name::#variant_name as u128).is_power_of_two()
) as usize] as enumflags2::_internal::AssertionHelper>
::Status as enumflags2::_internal::ExactlyOneBitSet>::X
) as usize] as ::enumflags2::_internal::AssertionHelper>
::Status as ::enumflags2::_internal::ExactlyOneBitSet>::X
= ();
)))
}
Expand Down

0 comments on commit e01808b

Please sign in to comment.