diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2016-03-07 15:42:29 -0800 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2016-03-12 12:31:13 -0800 |
| commit | b53764c73bd722ea22142bace6249d5950066253 (patch) | |
| tree | ecf0066dbdb65bf0cf4600c4560d06edcacff707 /src/libstd/net | |
| parent | 083db64d9050ae6f92628aa869171ac4affb016f (diff) | |
| download | rust-b53764c73bd722ea22142bace6249d5950066253.tar.gz rust-b53764c73bd722ea22142bace6249d5950066253.zip | |
std: Clean out deprecated APIs
Removes all unstable and deprecated APIs prior to the 1.8 release. All APIs that are deprecated in the 1.8 release are sticking around for the rest of this cycle. Some notable changes are: * The `dynamic_lib` module was moved into `rustc_back` as the compiler still relies on a few bits and pieces. * The `DebugTuple` formatter now special-cases an empty struct name with only one field to append a trailing comma.
Diffstat (limited to 'src/libstd/net')
| -rw-r--r-- | src/libstd/net/mod.rs | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/src/libstd/net/mod.rs b/src/libstd/net/mod.rs index d263bf38495..22332b709ce 100644 --- a/src/libstd/net/mod.rs +++ b/src/libstd/net/mod.rs @@ -128,33 +128,3 @@ impl Iterator for LookupHost { pub fn lookup_host(host: &str) -> io::Result<LookupHost> { net_imp::lookup_host(host).map(LookupHost) } - -/// Resolve the given address to a hostname. -/// -/// This function may perform a DNS query to resolve `addr` and may also inspect -/// system configuration to resolve the specified address. If the address -/// cannot be resolved, it is returned in string format. -/// -/// # Examples -/// -/// ```no_run -/// #![feature(lookup_addr)] -/// #![feature(ip_addr)] -/// -/// use std::net::{self, Ipv4Addr, IpAddr}; -/// -/// let ip_addr = "8.8.8.8"; -/// let addr: Ipv4Addr = ip_addr.parse().unwrap(); -/// let hostname = net::lookup_addr(&IpAddr::V4(addr)).unwrap(); -/// -/// println!("{} --> {}", ip_addr, hostname); -/// // Output: 8.8.8.8 --> google-public-dns-a.google.com -/// ``` -#[unstable(feature = "lookup_addr", reason = "recent addition", - issue = "27705")] -#[rustc_deprecated(reason = "ipaddr type is being deprecated", - since = "1.6.0")] -#[allow(deprecated)] -pub fn lookup_addr(addr: &IpAddr) -> io::Result<String> { - net_imp::lookup_addr(addr) -} |
