diff options
| author | Graydon Hoare <graydon@mozilla.com> | 2012-06-21 16:44:10 -0700 |
|---|---|---|
| committer | Graydon Hoare <graydon@mozilla.com> | 2012-06-21 16:44:10 -0700 |
| commit | 312faf31dfcce7a2d15495c5042d80a3e3b476c9 (patch) | |
| tree | 4ad8383191907b5cb148291a2d1dbc078f590eb6 /src/rustc | |
| parent | 57101780811490fa759ed1dca310c405d28c0a72 (diff) | |
Tag all remaining FIXMEs with bugs. Install rule in tidy script to enforce this.
Diffstat (limited to 'src/rustc')
27 files changed, 105 insertions, 114 deletions
diff --git a/src/rustc/back/link.rs b/src/rustc/back/link.rs index facb0bcda31..4875fbd69ca 100644 --- a/src/rustc/back/link.rs +++ b/src/rustc/back/link.rs @@ -85,13 +85,12 @@ mod write { } } if !sess.no_verify() { llvm::LLVMAddVerifierPass(pm.llpm); } - // FIXME: This is mostly a copy of the bits of opt's -O2 that are - // available in the C api. - // FIXME2: We might want to add optimization levels like -O1, -O2, + // FIXME (#2396): This is mostly a copy of the bits of opt's -O2 that + // are available in the C api. + // Also: We might want to add optimization levels like -O1, -O2, // -Os, etc - // FIXME3: Should we expose and use the pass lists used by the opt + // Also: Should we expose and use the pass lists used by the opt // tool? - // See #2396 if opts.optimize != 0u { let fpm = mk_pass_manager(); @@ -668,9 +667,8 @@ fn link_binary(sess: session, // Stack growth requires statically linking a __morestack function cc_args += ["-lmorestack"]; - // FIXME: At some point we want to rpath our guesses as to where + // FIXME (#2397): At some point we want to rpath our guesses as to where // native libraries might live, based on the addl_lib_search_paths - // #2397 cc_args += rpath::get_rpath_flags(sess, output); #debug("%s link args: %s", cc_prog, str::connect(cc_args, " ")); diff --git a/src/rustc/driver/driver.rs b/src/rustc/driver/driver.rs index 2cd9c392ef4..553db7695a8 100644 --- a/src/rustc/driver/driver.rs +++ b/src/rustc/driver/driver.rs @@ -78,9 +78,9 @@ fn build_configuration(sess: session, argv0: str, input: input) -> // Convert strings provided as --cfg [cfgspec] into a crate_cfg fn parse_cfgspecs(cfgspecs: [str]) -> ast::crate_cfg { - // FIXME: It would be nice to use the parser to parse all varieties of - // meta_item here. At the moment we just support the meta_word variant. - // #2399 + // FIXME (#2399): It would be nice to use the parser to parse all + // varieties of meta_item here. At the moment we just support the + // meta_word variant. let mut words = []; for cfgspecs.each {|s| words += [attr::mk_word_item(@s)]; } ret words; @@ -100,8 +100,7 @@ fn parse_input(sess: session, cfg: ast::crate_cfg, input: input) parse::parse_crate_from_file(file, cfg, sess.parse_sess) } str_input(src) { - // FIXME: Don't really want to box the source string - // #2319 + // FIXME (#2319): Don't really want to box the source string parse::parse_crate_from_source_str( anon_src(), @src, cfg, sess.parse_sess) } @@ -389,9 +388,10 @@ fn host_triple() -> str { // idea of the host triple is the same as for the set of libraries we've // actually built. We can't just take LLVM's host triple because they // normalize all ix86 architectures to i386. - // FIXME: Instead of grabbing the host triple we really should be - // grabbing (at compile time) the target triple that this rustc is - // built with and calling that (at runtime) the host triple. (#2400) + + // FIXME (#2400): Instead of grabbing the host triple we really should + // be grabbing (at compile time) the target triple that this rustc is + // built with and calling that (at runtime) the host triple. let ht = #env("CFG_HOST_TRIPLE"); ret if ht != "" { ht @@ -660,10 +660,10 @@ fn build_output_filenames(input: input, }; if sess.building_library { - // FIXME: We might want to warn here; we're actually not going to - // respect the user's choice of library name when it comes time to - // link, we'll be linking to lib<basename>-<hash>-<version>.so no - // matter what. (#2401) + // FIXME (#2401): We might want to warn here; we're actually not + // going to respect the user's choice of library name when it + // comes time to link, we'll be linking to + // lib<basename>-<hash>-<version>.so no matter what. } if odir != none { diff --git a/src/rustc/driver/session.rs b/src/rustc/driver/session.rs index def4c7d9a83..9645d919b04 100644 --- a/src/rustc/driver/session.rs +++ b/src/rustc/driver/session.rs @@ -32,7 +32,7 @@ const stats: uint = 16u; const no_asm_comments: uint = 32u; const no_verify: uint = 64u; const trace: uint = 128u; -// FIXME: This exists to transition to a Rust crate runtime +// FIXME (#2377): This exists to transition to a Rust crate runtime // It should be removed const no_rt: uint = 256u; diff --git a/src/rustc/front/test.rs b/src/rustc/front/test.rs index 473d25841b8..2c40db16a45 100644 --- a/src/rustc/front/test.rs +++ b/src/rustc/front/test.rs @@ -64,9 +64,10 @@ fn strip_test_functions(crate: @ast::crate) -> @ast::crate { fn fold_mod(_cx: test_ctxt, m: ast::_mod, fld: fold::ast_fold) -> ast::_mod { // Remove any defined main function from the AST so it doesn't clash with - // the one we're going to add. FIXME: This is sloppy. Instead we should - // have some mechanism to indicate to the translation pass which function - // we want to be main. (#2403) + // the one we're going to add. + + // FIXME (#2403): This is sloppy. Instead we should have some mechanism to + // indicate to the translation pass which function we want to be main. fn nomain(&&item: @ast::item) -> option<@ast::item> { alt item.node { ast::item_fn(_, _, _) { @@ -338,8 +339,8 @@ fn mk_test_desc_rec(cx: test_ctxt, test: test) -> @ast::expr { } // Produces a bare function that wraps the test function -// FIXME: This can go away once fn is the type of bare function -// (See #1281) + +// FIXME (#1281): This can go away once fn is the type of bare function. fn mk_test_wrapper(cx: test_ctxt, fn_path_expr: ast::expr, span: span) -> @ast::expr { diff --git a/src/rustc/metadata/creader.rs b/src/rustc/metadata/creader.rs index 97ccb1d3f24..c63d03ce239 100644 --- a/src/rustc/metadata/creader.rs +++ b/src/rustc/metadata/creader.rs @@ -261,8 +261,8 @@ fn resolve_crate_deps(e: env, cdata: @[u8]) -> cstore::cnum_map { none { #debug("need to load it"); // This is a new one so we've got to load it - // FIXME: Need better error reporting than just a bogus span - // #2404 + // FIXME (#2404): Need better error reporting than just a bogus + // span. let fake_span = ast_util::dummy_sp(); let local_cnum = resolve_crate(e, cname, cmetas, *dep.hash, fake_span); diff --git a/src/rustc/metadata/decoder.rs b/src/rustc/metadata/decoder.rs index e8e367656c1..7209d4e6731 100644 --- a/src/rustc/metadata/decoder.rs +++ b/src/rustc/metadata/decoder.rs @@ -433,8 +433,7 @@ fn item_impl_methods(cdata: cmd, item: ebml::doc, base_tps: uint) let m_did = parse_def_id(ebml::doc_data(doc)); let mth_item = lookup_item(m_did.node, cdata.data); rslt += [@{did: translate_def_id(cdata, m_did), - /* FIXME tjc: take a look at this, it may relate - to #2323 */ + /* FIXME (maybe #2323) tjc: take a look at this. */ n_tps: item_ty_param_count(mth_item) - base_tps, ident: item_name(mth_item)}]; } diff --git a/src/rustc/metadata/encoder.rs b/src/rustc/metadata/encoder.rs index e8fb1a3596e..62c4a078952 100644 --- a/src/rustc/metadata/encoder.rs +++ b/src/rustc/metadata/encoder.rs @@ -1028,9 +1028,8 @@ fn encode_crate_deps(ebml_w: ebml::writer, cstore: cstore::cstore) { // We're just going to write a list of crate 'name-hash-version's, with // the assumption that they are numbered 1 to n. - // FIXME: This is not nearly enough to support correct versioning + // FIXME (#2166): This is not nearly enough to support correct versioning // but is enough to get transitive crate dependencies working. - // See #2166 ebml_w.start_tag(tag_crate_deps); for get_ordered_deps(cstore).each {|dep| encode_crate_dep(ebml_w, dep); diff --git a/src/rustc/metadata/filesearch.rs b/src/rustc/metadata/filesearch.rs index a5cc6c28d53..eeb44f80fd7 100644 --- a/src/rustc/metadata/filesearch.rs +++ b/src/rustc/metadata/filesearch.rs @@ -1,6 +1,6 @@ // A module for searching for libraries -// FIXME: I'm not happy how this module turned out. Should probably -// just be folded into cstore. +// FIXME (#2658): I'm not happy how this module turned out. Should +// probably just be folded into cstore. import result::result; export filesearch; diff --git a/src/rustc/metadata/loader.rs b/src/rustc/metadata/loader.rs index 2cbf529ecf0..a5874aa29fa 100644 --- a/src/rustc/metadata/loader.rs +++ b/src/rustc/metadata/loader.rs @@ -125,8 +125,8 @@ fn crate_name_from_metas(metas: [@ast::meta_item]) -> @str { some(i) { alt attr::get_meta_item_value_str(i) { some(n) { n } - // FIXME: Probably want a warning here since the user - // is using the wrong type of meta item (#2406) + // FIXME (#2406): Probably want a warning here since the user + // is using the wrong type of meta item. _ { fail } } } diff --git a/src/rustc/middle/borrowck/gather_loans.rs b/src/rustc/middle/borrowck/gather_loans.rs index 1745757151c..df46a4cef8f 100644 --- a/src/rustc/middle/borrowck/gather_loans.rs +++ b/src/rustc/middle/borrowck/gather_loans.rs @@ -85,12 +85,12 @@ fn req_loans_in_expr(ex: @ast::expr, // is mutable in the caller's frame, thus effectively // passing the buck onto us to enforce this) // - // FIXME---this handling is not really adequate. For - // example, if there is a type like, {f: [int]}, we - // will ignore it, but we ought to be requiring it to - // be immutable (whereas something like {f:int} would - // be fine). - // (See #2493) + // FIXME (#2493): this handling is not really adequate. + // For example, if there is a type like, {f: [int]}, we + // will ignore it, but we ought to be requiring it to be + // immutable (whereas something like {f:int} would be + // fine). + // alt opt_deref_kind(arg_ty.ty) { some(deref_ptr(region_ptr)) | @@ -130,7 +130,7 @@ fn req_loans_in_expr(ex: @ast::expr, // Here, in an overloaded operator, the call is this expression, // and hence the scope of the borrow is this call. // - // FIXME/NOT REALLY---technically we should check the other + // FIX? / NOT REALLY---technically we should check the other // argument and consider the argument mode. But how annoying. // And this problem when goes away when argument modes are // phased out. So I elect to leave this undone. diff --git a/src/rustc/middle/const_eval.rs b/src/rustc/middle/const_eval.rs index 661ad87dfa8..26ffbdc0273 100644 --- a/src/rustc/middle/const_eval.rs +++ b/src/rustc/middle/const_eval.rs @@ -1,7 +1,7 @@ import syntax::ast::*; -// FIXME this doesn't handle big integer/float literals correctly (nor does -// the rest of our literal handling - issue #33) +// FIXME (#33): this doesn't handle big integer/float literals correctly +// (nor does the rest of our literal handling). enum const_val { const_float(f64), const_int(i64), diff --git a/src/rustc/middle/resolve.rs b/src/rustc/middle/resolve.rs index 78a0f1bfef7..0ae04c25ccd 100644 --- a/src/rustc/middle/resolve.rs +++ b/src/rustc/middle/resolve.rs @@ -215,9 +215,9 @@ fn iter_effective_import_paths(vi: ast::view_item, iter_export_paths(vi) {|vp| alt vp.node { ast::view_path_simple(_, _, _) { } - // FIXME: support uniform ident-list exports eventually; - // at the moment they have half a meaning as reaching into - // tags. (but also see #1893) + // FIXME (but also see #1893): support uniform ident-list exports + // eventually; at the moment they have half a meaning as reaching + // into tags. ast::view_path_list(_, _, _) {} ast::view_path_glob(_,_) { f(vp); diff --git a/src/rustc/middle/trans/base.rs b/src/rustc/middle/trans/base.rs index d308181d8c7..d202ba7a123 100644 --- a/src/rustc/middle/trans/base.rs +++ b/src/rustc/middle/trans/base.rs @@ -1354,10 +1354,10 @@ fn free_ty(cx: block, v: ValueRef, t: ty::t) -> block { fn call_memmove(cx: block, dst: ValueRef, src: ValueRef, n_bytes: ValueRef) { - // FIXME: Provide LLVM with better alignment information when the - // alignment is statically known (it must be nothing more than a constant - // int, or LLVM complains -- not even a constant element of a tydesc - // works). (Related to #1645, I think?) + // FIXME (Related to #1645, I think?): Provide LLVM with better + // alignment information when the alignment is statically known (it must + // be nothing more than a constant int, or LLVM complains -- not even a + // constant element of a tydesc works). let _icx = cx.insn_ctxt("call_memmove"); let ccx = cx.ccx(); let key = alt ccx.sess.targ_cfg.arch { @@ -1439,9 +1439,9 @@ fn copy_val_no_check(bcx: block, action: copy_action, dst: ValueRef, // This works like copy_val, except that it deinitializes the source. // Since it needs to zero out the source, src also needs to be an lval. -// FIXME: We always zero out the source. Ideally we would detect the +// FIXME (#839): We always zero out the source. Ideally we would detect the // case where a variable is always deinitialized by block exit and thus -// doesn't need to be dropped. (Issue #839) +// doesn't need to be dropped. fn move_val(cx: block, action: copy_action, dst: ValueRef, src: lval_result, t: ty::t) -> block { @@ -1652,8 +1652,8 @@ fn cast_shift_rhs(op: ast::binop, if lhs_sz < rhs_sz { trunc(rhs, lhs_llty) } else if lhs_sz > rhs_sz { - // FIXME: If shifting by negative values becomes not undefined - // then this is wrong. (See discussion at #1570) + // FIXME (See discussion at #1570): If shifting by negative + // values becomes not undefined then this is wrong. zext(rhs, lhs_llty) } else { rhs @@ -1790,14 +1790,14 @@ fn trans_assign_op(bcx: block, ex: @ast::expr, op: ast::binop, bcx, ex.info(), fty, expr_ty(bcx, ex), {|bcx| - // FIXME provide the already-computed address, not the expr - // #2528 + // FIXME (#2528): provide the already-computed address, not + // the expr. impl::trans_method_callee(bcx, callee_id, dst, origin) }, arg_exprs([src]), save_in(target)); ret move_val(bcx, DROP_EXISTING, lhs_res.val, - // FIXME: should kind be owned? + // FIXME (#2704): should kind be owned? {bcx: bcx, val: target, kind: owned}, dty); } @@ -4759,9 +4759,9 @@ fn trans_enum_variant(ccx: @crate_ctxt, enum_id: ast::node_id, } -// FIXME: this should do some structural hash-consing to avoid -// duplicate constants. I think. Maybe LLVM has a magical mode -// that does so later on? (#2530) +// FIXME (#2530): this should do some structural hash-consing to avoid +// duplicate constants. I think. Maybe LLVM has a magical mode that does so +// later on? fn trans_const_expr(cx: @crate_ctxt, e: @ast::expr) -> ValueRef { let _icx = cx.insn_ctxt("trans_const_expr"); alt e.node { @@ -4863,9 +4863,9 @@ fn trans_const_expr(cx: @crate_ctxt, e: @ast::expr) -> ValueRef { ast_map::node_item(@{ node: ast::item_const(_, subexpr), _ }, _) { - // FIXME: Instead of recursing here to regenerate the values - // for other constants, we should just look up the - // already-defined value (#2530) + // FIXME (#2530): Instead of recursing here to regenerate + // the values for other constants, we should just look up + // the already-defined value. trans_const_expr(cx, subexpr) } _ { diff --git a/src/rustc/middle/trans/debuginfo.rs b/src/rustc/middle/trans/debuginfo.rs index f80dd130e0e..e90590f0228 100644 --- a/src/rustc/middle/trans/debuginfo.rs +++ b/src/rustc/middle/trans/debuginfo.rs @@ -522,7 +522,7 @@ fn create_ty(_cx: @crate_ctxt, _t: ty::t, _ty: @ast::ty) option::none {} }*/ - /* FIXME I am disabling this code as part of the patch that moves + /* FIXME (#2012): disabled this code as part of the patch that moves * recognition of named builtin types into resolve. I tried to fix * it, but it seems to already be broken -- it's only called when * --xg is given, and compiling with --xg fails on trivial programs. @@ -531,8 +531,6 @@ fn create_ty(_cx: @crate_ctxt, _t: ty::t, _ty: @ast::ty) * needed. It is only done to track spans, but you will not get the * right spans anyway -- types tend to refer to stuff defined * elsewhere, not be self-contained. - * - * See Issue #2012 */ fail; diff --git a/src/rustc/middle/trans/native.rs b/src/rustc/middle/trans/native.rs index 28536282fad..fcc7f370f74 100644 --- a/src/rustc/middle/trans/native.rs +++ b/src/rustc/middle/trans/native.rs @@ -700,8 +700,8 @@ fn trans_native_mod(ccx: @crate_ctxt, } } - // FIXME this is very shaky and probably gets ABIs wrong all over - // the place (#2535) + // FIXME (#2535): this is very shaky and probably gets ABIs wrong all + // over the place fn build_direct_fn(ccx: @crate_ctxt, decl: ValueRef, item: @ast::native_item, tys: @c_stack_tys, cc: lib::llvm::CallConv) { diff --git a/src/rustc/middle/trans/reflect.rs b/src/rustc/middle/trans/reflect.rs index 9731c34fa82..740d53ed773 100644 --- a/src/rustc/middle/trans/reflect.rs +++ b/src/rustc/middle/trans/reflect.rs @@ -163,8 +163,8 @@ impl methods for reflector { self.visit("leave_tup", extra); } - // FIXME: fetch constants out of intrinsic:: for the numbers. - // (#2594) + // FIXME (#2594): fetch constants out of intrinsic:: for the + // numbers. ty::ty_fn(fty) { let pureval = alt fty.purity { ast::pure_fn { 0u } @@ -226,10 +226,10 @@ impl methods for reflector { self.visit("leave_class", extra); } - // FIXME: visiting all the variants in turn is probably - // not ideal. It'll work but will get costly on big enums. - // Maybe let the visitor tell us if it wants to visit only - // a particular variant? (#2595) + // FIXME (#2595): visiting all the variants in turn is probably + // not ideal. It'll work but will get costly on big enums. Maybe + // let the visitor tell us if it wants to visit only a particular + // variant? ty::ty_enum(did, substs) { let bcx = self.bcx; let tcx = bcx.ccx().tcx; diff --git a/src/rustc/middle/trans/shape.rs b/src/rustc/middle/trans/shape.rs index f0d98da5adb..f28d0b53e53 100644 --- a/src/rustc/middle/trans/shape.rs +++ b/src/rustc/middle/trans/shape.rs @@ -491,7 +491,7 @@ fn gen_enum_shapes(ccx: @crate_ctxt) -> ValueRef { // Compute the minimum and maximum size and alignment for each // variant. // - // FIXME: We could do better here; e.g. we know that any + // NB: We could do better here; e.g. we know that any // variant that contains (T,T) must be as least as large as // any variant that contains just T. let mut ranges = []; @@ -500,7 +500,7 @@ fn gen_enum_shapes(ccx: @crate_ctxt) -> ValueRef { let mut min_size = 0u, min_align = 0u; for vec::each(variant.args) {|elem_t| if ty::type_has_params(elem_t) { - // FIXME: We could do better here; this causes us to + // NB: We could do better here; this causes us to // conservatively assume that (int, T) has minimum size 0, // when in fact it has minimum size sizeof(int). bounded = false; @@ -699,7 +699,7 @@ fn llalign_of(cx: @crate_ctxt, t: TypeRef) -> ValueRef { // Computes the static size of a enum, without using mk_tup(), which is // bad for performance. // -// FIXME: Migrate trans over to use this. +// NB: Migrate trans over to use this. // Computes the size of the data part of an enum. fn static_size_of_enum(cx: @crate_ctxt, t: ty::t) -> uint { diff --git a/src/rustc/middle/trans/tvec.rs b/src/rustc/middle/trans/tvec.rs index 164a089dc88..d05629b990f 100644 --- a/src/rustc/middle/trans/tvec.rs +++ b/src/rustc/middle/trans/tvec.rs @@ -422,8 +422,9 @@ fn iter_vec_raw(bcx: block, data_ptr: ValueRef, vec_ty: ty::t, let unit_ty = ty::sequence_element_type(bcx.tcx(), vec_ty); // Calculate the last pointer address we want to handle. - // FIXME: Optimize this when the size of the unit type is statically - // known to not use pointer casts, which tend to confuse LLVM. (#2536) + // FIXME (#2536): Optimize this when the size of the unit type is + // statically known to not use pointer casts, which tend to confuse + // LLVM. let data_end_ptr = pointer_add(bcx, data_ptr, fill); // Now perform the iteration. diff --git a/src/rustc/middle/trans/type_use.rs b/src/rustc/middle/trans/type_use.rs index 7f87c6f74e2..628d407fead 100644 --- a/src/rustc/middle/trans/type_use.rs +++ b/src/rustc/middle/trans/type_use.rs @@ -183,8 +183,8 @@ fn mark_for_expr(cx: ctx, e: @expr) { node_type_needs(cx, use_repr, val.id); } expr_index(base, _) | expr_field(base, _, _) { - // FIXME could be more careful and not count fields - // after the chosen field (#2537) + // FIXME (#2537): could be more careful and not count fields after + // the chosen field. let base_ty = ty::node_id_to_type(cx.ccx.tcx, base.id); type_needs(cx, use_repr, ty::type_autoderef(cx.ccx.tcx, base_ty)); diff --git a/src/rustc/middle/tstate/ann.rs b/src/rustc/middle/tstate/ann.rs index a6a46d1e222..f20ad0f73dc 100644 --- a/src/rustc/middle/tstate/ann.rs +++ b/src/rustc/middle/tstate/ann.rs @@ -243,8 +243,8 @@ fn trit_str(t: trit) -> str { alt t { dont_care { "?" } ttrue { "1" } tfalse { "0" } } } -// FIXME: Would be nice to have unit tests for some of these operations, as -// a step towards formalizing them more rigorously. #2538 +// FIXME (#2538): Would be nice to have unit tests for some of these +// operations, as a step towards formalizing them more rigorously. // // Local Variables: diff --git a/src/rustc/middle/tstate/auxiliary.rs b/src/rustc/middle/tstate/auxiliary.rs index 1ccb19cd53f..5fb79dc1318 100644 --- a/src/rustc/middle/tstate/auxiliary.rs +++ b/src/rustc/middle/tstate/auxiliary.rs @@ -195,8 +195,8 @@ may be the operator in a "check" expression in the source. */ type constraint = { path: @path, - // FIXME: really only want it to be mut during collect_locals. - // freeze it after that. (#2539) + // FIXME (#2539): really only want it to be mut during + // collect_locals. freeze it after that. descs: @dvec<pred_args> }; @@ -494,9 +494,8 @@ fn constraints(fcx: fn_ctxt) -> [norm_constraint] { ret rslt; } -// FIXME -// Would rather take an immutable vec as an argument, -// should freeze it at some earlier point. (#2539) +// FIXME (#2539): Would rather take an immutable vec as an argument, +// should freeze it at some earlier point. fn match_args(fcx: fn_ctxt, occs: @dvec<pred_args>, occ: [@constr_arg_use]) -> uint { #debug("match_args: looking at %s", diff --git a/src/rustc/middle/tstate/states.rs b/src/rustc/middle/tstate/states.rs index 2948d097ab6..4883422a908 100644 --- a/src/rustc/middle/tstate/states.rs +++ b/src/rustc/middle/tstate/states.rs @@ -169,9 +169,9 @@ fn find_pre_post_state_call(fcx: fn_ctxt, pres: prestate, a: @expr, id: node_id, ops: [init_op], bs: [@expr], cf: ret_style) -> bool { let mut changed = find_pre_post_state_expr(fcx, pres, a); - // FIXME: This could be a typestate constraint (except we're - // not using them inside the compiler, I guess... see - // discussion at #2178) + // FIXME (#2178): This could be a typestate constraint (except we're + // not using them inside the compiler, I guess... see discussion in + // bug) if vec::len(bs) != vec::len(ops) { fcx.ccx.tcx.sess.span_bug(a.span, #fmt["mismatched arg lengths: \ diff --git a/src/rustc/middle/tstate/tritv.rs b/src/rustc/middle/tstate/tritv.rs index 546a8ae7deb..7bcc4840d25 100644 --- a/src/rustc/middle/tstate/tritv.rs +++ b/src/rustc/middle/tstate/tritv.rs @@ -25,10 +25,10 @@ export to_str; 01 = "this constraint is definitely true" 00 = "this constraint is definitely false" 11 should never appear - FIXME: typestate precondition (uncertain and val must + FIXME (#2178): typestate precondition (uncertain and val must have the same length; 11 should never appear in a given position) (except we're not putting typestate constraints in the compiler, as - per discussion at #2178). + per discussion at). */ type t = {uncertain: bitv::bitv, val: bitv::bitv, nbits: uint}; @@ -90,8 +90,8 @@ fn trit_or(a: trit, b: trit) -> trit { tfalse { alt b { ttrue { dont_care } - /* FIXME: ?????? - Again, unit tests would help here -- #2538 + /* FIXME (#2538): ?????? + Again, unit tests would help here */ _ { tfalse @@ -101,12 +101,11 @@ fn trit_or(a: trit, b: trit) -> trit { } } -// FIXME: This still seems kind of dodgy to me (that is, +// FIXME (#2538): This still seems kind of dodgy to me (that is, // that 1 + ? = 1. But it might work out given that // all variables start out in a 0 state. Probably I need // to make it so that all constraints start out in a 0 state // (we consider a constraint false until proven true), too. -// #2538 would help. fn trit_and(a: trit, b: trit) -> trit { alt a { dont_care { b } diff --git a/src/rustc/middle/ty.rs b/src/rustc/middle/ty.rs index 92ed7da8ace..3083563d220 100644 --- a/src/rustc/middle/ty.rs +++ b/src/rustc/middle/ty.rs @@ -1209,7 +1209,6 @@ pure fn type_is_scalar(ty: t) -> bool { } } -// FIXME maybe inline this for speed? fn type_is_immediate(ty: t) -> bool { ret type_is_scalar(ty) || type_is_boxed(ty) || type_is_unique(ty) || type_is_region_ptr(ty); @@ -1614,7 +1613,7 @@ fn type_kind(cx: ctxt, ty: t) -> kind { param_bounds_to_kind(cx.ty_param_bounds.get(did.node)) } ty_constr(t, _) { type_kind(cx, t) } - // FIXME: is self ever const? + // FIXME (#2663): is self ever const? ty_self { kind_noncopyable() } ty_var(_) | ty_var_integral(_) { cx.sess.bug("Asked to compute kind of a type variable"); @@ -2038,7 +2037,6 @@ fn hash_type_structure(st: sty) -> uint { fn hash_type_constr(id: uint, c: @type_constr) -> uint { let mut h = id; h = (h << 2u) + hash_def(h, c.node.id); - // FIXME this makes little sense for c.node.args.each {|a| alt a.node { carg_base { h += h << 2u; } @@ -2169,7 +2167,6 @@ fn args_eq<T>(eq: fn(T, T) -> bool, fn constr_eq(c: @constr, d: @constr) -> bool { fn eq_int(&&x: uint, &&y: uint) -> bool { ret x == y; } ret path_to_str(c.node.path) == path_to_str(d.node.path) && - // FIXME: hack args_eq(eq_int, c.node.args, d.node.args); } diff --git a/src/rustc/middle/typeck/collect.rs b/src/rustc/middle/typeck/collect.rs index 249c0105bea..b693ddb8492 100644 --- a/src/rustc/middle/typeck/collect.rs +++ b/src/rustc/middle/typeck/collect.rs @@ -25,8 +25,8 @@ import rscope::*; fn collect_item_types(ccx: @crate_ctxt, crate: @ast::crate) { - // FIXME: hooking into the "intrinsic" root module is crude. - // there ought to be a better approach. Attributes? (#2592) + // FIXME (#2592): hooking into the "intrinsic" root module is crude. + // There ought to be a better approach. Attributes? for crate.node.module.items.each {|crate_item| if *crate_item.ident == "intrinsic" { diff --git a/src/rustc/middle/typeck/infer.rs b/src/rustc/middle/typeck/infer.rs index d545702048f..e948e999e5c 100644 --- a/src/rustc/middle/typeck/infer.rs +++ b/src/rustc/middle/typeck/infer.rs @@ -387,10 +387,10 @@ fn can_mk_assignty(cx: infer_ctxt, anmnt: assignment, #debug["can_mk_assignty(%? / %s <: %s)", anmnt, a.to_str(cx), b.to_str(cx)]; - // FIXME---this will not unroll any entries we make in the - // borrowings table. But this is OK for the moment because this - // is only used in method lookup, and there must be exactly one - // match or an error is reported. Still, it should be fixed. (#2593) + // FIXME (#2593): this will not unroll any entries we make in the + // borrowings table. But this is OK for the moment because this is only + // used in method lookup, and there must be exactly one match or an + // error is reported. Still, it should be fixed. indent {|| cx.probe {|| cx.assign_tys(anmnt, a, b) @@ -1707,16 +1707,16 @@ fn super_fns<C:combine>( argvecs(self, a_f.inputs, b_f.inputs).chain {|inputs| self.tys(a_f.output, b_f.output).chain {|output| self.purities(a_f.purity, b_f.purity).chain {|purity| - //FIXME self.infcx().constrvecs(a_f.constraints, - //FIXME b_f.constraints).then {|| - // (Fix this if #2588 doesn't get accepted) + // FIXME: uncomment if #2588 doesn't get accepted: + // self.infcx().constrvecs(a_f.constraints, + // b_f.constraints).then {|| ok({purity: purity, proto: p, inputs: inputs, output: output, ret_style: rs, constraints: a_f.constraints}) - //FIXME } + // } } } } diff --git a/src/rustc/util/common.rs b/src/rustc/util/common.rs index e12aa98b67a..6e6c5fa740e 100644 --- a/src/rustc/util/common.rs +++ b/src/rustc/util/common.rs @@ -70,8 +70,8 @@ fn local_rhs_span(l: @ast::local, def: span) -> span { } fn is_main_name(path: syntax::ast_map::path) -> bool { - // FIXME: path should be a constrained type, so we know - // the call to last doesn't fail (#34) + // FIXME (#34): path should be a constrained type, so we know + // the call to last doesn't fail. vec::last(path) == syntax::ast_map::path_name(@"main") } |
