rename out -> handler_out

This commit is contained in:
p0lunin 2022-01-06 14:10:04 +02:00
parent 8a022edfb5
commit ee959c04cf
2 changed files with 4 additions and 4 deletions

View file

@ -148,7 +148,7 @@ fn parse_out_type(
) -> Result<Type, syn::Error> {
let mut out = None;
for x in attrs {
if x.path.is_ident("out") {
if x.path.is_ident("handler_out") {
out = Some(x.parse_args::<Type>()?);
}
}
@ -157,8 +157,8 @@ fn parse_out_type(
}
Err(syn::Error::new(
span,
"You must specify #[out()] argument in which declare output type of \
handlers. For example, #[out(Result<(), Error>)]",
"You must specify #[handler_out()] argument in which declare output \
type of handlers. For example, #[handler_out(Result<(), Error>)]",
))
}

View file

@ -25,7 +25,7 @@ use syn::{
use std::fmt::Write;
#[proc_macro_derive(DialogueState, attributes(handler, out, store))]
#[proc_macro_derive(DialogueState, attributes(handler, handler_out, store))]
pub fn derive_dialogue_state(item: TokenStream) -> TokenStream {
let input = parse_macro_input!(item as ItemEnum);
match dialogue_state::expand(input) {