Skip to content

Commit 8d35aa9

Browse files
authored
Rollup merge of rust-lang#131616 - RalfJung:const_ip, r=tgross35
merge const_ipv4 / const_ipv6 feature gate into 'ip' feature gate rust-lang#76205 has been closed a while ago, but there are still some functions that reference it. Those functions are all unstable *and* const-unstable. There's no good reason to use a separate feature gate for their const-stability, so this PR moves their const-stability under the same gate as their regular stability, and therefore removes the remaining references to rust-lang#76205.
2 parents b6cfaeb + ddfd2ea commit 8d35aa9

File tree

4 files changed

+0
-22
lines changed

4 files changed

+0
-22
lines changed

core/src/lib.rs

-2
Original file line numberDiff line numberDiff line change
@@ -124,8 +124,6 @@
124124
#![feature(const_hash)]
125125
#![feature(const_heap)]
126126
#![feature(const_index_range_slice_index)]
127-
#![feature(const_ipv4)]
128-
#![feature(const_ipv6)]
129127
#![feature(const_likely)]
130128
#![feature(const_make_ascii)]
131129
#![feature(const_nonnull_new)]

core/src/net/ip_addr.rs

-14
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,6 @@ impl IpAddr {
295295
/// assert_eq!(IpAddr::V4(Ipv4Addr::new(80, 9, 12, 3)).is_global(), true);
296296
/// assert_eq!(IpAddr::V6(Ipv6Addr::new(0, 0, 0x1c9, 0, 0, 0xafc8, 0, 0x1)).is_global(), true);
297297
/// ```
298-
#[rustc_const_unstable(feature = "const_ip", issue = "76205")]
299298
#[unstable(feature = "ip", issue = "27709")]
300299
#[must_use]
301300
#[inline]
@@ -348,7 +347,6 @@ impl IpAddr {
348347
/// true
349348
/// );
350349
/// ```
351-
#[rustc_const_unstable(feature = "const_ip", issue = "76205")]
352350
#[unstable(feature = "ip", issue = "27709")]
353351
#[must_use]
354352
#[inline]
@@ -794,7 +792,6 @@ impl Ipv4Addr {
794792
///
795793
/// // For a complete overview see the IANA IPv4 Special-Purpose Address Registry.
796794
/// ```
797-
#[rustc_const_unstable(feature = "const_ipv4", issue = "76205")]
798795
#[unstable(feature = "ip", issue = "27709")]
799796
#[must_use]
800797
#[inline]
@@ -831,7 +828,6 @@ impl Ipv4Addr {
831828
/// assert_eq!(Ipv4Addr::new(100, 127, 255, 255).is_shared(), true);
832829
/// assert_eq!(Ipv4Addr::new(100, 128, 0, 0).is_shared(), false);
833830
/// ```
834-
#[rustc_const_unstable(feature = "const_ipv4", issue = "76205")]
835831
#[unstable(feature = "ip", issue = "27709")]
836832
#[must_use]
837833
#[inline]
@@ -859,7 +855,6 @@ impl Ipv4Addr {
859855
/// assert_eq!(Ipv4Addr::new(198, 19, 255, 255).is_benchmarking(), true);
860856
/// assert_eq!(Ipv4Addr::new(198, 20, 0, 0).is_benchmarking(), false);
861857
/// ```
862-
#[rustc_const_unstable(feature = "const_ipv4", issue = "76205")]
863858
#[unstable(feature = "ip", issue = "27709")]
864859
#[must_use]
865860
#[inline]
@@ -896,7 +891,6 @@ impl Ipv4Addr {
896891
/// // The broadcast address is not considered as reserved for future use by this implementation
897892
/// assert_eq!(Ipv4Addr::new(255, 255, 255, 255).is_reserved(), false);
898893
/// ```
899-
#[rustc_const_unstable(feature = "const_ipv4", issue = "76205")]
900894
#[unstable(feature = "ip", issue = "27709")]
901895
#[must_use]
902896
#[inline]
@@ -1556,7 +1550,6 @@ impl Ipv6Addr {
15561550
///
15571551
/// // For a complete overview see the IANA IPv6 Special-Purpose Address Registry.
15581552
/// ```
1559-
#[rustc_const_unstable(feature = "const_ipv6", issue = "76205")]
15601553
#[unstable(feature = "ip", issue = "27709")]
15611554
#[must_use]
15621555
#[inline]
@@ -1608,7 +1601,6 @@ impl Ipv6Addr {
16081601
/// assert_eq!(Ipv6Addr::new(0, 0, 0, 0, 0, 0xffff, 0xc00a, 0x2ff).is_unique_local(), false);
16091602
/// assert_eq!(Ipv6Addr::new(0xfc02, 0, 0, 0, 0, 0, 0, 0).is_unique_local(), true);
16101603
/// ```
1611-
#[rustc_const_unstable(feature = "const_ipv6", issue = "76205")]
16121604
#[unstable(feature = "ip", issue = "27709")]
16131605
#[must_use]
16141606
#[inline]
@@ -1637,7 +1629,6 @@ impl Ipv6Addr {
16371629
/// assert_eq!(Ipv6Addr::new(0x2001, 0xdb8, 0, 0, 0, 0, 0, 0).is_unicast(), true);
16381630
/// assert_eq!(Ipv6Addr::new(0xff00, 0, 0, 0, 0, 0, 0, 0).is_unicast(), false);
16391631
/// ```
1640-
#[rustc_const_unstable(feature = "const_ipv6", issue = "76205")]
16411632
#[unstable(feature = "ip", issue = "27709")]
16421633
#[must_use]
16431634
#[inline]
@@ -1689,7 +1680,6 @@ impl Ipv6Addr {
16891680
/// assert_eq!(Ipv6Addr::new(0xfe80, 0, 0, 1, 0, 0, 0, 0).is_unicast_link_local(), true);
16901681
/// assert_eq!(Ipv6Addr::new(0xfe81, 0, 0, 0, 0, 0, 0, 0).is_unicast_link_local(), true);
16911682
/// ```
1692-
#[rustc_const_unstable(feature = "const_ipv6", issue = "76205")]
16931683
#[unstable(feature = "ip", issue = "27709")]
16941684
#[must_use]
16951685
#[inline]
@@ -1714,7 +1704,6 @@ impl Ipv6Addr {
17141704
/// assert_eq!(Ipv6Addr::new(0, 0, 0, 0, 0, 0xffff, 0xc00a, 0x2ff).is_documentation(), false);
17151705
/// assert_eq!(Ipv6Addr::new(0x2001, 0xdb8, 0, 0, 0, 0, 0, 0).is_documentation(), true);
17161706
/// ```
1717-
#[rustc_const_unstable(feature = "const_ipv6", issue = "76205")]
17181707
#[unstable(feature = "ip", issue = "27709")]
17191708
#[must_use]
17201709
#[inline]
@@ -1775,7 +1764,6 @@ impl Ipv6Addr {
17751764
/// assert_eq!(Ipv6Addr::new(0x2001, 0xdb8, 0, 0, 0, 0, 0, 0).is_unicast_global(), false);
17761765
/// assert_eq!(Ipv6Addr::new(0, 0, 0, 0, 0, 0xffff, 0xc00a, 0x2ff).is_unicast_global(), true);
17771766
/// ```
1778-
#[rustc_const_unstable(feature = "const_ipv6", issue = "76205")]
17791767
#[unstable(feature = "ip", issue = "27709")]
17801768
#[must_use]
17811769
#[inline]
@@ -1804,7 +1792,6 @@ impl Ipv6Addr {
18041792
/// );
18051793
/// assert_eq!(Ipv6Addr::new(0, 0, 0, 0, 0, 0xffff, 0xc00a, 0x2ff).multicast_scope(), None);
18061794
/// ```
1807-
#[rustc_const_unstable(feature = "const_ipv6", issue = "76205")]
18081795
#[unstable(feature = "ip", issue = "27709")]
18091796
#[must_use]
18101797
#[inline]
@@ -1864,7 +1851,6 @@ impl Ipv6Addr {
18641851
///
18651852
/// assert_eq!(Ipv6Addr::new(0x2001, 0xdb8, 0, 0, 0, 0, 0, 0).is_ipv4_mapped(), false);
18661853
/// ```
1867-
#[rustc_const_unstable(feature = "const_ipv6", issue = "76205")]
18681854
#[unstable(feature = "ip", issue = "27709")]
18691855
#[must_use]
18701856
#[inline]

core/tests/lib.rs

-3
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,6 @@
1919
#![feature(const_black_box)]
2020
#![feature(const_hash)]
2121
#![feature(const_heap)]
22-
#![feature(const_ip)]
23-
#![feature(const_ipv4)]
24-
#![feature(const_ipv6)]
2522
#![feature(const_likely)]
2623
#![feature(const_nonnull_new)]
2724
#![feature(const_option_ext)]

std/src/lib.rs

-3
Original file line numberDiff line numberDiff line change
@@ -414,9 +414,6 @@
414414
// tidy-alphabetical-start
415415
#![feature(const_collections_with_hasher)]
416416
#![feature(const_hash)]
417-
#![feature(const_ip)]
418-
#![feature(const_ipv4)]
419-
#![feature(const_ipv6)]
420417
#![feature(thread_local_internals)]
421418
// tidy-alphabetical-end
422419
//

0 commit comments

Comments
 (0)