servo / html5ever

High-performance browser-grade HTML5 parser
Other
2.1k stars 215 forks source link

cargo bench fails #501

Closed ultrasaurus closed 1 year ago

ultrasaurus commented 1 year ago

Repro steps:

git clone git@github.com:servo/html5ever.git
cd html5ever/
git submodule update --init
cargo bench

result:

error[E0463]: can't find crate for `criterion`
 --> xml5ever/benches/xml5ever.rs:2:1
  |
2 | extern crate criterion;
  | ^^^^^^^^^^^^^^^^^^^^^^^ can't find crate

error: cannot find macro `criterion_group` in this scope
  --> xml5ever/benches/xml5ever.rs:74:1
   |
74 | criterion_group!(benches, xml5ever_benchmarks);
   | ^^^^^^^^^^^^^^^
ultrasaurus commented 1 year ago

oops -- upgrading cargo made it ok

was

$ cargo --version
cargo 1.68.0-nightly (c994a4a63 2022-12-18)

this seems to work fine

cargo --version
cargo 1.70.0 (ec8a8a0ca 2023-04-25)