Closed evestera closed 7 years ago
Generating the type zero from the following sample:
zero
{ "one": { "two": {}, "three": {} }, "four": {} }
Currently generates types in this order, that we then reverse.
#[derive(Default, Debug, Clone, Serialize, Deserialize)] struct Two {} #[derive(Default, Debug, Clone, Serialize, Deserialize)] struct Three {} #[derive(Default, Debug, Clone, Serialize, Deserialize)] struct One { two: Two, three: Three, } #[derive(Default, Debug, Clone, Serialize, Deserialize)] struct Four {} #[derive(Default, Debug, Clone, Serialize, Deserialize)] struct Zero { one: One, four: Four, }
Ideally, types should be output in the order they appear in the sample.
Fixed by 2a2d2e2f8580948fddbc78ba1aee22ea58be3dc1
Generating the type
zero
from the following sample:Currently generates types in this order, that we then reverse.
Ideally, types should be output in the order they appear in the sample.