Skip to content

Commit 1dc31b7

Browse files
committed
Merge pull request #31552 from alexcrichton/beta-next
Backport one last PR for beta 3
2 parents 9d6e26d + 71afb6b commit 1dc31b7

File tree

5 files changed

+9
-23
lines changed

5 files changed

+9
-23
lines changed

mk/main.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ CFG_RELEASE_NUM=1.7.0
1818
# An optional number to put after the label, e.g. '.2' -> '-beta.2'
1919
# NB Make sure it starts with a dot to conform to semver pre-release
2020
# versions (section 9)
21-
CFG_PRERELEASE_VERSION=.2
21+
CFG_PRERELEASE_VERSION=.3
2222

2323
# Append a version-dependent hash to each library, so we can install different
2424
# versions in the same place

src/libstd/net/addr.rs

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,7 @@ use fmt;
1414
use hash;
1515
use io;
1616
use mem;
17-
use net::{lookup_host, ntoh, hton, Ipv4Addr, Ipv6Addr};
18-
#[allow(deprecated)]
19-
use net::IpAddr;
17+
use net::{lookup_host, ntoh, hton, IpAddr, Ipv4Addr, Ipv6Addr};
2018
use option;
2119
use sys::net::netc as c;
2220
use sys_common::{FromInner, AsInner, IntoInner};
@@ -50,10 +48,7 @@ pub struct SocketAddrV6 { inner: c::sockaddr_in6 }
5048

5149
impl SocketAddr {
5250
/// Creates a new socket address from the (ip, port) pair.
53-
#[unstable(feature = "ip_addr", reason = "recent addition", issue = "27801")]
54-
#[rustc_deprecated(reason = "ip type too small a type to pull its weight",
55-
since = "1.6.0")]
56-
#[allow(deprecated)]
51+
#[stable(feature = "ip_addr", since = "1.7.0")]
5752
pub fn new(ip: IpAddr, port: u16) -> SocketAddr {
5853
match ip {
5954
IpAddr::V4(a) => SocketAddr::V4(SocketAddrV4::new(a, port)),
@@ -62,10 +57,7 @@ impl SocketAddr {
6257
}
6358

6459
/// Returns the IP address associated with this socket address.
65-
#[unstable(feature = "ip_addr", reason = "recent addition", issue = "27801")]
66-
#[rustc_deprecated(reason = "too small a type to pull its weight",
67-
since = "1.6.0")]
68-
#[allow(deprecated)]
60+
#[stable(feature = "ip_addr", since = "1.7.0")]
6961
pub fn ip(&self) -> IpAddr {
7062
match *self {
7163
SocketAddr::V4(ref a) => IpAddr::V4(*a.ip()),
@@ -359,7 +351,6 @@ impl ToSocketAddrs for SocketAddrV6 {
359351
}
360352

361353
#[stable(feature = "rust1", since = "1.0.0")]
362-
#[allow(deprecated)]
363354
impl ToSocketAddrs for (IpAddr, u16) {
364355
type Iter = option::IntoIter<SocketAddr>;
365356
fn to_socket_addrs(&self) -> io::Result<option::IntoIter<SocketAddr>> {

src/libstd/net/ip.rs

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,15 @@ use sys::net::netc as c;
2222
use sys_common::{AsInner, FromInner};
2323

2424
/// An IP address, either an IPv4 or IPv6 address.
25-
#[unstable(feature = "ip_addr", reason = "recent addition", issue = "27801")]
26-
#[rustc_deprecated(reason = "too small a type to pull its weight",
27-
since = "1.6.0")]
25+
#[stable(feature = "ip_addr", since = "1.7.0")]
2826
#[derive(Copy, Clone, Eq, PartialEq, Debug, Hash, PartialOrd, Ord)]
29-
#[allow(deprecated)]
3027
pub enum IpAddr {
3128
/// Representation of an IPv4 address.
32-
V4(Ipv4Addr),
29+
#[stable(feature = "ip_addr", since = "1.7.0")]
30+
V4(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.7.0"))] Ipv4Addr),
3331
/// Representation of an IPv6 address.
34-
V6(Ipv6Addr),
32+
#[stable(feature = "ip_addr", since = "1.7.0")]
33+
V6(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.7.0"))] Ipv6Addr),
3534
}
3635

3736
/// Representation of an IPv4 address.

src/libstd/net/mod.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ use io::{self, Error, ErrorKind};
1818
use sys_common::net as net_imp;
1919

2020
#[stable(feature = "rust1", since = "1.0.0")]
21-
#[allow(deprecated)]
2221
pub use self::ip::{IpAddr, Ipv4Addr, Ipv6Addr, Ipv6MulticastScope};
2322
#[stable(feature = "rust1", since = "1.0.0")]
2423
pub use self::addr::{SocketAddr, SocketAddrV4, SocketAddrV6, ToSocketAddrs};

src/libstd/net/parser.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ use prelude::v1::*;
1717

1818
use error::Error;
1919
use fmt;
20-
#[allow(deprecated)]
2120
use net::{IpAddr, Ipv4Addr, Ipv6Addr, SocketAddr, SocketAddrV4, SocketAddrV6};
2221
use str::FromStr;
2322

@@ -262,7 +261,6 @@ impl<'a> Parser<'a> {
262261
self.read_atomically(|p| p.read_ipv6_addr_impl())
263262
}
264263

265-
#[allow(deprecated)]
266264
fn read_ip_addr(&mut self) -> Option<IpAddr> {
267265
let ipv4_addr = |p: &mut Parser| p.read_ipv4_addr().map(IpAddr::V4);
268266
let ipv6_addr = |p: &mut Parser| p.read_ipv6_addr().map(IpAddr::V6);
@@ -308,7 +306,6 @@ impl<'a> Parser<'a> {
308306
}
309307

310308
#[stable(feature = "rust1", since = "1.0.0")]
311-
#[allow(deprecated)]
312309
impl FromStr for IpAddr {
313310
type Err = AddrParseError;
314311
fn from_str(s: &str) -> Result<IpAddr, AddrParseError> {

0 commit comments

Comments
 (0)