rany

Crates.iorany
lib.rsrany
version0.1.11
sourcesrc
created_at2023-12-25 13:23:35.738079
updated_at2024-06-13 10:34:54.057097
descriptiondecode/encode usize to radix any
homepagehttps://github.com/i18n-site/rust/tree/main/rany
repositoryhttps://github.com/i18n-site/rust.git
max_upload_size
id1080241
size6,324
(3tieto)

documentation

README

rany : decode/encode usize to radix any

#[test]
fn test() {
  for num in [u64::MAX, 1234567890, 0, 1] {
    #[cfg(feature = "url")]
    {
      use rany::URL;
      let encode = URL.estr(num);
      let decode = URL.dstr(&encode);
      assert_eq!(num, decode);
    }
    #[cfg(feature = "b255")]
    {
      use rany::{Rany, B255};
      let encode = B255.e(num);
      assert_eq!(num, B255.d(&encode));
    }
  }
}
Commit count: 3

cargo fmt