WIP: text_system

This commit is contained in:
Mikayla
2024-01-22 19:30:40 -08:00
parent 0c3fb449f0
commit a99d5b87e8
5 changed files with 106 additions and 36 deletions
@@ -245,10 +245,14 @@ pub fn derive_refineable(input: TokenStream) -> TokenStream {
}
let gen = quote! {
/// A refinable version of [`#ident`], see that documentation for details.
#[derive(Clone)]
#derive_stream
pub struct #refinement_ident #impl_generics {
#( #field_visibilities #field_names: #wrapped_types ),*
#(
#[allow(missing_docs)]
#field_visibilities #field_names: #wrapped_types
),*
}
impl #impl_generics Refineable for #ident #ty_generics
@@ -304,6 +308,7 @@ pub fn derive_refineable(input: TokenStream) -> TokenStream {
impl #impl_generics #refinement_ident #ty_generics
#where_clause
{
/// Returns `true` if all fields are `Some`
pub fn is_some(&self) -> bool {
#(
if self.#field_names.is_some() {