2024-02-16 14:02:50 -06:00
|
|
|
//@ force-host
|
|
|
|
//@ edition: 2018
|
|
|
|
//@ no-prefer-dynamic
|
2023-07-23 05:09:43 -05:00
|
|
|
#![crate_type = "proc-macro"]
|
|
|
|
|
|
|
|
extern crate proc_macro;
|
|
|
|
|
|
|
|
use proc_macro::TokenStream;
|
|
|
|
use std::str::FromStr;
|
|
|
|
|
|
|
|
#[proc_macro]
|
|
|
|
pub fn number_of_tokens(_: TokenStream) -> TokenStream {
|
|
|
|
TokenStream::from_str("c\"\"").unwrap().into_iter().count().to_string().parse().unwrap()
|
|
|
|
}
|