-
Notifications
You must be signed in to change notification settings - Fork 392
Closed
Labels
A-shimsArea: This affects the external function shimsArea: This affects the external function shimsC-enhancementCategory: a PR with an enhancement or an issue tracking an accepted enhancementCategory: a PR with an enhancement or an issue tracking an accepted enhancement
Description
Cargo.toml
[package]
name = "repro"
version = "0.1.0"
authors = ["An Devloper <[email protected]>"]
edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
src/main.rs
fn main() {
std::env::vars_os();
}
Execution
$ cargo +nightly-2019-05-27 run
Compiling repro v0.1.0 (/private/tmp/repro)
Finished dev [unoptimized + debuginfo] target(s) in 0.25s
Running `target/debug/repro`
$ cargo +nightly-2019-05-27 miri
Compiling repro v0.1.0 (/private/tmp/repro)
error[E0080]: Miri evaluation error: can't call foreign function: _NSGetEnviron
--> /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/sys/unix/os.rs:405:5
|
405 | _NSGetEnviron()
| ^^^^^^^^^^^^^^^ Miri evaluation error: can't call foreign function: _NSGetEnviron
|
= note: inside call to `std::sys::unix::os::environ` at /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/sys/unix/os.rs:426:28
= note: inside call to `std::sys::unix::os::env` at /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/env.rs:143:21
note: inside call to `std::env::vars_os` at src/main.rs:2:5
--> src/main.rs:2:5
|
2 | std::env::vars_os();
| ^^^^^^^^^^^^^^^^^^^
= note: inside call to `main` at /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/rt.rs:64:34
= note: inside call to closure at /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/rt.rs:52:53
= note: inside call to closure at /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/panicking.rs:293:40
= note: inside call to `std::panicking::try::do_call::<[closure@DefId(1:5938 ~ std[29d7]::rt[0]::lang_start_internal[0]::{{closure}}[0]) 0:&dyn std::ops::Fn() -> i32 + std::marker::Sync + std::panic::RefUnwindSafe], i32>` at /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/panicking.rs:289:5
= note: inside call to `std::panicking::try::<i32, [closure@DefId(1:5938 ~ std[29d7]::rt[0]::lang_start_internal[0]::{{closure}}[0]) 0:&dyn std::ops::Fn() -> i32 + std::marker::Sync + std::panic::RefUnwindSafe]>` at /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/panic.rs:388:9
= note: inside call to `std::panic::catch_unwind::<[closure@DefId(1:5938 ~ std[29d7]::rt[0]::lang_start_internal[0]::{{closure}}[0]) 0:&dyn std::ops::Fn() -> i32 + std::marker::Sync + std::panic::RefUnwindSafe], i32>` at /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/rt.rs:52:25
= note: inside call to `std::rt::lang_start_internal` at /Users/shep/.rustup/toolchains/nightly-2019-05-27-x86_64-apple-darwin/lib/rustlib/src/rust/src/libstd/rt.rs:64:5
= note: inside call to `std::rt::lang_start::<()>`
Metadata
Metadata
Assignees
Labels
A-shimsArea: This affects the external function shimsArea: This affects the external function shimsC-enhancementCategory: a PR with an enhancement or an issue tracking an accepted enhancementCategory: a PR with an enhancement or an issue tracking an accepted enhancement