needless_lifetimes: macro test

Signed-off-by: Tyler Weaver <maybe@tylerjw.dev>
This commit is contained in:
Tyler Weaver 2023-01-30 07:59:01 -07:00
parent d020fd7fe6
commit c959813bfd
No known key found for this signature in database

View File

@ -495,4 +495,17 @@ fn multiple_inputs_output_would_be_elided<'a, 'b>(x: &'a u8, y: &'b u8, z: &'b u
}
}
mod skip_inside_macros {
macro_rules! print_with_one_input {
($a:expr) => {
fn print_with_one_input<'a>(x: &'a u8) -> &'a u8 {
println!("{}", $a);
unimplemented!()
}
};
}
print_with_one_input!("this is a dandy little string literal");
}
fn main() {}