protocols/gossipsub: Revert back to wasm_timer for interval (#2506)

Removed the custom interval implementation and removes support for
wasm32-unknown-unknown. See https://github.com/libp2p/rust-libp2p/issues/2497
for details.

Co-authored-by: Diva M <divma@protonmail.com>
Co-authored-by: Max Inden <mail@max-inden.de>
This commit is contained in:
Age Manning
2022-02-14 21:24:58 +11:00
committed by GitHub
parent 7fc342e6c0
commit 60666f5455
15 changed files with 37 additions and 229 deletions

View File

@ -21,13 +21,13 @@
//! This implements a time-based LRU cache for checking gossipsub message duplicates.
use fnv::FnvHashMap;
use instant::Instant;
use std::collections::hash_map::{
self,
Entry::{Occupied, Vacant},
};
use std::collections::VecDeque;
use std::time::Duration;
use wasm_timer::Instant;
struct ExpiringElement<Element> {
/// The element that expires