From 78e46dd405996e319e10def64bb0fecf2596beb4 Mon Sep 17 00:00:00 2001 From: Ryan Lopopolo Date: Sun, 14 Feb 2021 19:10:56 -0800 Subject: [PATCH] Fix README example and crate-level docs example rendering --- Cargo.toml | 2 +- README.md | 12 +++++++++--- src/lib.rs | 12 +++++++++--- 3 files changed, 19 insertions(+), 7 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index a448ac9db..45295fa7c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "roe" -version = "0.0.1" # remember to set `html_root_url` in `src/lib.rs`. +version = "0.0.2" # remember to set `html_root_url` in `src/lib.rs`. authors = ["Ryan Lopopolo "] license = "MIT" edition = "2018" diff --git a/README.md b/README.md index abbc81370..ae31d7190 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,7 @@ Add this to your `Cargo.toml`: ```toml [dependencies] -roe = "0.0.1" +roe = "0.0.2" ``` Then convert case like: @@ -43,8 +43,14 @@ Then convert case like: ```rust use roe::{LowercaseMode, UppercaseMode}; -assert_eq!(roe::lowercase(b"Artichoke Ruby", LowercaseMode::Ascii).collect::>(), b"artichoke ruby"); -assert_eq!(roe::uppercase("Αύριο".as_bytes(), UppercaseMode::Full).collect::>(), "ΑΎΡΙΟ".as_bytes()); +assert_eq!( + roe::lowercase(b"Artichoke Ruby", LowercaseMode::Ascii).collect::>(), + b"artichoke ruby" +); +assert_eq!( + roe::uppercase("Αύριο".as_bytes(), UppercaseMode::Full).collect::>(), + "ΑΎΡΙΟ".as_bytes() +); ``` ## Crate Features diff --git a/src/lib.rs b/src/lib.rs index 125245483..c409bdb0d 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -42,8 +42,14 @@ //! //! ``` //! # use roe::{LowercaseMode, UppercaseMode}; -//! assert_eq!(roe::lowercase(b"Artichoke Ruby", LowercaseMode::Ascii).collect::>(), b"artichoke ruby"); -//! assert_eq!(roe::uppercase("Αύριο".as_bytes(), UppercaseMode::Full).collect::>(), "ΑΎΡΙΟ".as_bytes()); +//! assert_eq!( +//! roe::lowercase(b"Artichoke Ruby", LowercaseMode::Ascii).collect::>(), +//! b"artichoke ruby" +//! ); +//! assert_eq!( +//! roe::uppercase("Αύριο".as_bytes(), UppercaseMode::Full).collect::>(), +//! "ΑΎΡΙΟ".as_bytes() +//! ); //! ``` //! //! @@ -72,7 +78,7 @@ //! [`Vec`]: https://doc.rust-lang.org/alloc/vec/struct.Vec.html #![no_std] -#![doc(html_root_url = "https://docs.rs/roe/0.0.1")] +#![doc(html_root_url = "https://docs.rs/roe/0.0.2")] #[cfg(any(feature = "alloc", test))] extern crate alloc;