core: convert vec::{head,head_opt} to return references

This commit is contained in:
Erick Tryzelaar
2013-03-02 21:49:50 -08:00
parent 431e756fd7
commit 359bb3e10b
6 changed files with 68 additions and 31 deletions

View File

@@ -132,7 +132,7 @@ pub fn parse_config_(
match getopts::getopts(args, opts) {
result::Ok(matches) => {
if matches.free.len() == 1 {
let input_crate = Path(vec::head(matches.free));
let input_crate = Path(copy *matches.free.head());
config_from_opts(&input_crate, &matches, program_output)
} else if matches.free.is_empty() {
result::Err(~"no crates specified")