mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-04 01:42:54 +03:00
Rollup merge of #141834 - Timmmm:user/timh/wasi, r=Noratrieb
Add unimplemented `current_dll_path()` for WASI This is the only change needed to Rust to allow compiling rustfmt for WASI (rustfmt uses some internal rustc crates).
This commit is contained in:
@@ -172,6 +172,11 @@ fn current_dll_path() -> Result<PathBuf, String> {
|
||||
Ok(OsString::from_wide(&filename).into())
|
||||
}
|
||||
|
||||
#[cfg(target_os = "wasi")]
|
||||
fn current_dll_path() -> Result<PathBuf, String> {
|
||||
Err("current_dll_path is not supported on WASI".to_string())
|
||||
}
|
||||
|
||||
pub fn sysroot_candidates() -> SmallVec<[PathBuf; 2]> {
|
||||
let target = crate::config::host_tuple();
|
||||
let mut sysroot_candidates: SmallVec<[PathBuf; 2]> = smallvec![get_or_default_sysroot()];
|
||||
|
||||
Reference in New Issue
Block a user