about summary refs log tree commit diff
path: root/src/libcore/os.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libcore/os.rs')
-rw-r--r--src/libcore/os.rs14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/libcore/os.rs b/src/libcore/os.rs
index 3fd98e7f298..a834bb84f8d 100644
--- a/src/libcore/os.rs
+++ b/src/libcore/os.rs
@@ -473,7 +473,7 @@ pub fn tmpdir() -> Path {
     #[cfg(unix)]
     #[allow(non_implicitly_copyable_typarams)]
     fn lookup() -> Path {
-        option::get_default(&getenv_nonempty("TMPDIR"),
+        option::get_default(getenv_nonempty("TMPDIR"),
                             Path("/tmp"))
     }
 
@@ -481,7 +481,7 @@ pub fn tmpdir() -> Path {
     #[allow(non_implicitly_copyable_typarams)]
     fn lookup() -> Path {
         option::get_default(
-                    &option::or(getenv_nonempty("TMP"),
+                    option::or(getenv_nonempty("TMP"),
                     option::or(getenv_nonempty("TEMP"),
                     option::or(getenv_nonempty("USERPROFILE"),
                                getenv_nonempty("WINDIR")))),
@@ -739,7 +739,7 @@ unsafe fn load_argc_and_argv(argc: c_int, argv: **c_char) -> ~[~str] {
     for uint::range(0, argc as uint) |i| {
         vec::push(&mut args, str::raw::from_c_str(*argv.offset(i)));
     }
-    return args;
+    move args
 }
 
 /**
@@ -903,7 +903,7 @@ mod tests {
         let rng: rand::Rng = rand::Rng();
         let n = ~"TEST" + rng.gen_str(10u);
         assert getenv(n).is_none();
-        n
+        move n
     }
 
     #[test]
@@ -937,7 +937,7 @@ mod tests {
         let n = make_rand_name();
         setenv(n, s);
         log(debug, s);
-        assert getenv(n) == option::Some(s);
+        assert getenv(n) == option::Some(move s);
     }
 
     #[test]
@@ -963,7 +963,7 @@ mod tests {
             // MingW seems to set some funky environment variables like
             // "=C:=C:\MinGW\msys\1.0\bin" and "!::=::\" that are returned
             // from env() but not visible from getenv().
-            assert v2.is_none() || v2 == option::Some(v);
+            assert v2.is_none() || v2 == option::Some(move v);
         }
     }
 
@@ -976,7 +976,7 @@ mod tests {
         assert !vec::contains(e, &(copy n, ~"VALUE"));
 
         e = env();
-        assert vec::contains(e, &(n, ~"VALUE"));
+        assert vec::contains(e, &(move n, ~"VALUE"));
     }
 
     #[test]