diff --git a/src/librusti/rusti.rc b/src/librusti/rusti.rc index cd479aadb256..257c651efc6f 100644 --- a/src/librusti/rusti.rc +++ b/src/librusti/rusti.rc @@ -131,7 +131,7 @@ fn record(repl: Repl, blk: @ast::blk, intr: @token::ident_interner) -> Repl { /// Run an input string in a Repl, returning the new Repl. fn run(repl: Repl, input: ~str) -> Repl { - let options: @session::options = @{ + let options = @session::options { crate_type: session::unknown_crate, binary: repl.binary, addl_lib_search_paths: repl.lib_search_paths.map(|p| Path(*p)), @@ -157,7 +157,7 @@ fn run(repl: Repl, input: ~str) -> Repl { let outputs = driver::build_output_filenames(wrapped, &None, &None, sess); debug!("calling compile_upto"); - let {crate: crate, tcx: _} = driver::compile_upto(sess, cfg, wrapped, + let (crate, _) = driver::compile_upto(sess, cfg, wrapped, driver::cu_everything, Some(outputs)); @@ -196,7 +196,7 @@ fn run(repl: Repl, input: ~str) -> Repl { fn compile_crate(src_filename: ~str, binary: ~str) -> Option { match do task::try { let src_path = Path(src_filename); - let options: @session::options = @{ + let options = @session::options { binary: binary, addl_lib_search_paths: ~[os::getcwd()], .. *session::basic_options() diff --git a/src/librustpkg/rustpkg.rc b/src/librustpkg/rustpkg.rc index 98ce4052eeb0..f4393425e18d 100644 --- a/src/librustpkg/rustpkg.rc +++ b/src/librustpkg/rustpkg.rc @@ -64,7 +64,7 @@ impl PackageScript { } let binary = os::args()[0]; - let options: @session::options = @{ + let options = @session::options { binary: binary, crate_type: session::bin_crate, .. *session::basic_options() @@ -72,7 +72,7 @@ impl PackageScript { let input = driver::file_input(script); let sess = driver::build_session(options, diagnostic::emit); let cfg = driver::build_configuration(sess, binary, input); - let {crate, _} = driver::compile_upto(sess, cfg, input, + let (crate, _) = driver::compile_upto(sess, cfg, input, driver::cu_parse, None); let mut id = None; let mut vers = None; diff --git a/src/librustpkg/util.rs b/src/librustpkg/util.rs index 7f7b3e75b6fc..5e549d964908 100644 --- a/src/librustpkg/util.rs +++ b/src/librustpkg/util.rs @@ -599,7 +599,7 @@ pub fn compile_input(sysroot: Option, input: driver::input, dir: &Path, let test_dir = dir.push(~"test"); let binary = os::args()[0]; let matches = getopts(flags, driver::optgroups()).get(); - let options = @{ + let options = @session::options { crate_type: session::unknown_crate, optimize: if opt { session::Aggressive } else { session::No }, test: test, @@ -612,7 +612,7 @@ pub fn compile_input(sysroot: Option, input: driver::input, dir: &Path, crate_cfg.push(attr::mk_word_item(@cfg)); } - let options = @{ + let options = @session::options { cfg: vec::append(options.cfg, crate_cfg), .. *options }; @@ -620,7 +620,7 @@ pub fn compile_input(sysroot: Option, input: driver::input, dir: &Path, let cfg = driver::build_configuration(sess, binary, input); let mut outputs = driver::build_output_filenames(input, &None, &None, sess); - let {crate, _} = driver::compile_upto(sess, cfg, input, driver::cu_parse, + let (crate, _) = driver::compile_upto(sess, cfg, input, driver::cu_parse, Some(outputs)); let mut name = None;