From 3681dc443116a8f3b48595fea3d584187bef3599 Mon Sep 17 00:00:00 2001 From: Baitinq Date: Sun, 30 Oct 2022 13:01:39 +0100 Subject: Misc: Remove unneeded dependencies --- lib/Cargo.toml | 2 +- lib/src/lib.rs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/Cargo.toml b/lib/Cargo.toml index a43e09e..35a385c 100644 --- a/lib/Cargo.toml +++ b/lib/Cargo.toml @@ -6,4 +6,4 @@ edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -serde = { version = "1.0", features = ["derive"] } +serde = { version = "1.0", features = ["derive", "rc"] } diff --git a/lib/src/lib.rs b/lib/src/lib.rs index a11637f..2f0b750 100644 --- a/lib/src/lib.rs +++ b/lib/src/lib.rs @@ -1,4 +1,5 @@ pub mod lib { + use serde::{Serialize,Deserialize}; use std::sync::Arc; use std::hash::{Hash, Hasher}; @@ -33,6 +34,7 @@ pub mod lib { } } + //Reverse ordering as priority: 1 is less than priority: 2 impl Ord for IndexedResource { fn cmp(&self, other: &Self) -> Ordering { self.priority.cmp(&other.priority).reverse() @@ -46,5 +48,4 @@ pub mod lib { } } - } \ No newline at end of file -- cgit 1.4.1