Stabilize IpAddr::is_ipv4 and is_ipv6 as const by CDirkx · Pull Request #76226 · rust-lang/rust (original) (raw)

Conversation

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters

[ Show hidden characters]({{ revealButtonHref }})

CDirkx

Insta-stabilize the methods is_ipv4 and is_ipv6 of std:🥅:IpAddr as const, in the same way as PR#76198.

Possible because of the recent stabilization of const control flow.

Part of #76225 and #76205.

@rust-highfive

r? @joshtriplett

(rust_highfive has picked a reviewer for you, use r? to override)

This was referenced

Sep 2, 2020

@scottmcm scottmcm added the needs-fcp

This change is insta-stable, so needs a completed FCP to proceed.

label

Sep 2, 2020

@jonas-schievink jonas-schievink added the relnotes

Marks issues that should be documented in the release notes of the next release.

label

Sep 13, 2020

@Dylan-DPC-zz

@KodrAus

@rfcbot fcp merge

This is another set of constifying for boolean-style match methods. This time for IpAddr:

impl IpAddr { pub const fn is_ipv4(&self) -> bool; pub const fn is_ipv6(&self) -> bool; }

@rfcbot

Team member @KodrAus has proposed to merge this. The next step is review by the rest of the tagged team members:

No concerns currently listed.

Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up!

See this document for info about what commands tagged team members can give me.

@rfcbot

🔔 This is now entering its final comment period, as per the review above. 🔔

@rfcbot

The final comment period, with a disposition to merge, as per the review above, is now complete.

As the automated representative of the governance process, I would like to thank the author for their work and everyone else who contributed.

The RFC will be merged soon.

dtolnay

@dtolnay

@bors

📌 Commit b5746fe0b1f03b6a6e2f827165e38f7fa23b5295 has been approved by dtolnay

@bors bors removed the S-waiting-on-team

Status: Awaiting decision from the relevant subteam (see the T- label).

label

Nov 23, 2020

@bors bors added the S-waiting-on-bors

Status: Waiting on bors to run and complete tests. Bors will change the label on completion.

label

Nov 23, 2020

@CDirkx

Insta-stabilize the methods is_ipv4 and is_ipv6 of IpAddr.

Possible because of the recent stabilization of const control flow.

Also adds a test for these methods in a const context.

@CDirkx

@CDirkx

I bumped the version to 1.50.0

@dtolnay

Good catch, thanks.
@bors r+

@bors

📌 Commit 4613bc9 has been approved by dtolnay

@bors

@bors

@bors bors mentioned this pull request

Nov 23, 2020

@RalfJung RalfJung added the A-const-eval

Area: Constant evaluation, covers all const contexts (static, const fn, ...)

label

Dec 1, 2024

Labels

A-const-eval

Area: Constant evaluation, covers all const contexts (static, const fn, ...)

disposition-merge

This issue / PR is in PFCP or FCP with a disposition to merge it.

finished-final-comment-period

The final comment period is finished for this PR / Issue.

merged-by-bors

This PR was explicitly merged by bors.

needs-fcp

This change is insta-stable, so needs a completed FCP to proceed.

relnotes

Marks issues that should be documented in the release notes of the next release.

S-waiting-on-bors

Status: Waiting on bors to run and complete tests. Bors will change the label on completion.

T-libs-api

Relevant to the library API team, which will review and decide on the PR/issue.