Upgrade toml, toml_edit

This commit is contained in:
Jonas Platte 2023-01-31 18:13:23 +01:00
parent fe5077b1a5
commit de448ead01
No known key found for this signature in database
GPG Key ID: AAA7A61F696C3E0C
3 changed files with 5 additions and 5 deletions

View File

@ -25,4 +25,4 @@ quote = "1.0.8"
ruma-identifiers-validation = { version = "0.9.0", path = "../ruma-identifiers-validation", default-features = false }
serde = { workspace = true }
syn = { version = "1.0.57", features = ["extra-traits", "full", "visit"] }
toml = "0.5.9"
toml = { version = "0.7.1", default-features = false, features = ["parse"] }

View File

@ -37,10 +37,10 @@ fn ensure_feature_presence() -> Option<&'static syn::Error> {
.map_err(|_| syn::Error::new(Span::call_site(), "Failed to read CARGO_MANIFEST_DIR"))?;
let manifest_file = Path::new(&manifest_dir).join("Cargo.toml");
let manifest_bytes = fs::read(manifest_file)
let manifest_bytes = fs::read_to_string(manifest_file)
.map_err(|_| syn::Error::new(Span::call_site(), "Failed to read Cargo.toml"))?;
let manifest_parsed: CargoToml = toml::from_slice(&manifest_bytes)
let manifest_parsed: CargoToml = toml::from_str(&manifest_bytes)
.map_err(|_| syn::Error::new(Span::call_site(), "Failed to parse Cargo.toml"))?;
if manifest_parsed.features.client.is_none() {

View File

@ -13,6 +13,6 @@ isahc = { version = "1.7.0", features = ["json"], optional = true }
semver = { version = "1.0.6", features = ["serde"], optional = true }
serde = { workspace = true }
serde_json = { workspace = true }
toml = "0.5.8"
toml_edit = { version = "0.17.1", optional = true }
toml = { version = "0.7.1", default-features = false, features = ["parse"] }
toml_edit = { version = "0.19.1", optional = true }
xshell = "0.1.17"