I've asked sometime here about untagged enums in TOML, and it looks like the solution got something wrong. I get:
Error: Whack manifest at C:\Users\Hydro\Documents\Repository Groups\Whack\whacklib\packages\whack.base\whack.toml
contains invalid TOML: data did not match
any variant of untagged enum ManifestDependency
Here's whack.toml
:
[package]
name = "whack.base"
version = "1.0.0"
authors = ["Matheus Dias de Souza <hydroperfox@gmail.com>"]
license = "Apache-2.0"
description = "The base library of the Whack engine."
source-path = ["src"]
[dependencies]
"as3.lang" = { path = "../as3.lang", version = "1" }
Here's ManifestDependency
:
#[derive(Clone, Serialize, Deserialize)]
#[serde(untagged)]
pub enum ManifestDependency {
Version(Version),
Advanced {
version: Option<Version>,
path: Option<String>,
git: Option<String>,
rev: Option<String>,
branch: Option<String>,
},
}