about summary refs log tree commit diff
path: root/src/libstd/rt/args.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd/rt/args.rs')
-rw-r--r--src/libstd/rt/args.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/libstd/rt/args.rs b/src/libstd/rt/args.rs
index cd950471286..e701cb64fb6 100644
--- a/src/libstd/rt/args.rs
+++ b/src/libstd/rt/args.rs
@@ -53,11 +53,10 @@ pub fn clone() -> Option<~[~str]> {
 #[cfg(target_os = "android")]
 #[cfg(target_os = "freebsd")]
 mod imp {
-
     use libc;
     use option::{Option, Some, None};
+    use iterator::{Iterator, range};
     use str;
-    use uint;
     use unstable::finally::Finally;
     use util;
 
@@ -113,10 +112,10 @@ mod imp {
     // Copied from `os`.
     unsafe fn load_argc_and_argv(argc: int, argv: **u8) -> ~[~str] {
         let mut args = ~[];
-        for uint::range(0, argc as uint) |i| {
+        foreach i in range(0u, argc as uint) {
             args.push(str::raw::from_c_str(*(argv as **libc::c_char).offset(i as int)));
         }
-        return args;
+        args
     }
 
     extern {