4f7d898a86
Replace Ipv{4,6}Network::new_unchecked
with Ipv{4,6}Network::new_checked
( #203 )
...
* Replace `Ipv4Network::new_unchecked` with `Ipv4Network::new_checked`
* Replace `Ipv6Network::new_unchecked` with `Ipv6Network::new_checked`
* Update doc test for `Ipv{4,6}Network::new_checked` to use `should_panic`
* Better demonstrate use of `Ipv{4,6}Network::new_checked` in const contexts
* Add back `unsafe_code` lint at the deny level
2025-01-05 21:19:04 -06:00
d665bb6beb
Make the serde feature opt-in instead of opt-out ( #200 )
...
Most people add dependencies without checking their features
or optional dependencies too carefully. This leads to them pulling in
transitive dependencies they likely don't need.
2024-09-24 10:40:42 -05:00
ad46759a55
fix for 0.0.0.0/0 network ( #199 )
2024-09-07 14:22:12 -05:00
cbf8d6b29a
Fix typo ( #198 )
2024-08-09 20:53:42 -05:00
7e0519cd35
fix(deps): update rust crate serde to 1.0.200 ( #196 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-01 12:44:19 -05:00
83a62c9605
Update publish.yml ( #195 )
2024-05-01 09:12:06 -05:00
c840f27855
chore(deps): update rust crate serde_json to 1.0.116 ( #193 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-01 09:10:53 -05:00
4b16661585
fix(deps): update rust crate serde to 1.0.199 ( #194 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-01 09:10:23 -05:00
a0831a77b9
chore: setup release plz ( #192 )
2024-04-30 21:59:49 -05:00
f0fd0521e1
fix: use associated constants ( #191 )
2024-04-30 21:49:56 -05:00
bb51dee73a
Update Rust crate criterion to 0.5.1 ( #172 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-30 21:43:09 -05:00
b5f5b79d23
Update actions/checkout action to v4 ( #182 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-30 21:42:39 -05:00
70d1f74e29
ipv6: rewrite core ipv6 methods to operate on u128s ( #187 )
...
* errors: adds `From<AddrParseError>` for `IpNetworkError`
* ipv4: adds safety comment to `new_unchecked` and debug assertions to verify compliance
* ipv6: rewrite core ipv6 methods to operate on `u128`s
2024-04-30 21:41:17 -05:00
068959e2c4
github: move to dtolnay/rust-toolchain and run clippy ( #189 )
2024-04-29 22:25:29 -05:00
241b1dcdf8
netsize: Hash implementation to match PartialEq ( #186 )
...
* netsize: hash implementation to match PartialEq
* netsize: Prefer `From` over `Into`, add documentation, and add Hash and PartialEq tests
2024-04-29 22:23:28 -05:00
6e32dd2e88
Update Rust crate schemars to 0.8.17 ( #184 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-28 13:42:11 -05:00
a1966d4089
Add const unsafe new_unchecked
to Ipv4Network
& Ipv6Network
( #185 )
...
* Add const unsafe `new_unchecked` to `Ipv4Network` & `Ipv6Network`
* New tests added for `new_unchecked` functions
2023-12-21 09:03:04 -06:00
817b5babed
Update Rust crate schemars to 0.8.15 ( #183 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-09-18 12:04:15 -05:00
9bf407e634
Update Rust crate schemars to 0.8.13 ( #181 )
...
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-08-28 19:09:51 -05:00
1bd937e90c
Add Ipv6Network::nth
to get the nth address (take two) ( #176 )
...
* Add `Ipv6Network::nth` to get the nth address
Works the same as `Ipv4Network::nth`, but using a `u128` index instead
of `u32`.
* add IpNetwork v6 nth test
---------
Co-authored-by: Josh Triplett <josh@joshtriplett.org >
2023-06-13 21:17:39 -05:00
d19ac33071
Added needed traits to NetworkSize
( #175 )
...
* Add conversion and better equality traits to NetworkSize
* Add tests for NetworkSize conversion/equality
* impl Display for NetworkSize
2023-06-13 21:14:02 -05:00
19aafee3c8
Update criterion requirement from 0.4.0 to 0.5.0
...
Updates the requirements on [criterion](https://github.com/bheisler/criterion.rs ) to permit the latest version.
- [Changelog](https://github.com/bheisler/criterion.rs/blob/master/CHANGELOG.md )
- [Commits](https://github.com/bheisler/criterion.rs/compare/0.4.0...0.5.0 )
---
updated-dependencies:
- dependency-name: criterion
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com >
2023-05-24 20:33:33 -05:00
a01d32ede8
Update katyo/publish-crates action to v2
2023-04-23 19:53:43 -05:00
b4c0554d11
Update actions/checkout action to v3
2023-04-23 19:53:26 -05:00
3a2d1da053
Update Rust crate schemars to 0.8.12
2023-04-23 19:53:07 -05:00
98914649d6
Add renovate.json
2023-04-23 15:04:05 -05:00
0bb1ea8fd4
Replace assert_eq with assert for bool comparison
2023-04-07 14:36:02 -05:00
b624487f72
Use cargo clippy --fix to autofix code
2023-04-07 14:36:02 -05:00
dff59ea0a5
Add a reference where missing
2023-04-07 12:00:03 -05:00
432f7342e3
Cleanup mask for Ipv4Addr
2023-04-07 12:00:03 -05:00
b15eb54695
Shrink the enumerate call on mask
2023-04-07 12:00:03 -05:00
ec79428c75
Cleanup both size functions
2023-04-07 12:00:03 -05:00
a96f30d64e
Simplify FromStr for Ipv6Network
2023-04-07 12:00:03 -05:00
ef3f536d48
Make parse_prefix more idiomatic
2023-04-07 12:00:03 -05:00
a42e9d9593
Update criterion requirement from 0.3.4 to 0.4.0 ( #162 )
...
Updates the requirements on [criterion](https://github.com/bheisler/criterion.rs ) to permit the latest version.
- [Release notes](https://github.com/bheisler/criterion.rs/releases )
- [Changelog](https://github.com/bheisler/criterion.rs/blob/master/CHANGELOG.md )
- [Commits](https://github.com/bheisler/criterion.rs/compare/0.3.4...0.4.0 )
---
updated-dependencies:
- dependency-name: criterion
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com >
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-09-13 16:01:00 -05:00
2c9bf9b29b
Update does-it-json requirement from 0.0.3 to 0.0.4 ( #161 )
...
Updates the requirements on [does-it-json](https://github.com/ahl/does-it-json ) to permit the latest version.
- [Release notes](https://github.com/ahl/does-it-json/releases )
- [Commits](https://github.com/ahl/does-it-json/compare/v0.0.3...v0.0.4 )
---
updated-dependencies:
- dependency-name: does-it-json
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-11 08:58:10 -05:00
1b6904bfc7
Cut a new release for v0.20.0 ( #158 )
v0.20.0
2022-06-30 22:00:50 -05:00
ab6f1012b3
Correct and validate JsonSchema for Ipv4Network, Ipv6Network, and IpNetwork ( #157 )
...
* show failed test cases
* add proper JSON schema
2022-06-28 21:27:13 -05:00
5146125c35
Merge pull request #155 from sancho20021/153-JsonSchema-for-IPNetwork
...
[#153 ] Add optional JSONSchema implementation for IpNetwork
2022-05-31 18:47:26 -05:00
86dbbd997a
[ #153 ] Add optional JSONSchema implementation for IpNetwork
...
Problem: No instance of `JSONSchema` is implemented for
`IpNetwork`.
Solution: Derive implementation via `schemars`. Add corresponding
feature to the crate.
2022-05-31 23:37:44 +03:00
372f9bdbb7
Add workflow_dispatch
2022-04-13 23:11:42 -05:00
c0e04d534a
Merge pull request #151 from achanda/update-publish-job
...
Update publish.yml
2022-04-13 23:04:52 -05:00
7c9ff1bc30
Update publish.yml
2022-04-13 23:04:38 -05:00
6d4e4ba47a
Merge pull request #150 from achanda/autopublish
...
Auto publish to crates.io on new tag push
v0.19.2
v0.19.1
v0.19.3
2022-04-13 22:59:50 -05:00
e842e0edc0
Auto publish to crates.io on new tag push
2022-04-13 22:56:43 -05:00
61550eda45
Merge pull request #149 from achanda/v0.19.0
...
Cut a new release for v0.19.0
v0.19.0
2022-04-12 22:47:18 -05:00
3503e4c094
Cut a new release for v0.19.0
...
This one is still a manual release, I am hoping to get this automated
soon.
2022-04-12 22:44:10 -05:00
91528476a9
Merge pull request #148 from achanda/remove-html_root_url
...
Remove the redundant html_root_url attribute
2022-04-12 22:38:29 -05:00
501e5533d7
Remove the redundant html_root_url attribute
2022-04-12 22:35:37 -05:00
7120b93837
Merge pull request #144 from paolobarbolini/collect-str
...
Remove useless allocation when serializing
2021-12-29 10:24:38 -06:00