mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-29 05:14:52 +00:00
13 lines
510 B
Rust
13 lines
510 B
Rust
//! This module re-exports the criterion API but picks the right backend depending on whether
|
|
//! the benchmarks are built to run locally or with codspeed.
|
|
//! The compat layer is required because codspeed doesn't support all platforms.
|
|
//! See [#12662](https://github.com/astral-sh/ruff/issues/12662)
|
|
|
|
#[cfg(not(codspeed))]
|
|
pub use criterion::*;
|
|
|
|
#[cfg(not(codspeed))]
|
|
pub type BenchmarkGroup<'a> = criterion::BenchmarkGroup<'a, measurement::WallTime>;
|
|
|
|
#[cfg(codspeed)]
|
|
pub use codspeed_criterion_compat::*;
|