Skip to content

Commit

Permalink
Fix macro hygiene in wasm_bindgen_test (#2748)
Browse files Browse the repository at this point in the history
Specifically, use fully qualified path for `concat!` macro.
  • Loading branch information
teohhanhui committed Jan 4, 2022
1 parent c515cbf commit 8aa58ac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/test-macro/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ pub fn wasm_bindgen_test(
(quote! {
#[no_mangle]
pub extern "C" fn #name(cx: &::wasm_bindgen_test::__rt::Context) {
let test_name = concat!(module_path!(), "::", stringify!(#ident));
let test_name = ::std::concat!(::std::module_path!(), "::", ::std::stringify!(#ident));
#test_body
}
})
Expand Down

0 comments on commit 8aa58ac

Please sign in to comment.