We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
OwnedHandle
repr(transparent)
1 parent a743d1c commit 0cd81fcCopy full SHA for 0cd81fc
src/example_ffi.rs
@@ -21,7 +21,7 @@ use winapi::{
21
um::minwinbase::{LPOVERLAPPED, LPSECURITY_ATTRIBUTES},
22
};
23
24
-/// Declare a few FFI functions ourselves, to show off the FFI ergonomics.
+// Declare a few FFI functions ourselves, to show off the FFI ergonomics.
25
#[cfg(all(rustc_attrs, any(unix, target_os = "wasi")))]
26
extern "C" {
27
pub fn open(pathname: *const c_char, flags: c_int, ...) -> Option<OwnedFd>;
src/types.rs
@@ -206,6 +206,7 @@ impl OwnedFd {
206
///
207
/// [here]: https://devblogs.microsoft.com/oldnewthing/20040302-00/?p=40443
208
#[cfg(windows)]
209
+#[repr(transparent)]
210
pub struct OwnedHandle {
211
handle: RawHandle,
212
}
0 commit comments