1

env: Use VScode + RA with nightly Rust toolchain.

e.g. bench.rs file

#![feature(test)]

extern crate test;
use test::*;

#[bench]
fn demo(b:& Bencher){
       ...

}

When click Debug lens trigger "Multiple compilation artifacts are not supported" error, but click Run Bench works normally.

Ironically, if you put the demo fn in other bin lib test example target everything works fine. Why debug bench fn in bench target occur problems?

Larry
  • 155
  • 7

1 Answers1

1

This is a bug in rust-analyzer. See issue #12645.

I sent a PR to fix it: #12655.

Chayim Friedman
  • 47,971
  • 5
  • 48
  • 77