diff options
| author | Tim Chevalier <chevalier@alum.wellesley.edu> | 2012-11-24 12:49:31 -0800 |
|---|---|---|
| committer | Tim Chevalier <chevalier@alum.wellesley.edu> | 2012-11-24 12:52:27 -0800 |
| commit | f74fe894fc54ebfeaec03f4df6766489c65fa8c5 (patch) | |
| tree | 7c3a6d8ba5bdf917742d6c415e8f5dc5b67c8fa6 /src/libstd/test.rs | |
| parent | e454a47bf2272abfad9987a7be876f0563391e3d (diff) | |
| download | rust-f74fe894fc54ebfeaec03f4df6766489c65fa8c5.tar.gz rust-f74fe894fc54ebfeaec03f4df6766489c65fa8c5.zip | |
[libstd] getopts, now with fewer copies
Change the opt_ functions in getopts to take a reference to a Matches, instead of taking a Matches by-value, as suggested in
Diffstat (limited to 'src/libstd/test.rs')
| -rw-r--r-- | src/libstd/test.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libstd/test.rs b/src/libstd/test.rs index 54f011d246c..fb3e057392d 100644 --- a/src/libstd/test.rs +++ b/src/libstd/test.rs @@ -73,8 +73,8 @@ fn parse_opts(args: &[~str]) -> OptRes { option::Some(matches.free[0]) } else { option::None }; - let run_ignored = getopts::opt_present(matches, ~"ignored"); - let logfile = getopts::opt_maybe_str(matches, ~"logfile"); + let run_ignored = getopts::opt_present(&matches, ~"ignored"); + let logfile = getopts::opt_maybe_str(&matches, ~"logfile"); let test_opts = {filter: filter, run_ignored: run_ignored, logfile: logfile}; |
