Skip to content

Commit 0e5da37

Browse files
committed
Turn on monomorphization by default
1 parent c67679e commit 0e5da37

File tree

4 files changed

+1
-7
lines changed

4 files changed

+1
-7
lines changed

src/rustc/driver/driver.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,6 @@ fn build_session_options(match: getopts::match,
366366
if opt_present(match, "no-lint-ctypes") {
367367
lint_opts += [(lint::ctypes, false)];
368368
}
369-
let monomorphize = opt_present(match, "monomorphize");
370369

371370
let output_type =
372371
if parse_only || no_trans {
@@ -445,7 +444,6 @@ fn build_session_options(match: getopts::match,
445444
parse_only: parse_only,
446445
no_trans: no_trans,
447446
no_asm_comments: no_asm_comments,
448-
monomorphize: monomorphize,
449447
warn_unused_imports: warn_unused_imports,
450448
enforce_mut_vars: enforce_mut_vars};
451449
ret sopts;
@@ -520,7 +518,6 @@ fn opts() -> [getopts::opt] {
520518
optflag("time-passes"), optflag("time-llvm-passes"),
521519
optflag("no-verify"),
522520
optflag("no-lint-ctypes"),
523-
optflag("monomorphize"),
524521
optmulti("cfg"), optflag("test"),
525522
optflag("lib"), optflag("bin"), optflag("static"), optflag("gc"),
526523
optflag("no-asm-comments"),

src/rustc/driver/session.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ type options =
4545
parse_only: bool,
4646
no_trans: bool,
4747
no_asm_comments: bool,
48-
monomorphize: bool,
4948
warn_unused_imports: bool,
5049
enforce_mut_vars: bool};
5150

src/rustc/middle/trans/base.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2229,8 +2229,7 @@ fn lval_static_fn(bcx: block, fn_id: ast::def_id, id: ast::node_id,
22292229
// The awkwardness below mostly stems from the fact that we're mixing
22302230
// monomorphized and non-monomorphized functions at the moment. If
22312231
// monomorphizing becomes the only approach, this'll be much simpler.
2232-
if ccx.sess.opts.monomorphize &&
2233-
(option::is_some(substs) || tys.len() > 0u) &&
2232+
if (option::is_some(substs) || tys.len() > 0u) &&
22342233
fn_id.crate == ast::local_crate &&
22352234
!vec::any(tys, {|t| ty::type_has_params(t)}) {
22362235
let mono = alt substs {

src/rustdoc/astsrv.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,6 @@ fn build_session() -> (session::session, @mutable bool) {
145145
parse_only: false,
146146
no_trans: false,
147147
no_asm_comments: false,
148-
monomorphize: false,
149148
warn_unused_imports: false,
150149
enforce_mut_vars: false
151150
};

0 commit comments

Comments
 (0)