Skip to content

Latest commit

 

History

History
38 lines (27 loc) · 1.47 KB

Readme.md

File metadata and controls

38 lines (27 loc) · 1.47 KB

Module :: winterval

experimental rust-status docs.rs Open in Gitpod discord

Interval adapter for both open/closed implementations of intervals ( ranges ).

Sample

#[ cfg( feature = "use_std" ) ]
{
  use winterval::*;

  let src = 2..5;
  assert_eq!( src.closed(), ( 2, 4 ) );

  let src = 2..=4;
  assert_eq!( src.closed(), ( 2, 4 ) );
}

To add to your project

cargo add winterval

Try out from the repository

git clone https://github.com/Wandalen/wTools
cd wTools
cd sample/rust/winterval_trivial
cargo run