Is there a way to write it laconically?
let ty_is_ref = if let syn::Type::Reference( _ ) = ty { true } else { false };
Is that the best way to write it?
Is there a way to write it laconically?
let ty_is_ref = if let syn::Type::Reference( _ ) = ty { true } else { false };
Is that the best way to write it?
let ty_is_ref = matches!(ty, syn::Type::Reference(_));
This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.