Skip to content

Commit bbfa08d

Browse files
committed
rustc: Stop generating the flag_none #fmt flag. Issue #1993
1 parent a0c6ad0 commit bbfa08d

File tree

2 files changed

+1
-13
lines changed

2 files changed

+1
-13
lines changed

src/libcore/extfmt.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -269,12 +269,7 @@ mod rt {
269269
flag_space_for_sign,
270270
flag_sign_always,
271271
flag_alternate,
272-
273-
274-
// FIXME: This is a hack to avoid creating 0-length vec exprs,
275-
// which have some difficulty typechecking currently. See
276-
// comments in front::extfmt::make_flags
277-
// (once #1993 is addressed, this won't be necessary)
272+
// FIXME(1993): This is no longer needed. Remove after a snapshot
278273
flag_none,
279274
}
280275
enum count { count_is(int), count_implied, }

src/rustc/syntax/ext/fmt.rs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -68,13 +68,6 @@ fn pieces_to_expr(cx: ext_ctxt, sp: span, pieces: [piece], args: [@ast::expr])
6868
}
6969
flagexprs += [make_rt_path_expr(cx, sp, fstr)];
7070
}
71-
// FIXME: 0-length vectors can't have their type inferred
72-
// through the rec that these flags are a member of, so
73-
// this is a hack placeholder flag
74-
75-
if vec::len::<@ast::expr>(flagexprs) == 0u {
76-
flagexprs += [make_rt_path_expr(cx, sp, "flag_none")];
77-
}
7871
ret mk_vec_e(cx, sp, flagexprs);
7972
}
8073
fn make_count(cx: ext_ctxt, sp: span, cnt: count) -> @ast::expr {

0 commit comments

Comments
 (0)