From 4c1595c5629a17b001492a37d6346e29f46a553e Mon Sep 17 00:00:00 2001 From: Trevor Spiteri Date: Mon, 19 Oct 2020 10:50:38 +0200 Subject: [PATCH] test fixed-macro rustdoc example --- Cargo.toml | 1 + src/lib.rs | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 18f8cd2..f9ccb9f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -34,6 +34,7 @@ num-traits = { version = "0.2.12", default-features = false, optional = true } serde = { version = "1.0.60", default-features = false, optional = true } [dev-dependencies] +fixed-macro = "1" rand = { version = "0.7", default-features = false } rand_xoshiro = "0.4" criterion = "0.3" diff --git a/src/lib.rs b/src/lib.rs index 3e143ef..9dfac0c 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -145,7 +145,7 @@ cannot use [`From`] as we have less fractional bits, so we use The [*fixed-macro* crate] provides a convenient macro to write down fixed-point constants literally in the code. -```ignore +```rust use fixed::types::I16F16; use fixed_macro::fixed;