You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tests/testsuite/cfg.rs
+10-7Lines changed: 10 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -543,12 +543,15 @@ fn cfg_raw_idents() {
543
543
.build();
544
544
545
545
p.cargo("check")
546
-
.with_status(101)
547
546
.with_stderr_data(str![[r#"
548
-
[ERROR] failed to parse manifest at `[ROOT]/foo/Cargo.toml`
549
-
550
-
Caused by:
551
-
failed to parse `any(r#true, r#all, r#target_os = "<>")` as a cfg expression: unexpected character `#` in cfg, expected parens, a comma, an identifier, or a string
547
+
[WARNING] [[ROOT]/foo/Cargo.toml] future-incompatibility: the meaning of `cfg(r#true)` will change in the future
548
+
| Cargo is erroneously allowing `cfg(true)` and `cfg(false)`, but both forms are interpreted as false unless manually overridden with `--cfg`.
549
+
| In the future these will be built-in defines that will have the corresponding true/false value.
550
+
| It is recommended to avoid using these configs until they are properly supported.
551
+
| See <https://github.com/rust-lang/rust/issues/131204> for more information.
552
+
[LOCKING] 1 package to latest compatible version
553
+
[CHECKING] foo v0.1.0 ([ROOT]/foo)
554
+
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
552
555
553
556
"#]])
554
557
.run();
@@ -577,7 +580,7 @@ fn cfg_raw_idents_empty() {
577
580
[ERROR] failed to parse manifest at `[ROOT]/foo/Cargo.toml`
578
581
579
582
Caused by:
580
-
failed to parse `r#)` as a cfg expression: unexpected content `#)` found after cfg expression
583
+
failed to parse `r#)` as a cfg expression: unexpected character `)` in cfg, expected parens, a comma, an identifier, or a string
0 commit comments