Remove struct_type from union output and bump format

This commit is contained in:
Rune Tynan
2021-01-23 19:40:29 -05:00
parent 74500b9978
commit 3106de5f2a
4 changed files with 20 additions and 6 deletions

View File

@@ -194,6 +194,7 @@ pub enum ItemEnum {
},
ImportItem(Import),
UnionItem(Union),
StructItem(Struct),
StructFieldItem(Type),
EnumItem(Enum),
@@ -238,6 +239,14 @@ pub struct Module {
pub items: Vec<Id>,
}
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq)]
pub struct Union {
pub generics: Generics,
pub fields_stripped: bool,
pub fields: Vec<Id>,
pub impls: Vec<Id>,
}
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq)]
pub struct Struct {
pub struct_type: StructType,
@@ -270,7 +279,6 @@ pub enum StructType {
Plain,
Tuple,
Unit,
Union,
}
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq)]