lits 0.3.1

A proc-macro collection that parses human-readable literals at compile time.
Documentation
# Rust Lits

A proc-macro collection that parses human-readable strings at compile time.

## Installation

```sh
cargo add lits
```

## Usage

```rust
use lits::*;

assert_eq!(duration!("7 days"), Duration::from_secs(7 * 24 * 60 * 60));

assert_eq!(datetime!("1970-01-01T00:00:00Z"), UNIX_EPOCH);

assert_eq!(bytes!("1 kiB"), 1024);
assert_eq!(bytes!("1 kB"), 1000);
```

## Features

- [humantime]
  - `duration!()``humantime::parse_duration()`
  - `datetime!()``humantime::parse_rfc3339_weak()`
- [bytesize]
  - `bytes!()``FromStr::parse::<bytesize::ByteSize>().as_u64()`

## License

MIT License.

[humantime]: https://crates.io/crates/humantime
[bytesize]: https://crates.io/crates/bytesize