mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-07-01 02:47:24 +00:00
Look inside of None-delimited groups when examining types
This commit is contained in:
@@ -8,8 +8,17 @@ mod case;
|
||||
mod check;
|
||||
mod symbol;
|
||||
|
||||
use syn::Type;
|
||||
|
||||
#[derive(Copy, Clone)]
|
||||
pub enum Derive {
|
||||
Serialize,
|
||||
Deserialize,
|
||||
}
|
||||
|
||||
pub fn ungroup(mut ty: &Type) -> &Type {
|
||||
while let Type::Group(group) = ty {
|
||||
ty = &group.elem;
|
||||
}
|
||||
ty
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user