Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tests fail to compile on 1.34.0-nightly #8

Open
RalfNorthman opened this issue Feb 24, 2019 · 1 comment
Open

Tests fail to compile on 1.34.0-nightly #8

RalfNorthman opened this issue Feb 24, 2019 · 1 comment

Comments

@RalfNorthman
Copy link

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)
@Boscop
Copy link

Boscop commented Aug 26, 2019

@anowell Any update on this? :)
I'm also running into these errors on the latest nightly..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants