Skip to content

Commit 8459d6b

Browse files
committed
Fix std doctest build for SGX target.
1 parent 3b1b0ef commit 8459d6b

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

library/std/src/os/fd/raw.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ use crate::io;
1616
use crate::os::hermit::io::OwnedFd;
1717
#[cfg(all(not(target_os = "hermit"), not(target_os = "motor")))]
1818
use crate::os::raw;
19-
#[cfg(all(doc, not(target_arch = "wasm32")))]
19+
#[cfg(all(doc, not(any(target_arch = "wasm32", target_env = "sgx"))))]
2020
use crate::os::unix::io::AsFd;
2121
#[cfg(unix)]
2222
use crate::os::unix::io::OwnedFd;

library/std/src/sys/net/connection/sgx.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,8 @@ impl fmt::Debug for TcpStream {
6868
///
6969
/// SGX doesn't support DNS resolution but rather accepts hostnames in
7070
/// the same place as socket addresses. So, to make e.g.
71-
/// ```rust
72-
/// TcpStream::connect("example.com:80")`
71+
/// ```rust,ignore (incomplete example)
72+
/// TcpStream::connect("example.com:80")
7373
/// ```
7474
/// work, the DNS lookup returns a special error (`NonIpSockAddr`) instead,
7575
/// which contains the hostname being looked up. When `.to_socket_addrs()`

0 commit comments

Comments
 (0)