2025-01-09 02:29:02 +01:00
|
|
|
#![feature(proc_macro_quote)]
|
|
|
|
|
|
|
|
|
|
extern crate proc_macro;
|
|
|
|
|
|
|
|
|
|
use proc_macro::quote;
|
|
|
|
|
|
|
|
|
|
struct Ipv4Addr;
|
|
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
|
let ip = Ipv4Addr;
|
2025-09-23 15:32:25 +02:00
|
|
|
let _ = quote! { $($ip)* };
|
|
|
|
|
//~^ ERROR the method `quote_into_iter` exists for struct `Ipv4Addr`, but its trait bounds were not satisfied
|
|
|
|
|
//~| ERROR type annotations needed
|
2025-01-09 02:29:02 +01:00
|
|
|
}
|