We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bb0b971 commit 6055f38Copy full SHA for 6055f38
syn/src/data.rs
@@ -48,6 +48,10 @@ pub enum Fields {
48
Unnamed(Items<Field>),
49
}
50
51
+impl Fields {
52
+ pub fn is_unit(&self) -> bool { matches!(self, Fields::Unit) }
53
+}
54
+
55
pub trait Element: Sized {
56
type Input: Sized;
57
fn with(input: Self::Input, attr_name: &Ident) -> syn::Result<Self>;
0 commit comments