deps: bump criterion 0.5 -> 0.8 and switch to std::hint::black_box
Dependabot opened #10 to bump criterion from 0.5.1 to 0.8.2 but the straight version bump fails to build: criterion::black_box was deprecated in 0.6 and removed/marked deny-warn in 0.8, so the existing `use criterion::{black_box, ...}` produces error: use of deprecated function `criterion::black_box`: use `std::hint::black_box()` instead across every bench callsite. Switch the import to std::hint::black_box (stable since Rust 1.66, well under our MSRV of 1.85) and drop the criterion re-export. This supersedes #10 — same target version, plus the code change Dependabot can't make on its own. Verified locally: cargo bench -p wickra --no-run # builds clean cargo clippy --workspace --all-targets --all-features -- -D warnings cargo test --workspace # 630 passed / 0 failed
This commit is contained in:
@@ -16,7 +16,8 @@
|
||||
//! cargo run -p wickra-examples --bin fetch_btcusdt
|
||||
//! ```
|
||||
|
||||
use criterion::{black_box, criterion_group, criterion_main, BenchmarkId, Criterion, Throughput};
|
||||
use criterion::{criterion_group, criterion_main, BenchmarkId, Criterion, Throughput};
|
||||
use std::hint::black_box;
|
||||
use wickra::{
|
||||
Atr, BatchExt, BollingerBands, Candle, Ema, Indicator, MacdIndicator, Obv, Rsi, Sma,
|
||||
Stochastic, Wma,
|
||||
|
||||
Reference in New Issue
Block a user