Skip to content

Change wasm32-wasip2 to use the stable path to fd #379

@tgross35

Description

@tgross35

Attempting to build without the nightly feature hits an error here:

tempfile/src/file/mod.rs

Lines 10 to 11 in b0e6309

#[cfg(target_os = "wasi")]
use std::os::wasi::io::{AsFd, AsRawFd, BorrowedFd, RawFd};
This can be sidestepped by importing the types via std::os::fd::*;, which is a stable path https://rust.godbolt.org/z/rKrG6fvc5. The above cfg(unix) import can use the same path.

The way os::wasi works seems unusual so I asked about it here #general > std::os::wasi unstable on wasip2.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions