stdarch-test: use std::sync::LazyLock instead of lazy_static!
This commit is contained in:
parent
5cb1e01a94
commit
7ff9bcfd1e
3 changed files with 2 additions and 8 deletions
|
|
@ -726,7 +726,6 @@ dependencies = [
|
|||
"assert-instr-macro",
|
||||
"cc",
|
||||
"cfg-if",
|
||||
"lazy_static",
|
||||
"rustc-demangle",
|
||||
"simd-test-macro",
|
||||
"wasmprinter",
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@ edition = "2024"
|
|||
[dependencies]
|
||||
assert-instr-macro = { path = "../assert-instr-macro" }
|
||||
simd-test-macro = { path = "../simd-test-macro" }
|
||||
lazy_static = "1.0"
|
||||
rustc-demangle = "0.1.8"
|
||||
cfg-if = "1.0"
|
||||
|
||||
|
|
|
|||
|
|
@ -6,14 +6,12 @@
|
|||
#![deny(rust_2018_idioms)]
|
||||
#![allow(clippy::missing_docs_in_private_items, clippy::print_stdout)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate lazy_static;
|
||||
#[macro_use]
|
||||
extern crate cfg_if;
|
||||
|
||||
pub use assert_instr_macro::*;
|
||||
pub use simd_test_macro::*;
|
||||
use std::{cmp, collections::HashSet, env, hash, hint::black_box, str};
|
||||
use std::{cmp, collections::HashSet, env, hash, hint::black_box, str, sync::LazyLock};
|
||||
|
||||
cfg_if! {
|
||||
if #[cfg(target_arch = "wasm32")] {
|
||||
|
|
@ -25,9 +23,7 @@ cfg_if! {
|
|||
}
|
||||
}
|
||||
|
||||
lazy_static! {
|
||||
static ref DISASSEMBLY: HashSet<Function> = disassemble_myself();
|
||||
}
|
||||
static DISASSEMBLY: LazyLock<HashSet<Function>> = LazyLock::new(disassemble_myself);
|
||||
|
||||
#[derive(Debug)]
|
||||
struct Function {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue