diff options
| author | Thalia Archibald <thalia@archibald.dev> | 2025-04-21 21:05:04 -0700 |
|---|---|---|
| committer | Thalia Archibald <thalia@archibald.dev> | 2025-04-21 21:05:04 -0700 |
| commit | dfc8f02279ab13c81ab47cb875bc585adc0cdc6f (patch) | |
| tree | 1d3e71618362f2d933593e0e6c9b76372fa1bc9f | |
| parent | d6c1e454aa8af5e7e59fbf5c4e7d3128d2f99582 (diff) | |
| download | rust-dfc8f02279ab13c81ab47cb875bc585adc0cdc6f.tar.gz rust-dfc8f02279ab13c81ab47cb875bc585adc0cdc6f.zip | |
Move zkVM constants into `sys::env_consts`
I missed this in #139868. Its `mod` declaration was removed, but the contents were not moved.
| -rw-r--r-- | library/std/src/sys/env_consts.rs | 11 | ||||
| -rw-r--r-- | library/std/src/sys/pal/zkvm/env.rs | 9 |
2 files changed, 11 insertions, 9 deletions
diff --git a/library/std/src/sys/env_consts.rs b/library/std/src/sys/env_consts.rs index 018d7954db2..9683fd47cf9 100644 --- a/library/std/src/sys/env_consts.rs +++ b/library/std/src/sys/env_consts.rs @@ -389,6 +389,17 @@ pub mod os { pub const EXE_EXTENSION: &str = "exe"; } +#[cfg(target_os = "zkvm")] +pub mod os { + pub const FAMILY: &str = ""; + pub const OS: &str = ""; + pub const DLL_PREFIX: &str = ""; + pub const DLL_SUFFIX: &str = ".elf"; + pub const DLL_EXTENSION: &str = "elf"; + pub const EXE_SUFFIX: &str = ".elf"; + pub const EXE_EXTENSION: &str = "elf"; +} + // The fallback when none of the other gates match. #[else] pub mod os { diff --git a/library/std/src/sys/pal/zkvm/env.rs b/library/std/src/sys/pal/zkvm/env.rs deleted file mode 100644 index b85153642b1..00000000000 --- a/library/std/src/sys/pal/zkvm/env.rs +++ /dev/null @@ -1,9 +0,0 @@ -pub mod os { - pub const FAMILY: &str = ""; - pub const OS: &str = ""; - pub const DLL_PREFIX: &str = ""; - pub const DLL_SUFFIX: &str = ".elf"; - pub const DLL_EXTENSION: &str = "elf"; - pub const EXE_SUFFIX: &str = ".elf"; - pub const EXE_EXTENSION: &str = "elf"; -} |
