Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use wasi crate for Core API #63676

Merged
merged 23 commits into from
Sep 6, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix
  • Loading branch information
newpavlov committed Aug 19, 2019
commit c05237686f994144f2f0bae68dc5b337b06e9a97
2 changes: 1 addition & 1 deletion src/libstd/sys/wasi/args.rs
Original file line number Diff line number Diff line change
@@ -19,7 +19,7 @@ pub struct Args {
/// Returns the command line arguments
pub fn args() -> Args {
Args {
iter: wasi::get_args().unwrap_or(Vec::new()),
iter: wasi::get_args().unwrap_or(Vec::new()).into_iter(),
_dont_send_or_sync_me: PhantomData
}
}
4 changes: 2 additions & 2 deletions src/libstd/sys/wasi/os.rs
Original file line number Diff line number Diff line change
@@ -75,7 +75,7 @@ pub fn current_exe() -> io::Result<PathBuf> {
}

pub struct Env {
iter: Vec<Vec<u8>>,
iter: vec::IntoIter<Vec<u8>>,
_dont_send_or_sync_me: PhantomData<*mut ()>,
}

@@ -100,7 +100,7 @@ impl Iterator for Env {

pub fn env() -> Env {
Env {
iter: wasi::get_environ().unwrap_or(Vec::new()),
iter: wasi::get_environ().unwrap_or(Vec::new()).into_iter(),
newpavlov marked this conversation as resolved.
Show resolved Hide resolved
_dont_send_or_sync_me: PhantomData,
}
}