1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#![no_std]
extern crate alloc;
#[cfg(test)]
extern crate std;
use proc_macro::TokenStream as TokenStream1;
use proc_macro2::TokenStream as TokenStream2;
mod datastructure;
mod derive_debug;
mod syntax;
mod utils;
#[cfg(test)]
mod test_utils;
#[proc_macro_derive(PanicFmt, attributes(pfmt))]
pub fn derive_const_debug(input: TokenStream1) -> TokenStream1 {
syn::parse(input)
.and_then(derive_debug::derive_constdebug_impl)
.unwrap_or_else(|e| e.to_compile_error())
.into()
}