Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions library/core/src/os/darwin/objc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ pub type SEL = *mut objc_selector;
///
/// # Example
///
/// ```no_run
#[cfg_attr(target_os = "macos", doc = "```no_run")]
#[cfg_attr(not(target_os = "macos"), doc = "```ignore (needs macos)")]
/// #![feature(darwin_objc)]
/// use core::os::darwin::objc;
///
Expand All @@ -93,7 +94,8 @@ pub macro class($classname:expr) {{
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "macos", doc = "```no_run")]
#[cfg_attr(not(target_os = "macos"), doc = "```ignore (needs macos)")]
/// #![feature(darwin_objc)]
/// use core::os::darwin::objc;
///
Expand Down
48 changes: 32 additions & 16 deletions library/std/src/os/aix/fs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -33,7 +34,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -50,7 +52,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -67,7 +70,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -84,7 +88,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -101,7 +106,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -118,7 +124,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -138,7 +145,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -155,7 +163,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -174,7 +183,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -191,7 +201,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -210,7 +221,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -227,7 +239,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -246,7 +259,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -263,7 +277,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand All @@ -280,7 +295,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "aix", doc = "```no_run")]
#[cfg_attr(not(target_os = "aix"), doc = "```ignore (needs aix)")]
/// use std::fs;
/// use std::io;
/// use std::os::aix::fs::MetadataExt;
Expand Down
12 changes: 10 additions & 2 deletions library/std/src/os/fortanix_sgx/ffi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@
//!
//! # Examples
//!
//! ```
#![cfg_attr(all(target_vendor = "fortanix", target_env = "sgx"), doc = "```")]
#![cfg_attr(
not(all(target_vendor = "fortanix", target_env = "sgx")),
doc = "```ignore (needs aix)"
)]
//! use std::ffi::OsString;
//! use std::os::fortanix_sgx::ffi::OsStringExt;
//!
Expand All @@ -17,7 +21,11 @@
//! assert_eq!(bytes, b"foo");
//! ```
//!
//! ```
#![cfg_attr(all(target_vendor = "fortanix", target_env = "sgx"), doc = "```")]
#![cfg_attr(
not(all(target_vendor = "fortanix", target_env = "sgx")),
doc = "```ignore (needs aix)"
)]
//! use std::ffi::OsStr;
//! use std::os::fortanix_sgx::ffi::OsStrExt;
//!
Expand Down
3 changes: 2 additions & 1 deletion library/std/src/os/freebsd/net.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ pub impl(self) trait UnixSocketExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "freebsd", doc = "```no_run")]
#[cfg_attr(not(target_os = "freebsd"), doc = "```ignore (needs freebsd)")]
/// #![feature(unix_socket_ancillary_data)]
/// use std::os::freebsd::net::UnixSocketExt;
/// use std::os::unix::net::UnixDatagram;
Expand Down
6 changes: 4 additions & 2 deletions library/std/src/os/hermit/ffi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
//!
//! # Examples
//!
//! ```
#![cfg_attr(target_os = "hermit", doc = "```")]
#![cfg_attr(not(target_os = "hermit"), doc = "```ignore (needs hermit)")]
//! use std::ffi::OsString;
//! use std::os::hermit::ffi::OsStringExt;
//!
Expand All @@ -17,7 +18,8 @@
//! assert_eq!(bytes, b"foo");
//! ```
//!
//! ```
#![cfg_attr(target_os = "hermit", doc = "```")]
#![cfg_attr(not(target_os = "hermit"), doc = "```ignore (needs hermit)")]
//! use std::ffi::OsStr;
//! use std::os::hermit::ffi::OsStrExt;
//!
Expand Down
48 changes: 32 additions & 16 deletions library/std/src/os/hurd/fs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -33,7 +34,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -50,7 +52,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -67,7 +70,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -84,7 +88,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -101,7 +106,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -118,7 +124,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -138,7 +145,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -155,7 +163,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -174,7 +183,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -191,7 +201,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -210,7 +221,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -227,7 +239,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -246,7 +259,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -263,7 +277,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand All @@ -280,7 +295,8 @@ pub trait MetadataExt {
///
/// # Examples
///
/// ```no_run
#[cfg_attr(target_os = "hurd", doc = "```no_run")]
#[cfg_attr(not(target_os = "hurd"), doc = "```ignore (needs hurd)")]
/// use std::fs;
/// use std::io;
/// use std::os::hurd::fs::MetadataExt;
Expand Down
Loading
Loading