Add #![allow(unexpected_cfgs)] in preparation of global --check-cfg

This commit is contained in:
Loïc BRANSTETT 2022-02-26 01:31:36 +01:00
parent 08e1e67b49
commit a93c7abc69
2 changed files with 4 additions and 0 deletions

View file

@ -817,6 +817,7 @@ impl<T> MaybeUninit<T> {
/// ### Correct usage of this method:
///
/// ```rust
/// # #![allow(unexpected_cfgs)]
/// use std::mem::MaybeUninit;
///
/// # unsafe extern "C" fn initialize_buffer(buf: *mut [u8; 1024]) { *buf = [0; 1024] }

View file

@ -158,6 +158,7 @@ pub trait OpenOptionsExt {
/// # Examples
///
/// ```no_run
/// # #![allow(unexpected_cfgs)]
/// # #[cfg(for_demonstration_only)]
/// extern crate winapi;
/// # mod winapi { pub const FILE_FLAG_DELETE_ON_CLOSE: u32 = 0x04000000; }
@ -195,6 +196,7 @@ pub trait OpenOptionsExt {
/// # Examples
///
/// ```no_run
/// # #![allow(unexpected_cfgs)]
/// # #[cfg(for_demonstration_only)]
/// extern crate winapi;
/// # mod winapi { pub const FILE_ATTRIBUTE_HIDDEN: u32 = 2; }
@ -236,6 +238,7 @@ pub trait OpenOptionsExt {
/// # Examples
///
/// ```no_run
/// # #![allow(unexpected_cfgs)]
/// # #[cfg(for_demonstration_only)]
/// extern crate winapi;
/// # mod winapi { pub const SECURITY_IDENTIFICATION: u32 = 0; }