Skip to content

Commit e6cc50d

Browse files
authored
fix(gctx): types are unsupported not unknown (#16109)
Address #16103 (comment)
2 parents 93ac6e1 + 633a3a4 commit e6cc50d

File tree

3 files changed

+4
-7
lines changed

3 files changed

+4
-7
lines changed

src/cargo/util/context/mod.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2155,10 +2155,7 @@ impl ConfigValue {
21552155
.collect::<CargoResult<_>>()?,
21562156
def,
21572157
)),
2158-
v => bail!(
2159-
"found TOML configuration value of unknown type `{}`",
2160-
v.type_str()
2161-
),
2158+
v => bail!("unsupported TOML configuration type `{}`", v.type_str()),
21622159
}
21632160
}
21642161

tests/testsuite/bad_config.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ Caused by:
5050
failed to parse config at `http.proxy`
5151
5252
Caused by:
53-
found TOML configuration value of unknown type `float`
53+
unsupported TOML configuration type `float`
5454
5555
"#]])
5656
.run();
@@ -80,7 +80,7 @@ Caused by:
8080
failed to parse config at `http.proxy`
8181
8282
Caused by:
83-
found TOML configuration value of unknown type `datetime`
83+
unsupported TOML configuration type `datetime`
8484
8585
"#]])
8686
.run();

tests/testsuite/config_cli.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -502,7 +502,7 @@ Caused by:
502502
failed to parse config at `a`
503503
504504
Caused by:
505-
found TOML configuration value of unknown type `datetime`
505+
unsupported TOML configuration type `datetime`
506506
"#]],
507507
);
508508
}

0 commit comments

Comments
 (0)