diff options
| author | Tim Chevalier <chevalier@alum.wellesley.edu> | 2013-04-16 17:30:31 -0700 |
|---|---|---|
| committer | Tim Chevalier <chevalier@alum.wellesley.edu> | 2013-04-18 17:40:42 -0700 |
| commit | 3d43af15d8ddb497e5aa76cb1ae0530198c63f96 (patch) | |
| tree | 69ea13b8a3adb5f9869d8ac66cf86319decb3854 /src/librustpkg | |
| parent | 18db9a2954450cdc5ace4c91a147804824aa153b (diff) | |
rustc: Anti-copy police
In this case, some copies are still necessary to convert from a mutable to an immutable @-box. It's still an improvement, I hope.
Diffstat (limited to 'src/librustpkg')
| -rw-r--r-- | src/librustpkg/rustpkg.rc | 4 | ||||
| -rw-r--r-- | src/librustpkg/util.rs | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/librustpkg/rustpkg.rc b/src/librustpkg/rustpkg.rc index f8805142769..c28e790338d 100644 --- a/src/librustpkg/rustpkg.rc +++ b/src/librustpkg/rustpkg.rc @@ -76,13 +76,13 @@ impl PkgScript { // Build the rustc session data structures to pass // to the compiler let options = @session::options { - binary: binary, + binary: @binary, crate_type: session::bin_crate, .. *session::basic_options() }; let input = driver::file_input(script); let sess = driver::build_session(options, diagnostic::emit); - let cfg = driver::build_configuration(sess, binary, input); + let cfg = driver::build_configuration(sess, @binary, input); let (crate, _) = driver::compile_upto(sess, cfg, input, driver::cu_parse, None); let work_dir = dest_dir(id); diff --git a/src/librustpkg/util.rs b/src/librustpkg/util.rs index 19938e8c5f1..c61a0025ff6 100644 --- a/src/librustpkg/util.rs +++ b/src/librustpkg/util.rs @@ -467,7 +467,7 @@ pub fn compile_input(sysroot: Option<Path>, test: test, maybe_sysroot: sysroot, addl_lib_search_paths: ~[copy *out_dir], - .. *driver::build_session_options(binary, &matches, diagnostic::emit) + .. *driver::build_session_options(@binary, &matches, diagnostic::emit) }; let mut crate_cfg = options.cfg; @@ -499,7 +499,7 @@ pub fn compile_crate_from_input(input: driver::input, build_dir_opt: Option<Path debug!("Calling build_output_filenames with %?", build_dir_opt); let outputs = driver::build_output_filenames(input, &build_dir_opt, &None, sess); debug!("Outputs are %? and output type = %?", outputs, sess.opts.output_type); - let cfg = driver::build_configuration(sess, binary, input); + let cfg = driver::build_configuration(sess, @binary, input); match crate_opt { Some(c) => { debug!("Calling compile_rest, outputs = %?", outputs); |
