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
I'm on 1.34.0-nightly and tried to do some trivial things with s! but I couldn't get my code to compile.
I'm using interpolate 0.2.3. My next step was to run cargo test -p interpolate in my project.
This is what I got:
$ cargo test -p interpolate
Finished dev [unoptimized + debuginfo] target(s) in 0.03s
Running target/debug/deps/interpolate-c5fc2b5f74fbaa21
running 0 tests
test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
Doc-tests interpolate
running 1 test
test src/lib.rs - (line 7) ... FAILED
failures:
---- src/lib.rs - (line 7) stdout ----
error[E0658]: procedural macros cannot be expanded to expressions (see issue #54727)
--> src/lib.rs:12:13
|
8 | let greet = s!("Hello, {name}");
| ^^^^^^^^^^^^^^^^^^^
|
= help: add #![feature(proc_macro_hygiene)] to the crate attributes to enable
error: expected `[`, found `fmt`
--> src/lib.rs:12:13
|
8 | let greet = s!("Hello, {name}");
| ^^^^^^^^^^^^^^^^^^^ expected `[`
error[E0658]: procedural macros cannot be expanded to expressions (see issue #54727)
--> src/lib.rs:13:11
|
9 | let sos = s!("HELP, {name.to_uppercase()}");
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: add #![feature(proc_macro_hygiene)] to the crate attributes to enable
error: expected `[`, found `fmt`
--> src/lib.rs:13:11
|
9 | let sos = s!("HELP, {name.to_uppercase()}");
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `[`
thread 'src/lib.rs - (line 7)' panicked at 'couldn't compile the test', src/librustdoc/test.rs:351:13
note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
failures:
src/lib.rs - (line 7)
test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out
error: test failed, to rerun pass '--doc'
$ rustc --version
rustc 1.34.0-nightly (e1c6d0057 2019-02-22)
$ cargo --version
cargo 1.34.0-nightly (b33ce7fc9 2019-02-19)
The text was updated successfully, but these errors were encountered:
I'm on 1.34.0-nightly and tried to do some trivial things with
s!
but I couldn't get my code to compile.I'm using interpolate 0.2.3. My next step was to run
cargo test -p interpolate
in my project.This is what I got:
The text was updated successfully, but these errors were encountered: