Skip to content

Commit 4b35702

Browse files
authored
Rollup merge of #153774 - sardok:fix_sgx_std_doctest_build, r=WaffleLapkin
Fix std doctest build for SGX target. This PR fixes standard library doctest build for `x86_64-fortanix-unknown-sgx` target.
2 parents 4625821 + 8459d6b commit 4b35702

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

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)