🎨 Nueov enfoque para las funciones de traducción

This commit is contained in:
Manuel Cillero 2023-05-21 21:59:47 +02:00
parent 7691bf4b2f
commit 71b0b0889d
11 changed files with 110 additions and 93 deletions

View file

@ -8,8 +8,8 @@ mod escape;
mod generate;
mod parse;
use proc_macro_crate::{crate_name, FoundCrate};
use proc_macro2::{Ident, Span, TokenStream, TokenTree};
use proc_macro_crate::{crate_name, FoundCrate};
use quote::quote;
pub fn expand(input: TokenStream) -> TokenStream {
@ -27,7 +27,7 @@ pub fn expand(input: TokenStream) -> TokenStream {
),
_ => quote!(
pagetop::html::PreEscaped(#output_ident)
)
),
};
quote!({

View file

@ -113,7 +113,7 @@ impl Generator {
),
_ => quote!(
pagetop::html::html_private::render_to!(&#expr, &mut #output_ident);
)
),
});
}