summary refs log tree commit diff
path: root/src/libsyntax
diff options
context:
space:
mode:
authorGraydon Hoare <graydon@mozilla.com>2012-06-21 16:44:10 -0700
committerGraydon Hoare <graydon@mozilla.com>2012-06-21 16:44:10 -0700
commit312faf31dfcce7a2d15495c5042d80a3e3b476c9 (patch)
tree4ad8383191907b5cb148291a2d1dbc078f590eb6 /src/libsyntax
parent57101780811490fa759ed1dca310c405d28c0a72 (diff)
downloadrust-312faf31dfcce7a2d15495c5042d80a3e3b476c9.tar.gz
rust-312faf31dfcce7a2d15495c5042d80a3e3b476c9.zip
Tag all remaining FIXMEs with bugs. Install rule in tidy script to enforce this.
Diffstat (limited to 'src/libsyntax')
-rw-r--r--src/libsyntax/ast.rs16
-rw-r--r--src/libsyntax/ast_map.rs58
-rw-r--r--src/libsyntax/ast_util.rs20
-rw-r--r--src/libsyntax/attr.rs22
-rw-r--r--src/libsyntax/codemap.rs6
-rw-r--r--src/libsyntax/diagnostic.rs2
-rw-r--r--src/libsyntax/ext/env.rs4
-rw-r--r--src/libsyntax/ext/expand.rs8
-rw-r--r--src/libsyntax/ext/fmt.rs7
-rw-r--r--src/libsyntax/ext/qquote.rs4
-rw-r--r--src/libsyntax/ext/simplext.rs7
-rw-r--r--src/libsyntax/fold.rs39
-rw-r--r--src/libsyntax/parse.rs6
-rw-r--r--src/libsyntax/parse/common.rs4
-rw-r--r--src/libsyntax/parse/eval.rs4
-rw-r--r--src/libsyntax/parse/lexer.rs6
-rw-r--r--src/libsyntax/parse/parser.rs20
-rw-r--r--src/libsyntax/print/pprust.rs5
-rw-r--r--src/libsyntax/visit.rs21
19 files changed, 130 insertions, 129 deletions
diff --git a/src/libsyntax/ast.rs b/src/libsyntax/ast.rs
index 98cf35efdc8..9d3dcb0f23e 100644
--- a/src/libsyntax/ast.rs
+++ b/src/libsyntax/ast.rs
@@ -176,9 +176,7 @@ enum proto {
 
 #[auto_serialize]
 enum vstore {
-    /* FIXME: Change uint to @expr (actually only constant exprs,
-       as per #2112)
-     */
+    // FIXME (#2112): Change uint to @expr (actually only constant exprs)
     vstore_fixed(option<uint>),   // [1,2,3,4]/_ or 4
     vstore_uniq,                  // [1,2,3,4]/~
     vstore_box,                   // [1,2,3,4]/@
@@ -256,12 +254,11 @@ enum init_op { init_assign, init_move, }
 #[auto_serialize]
 type initializer = {op: init_op, expr: @expr};
 
+// FIXME (pending discussion of #1697, #2178...): local should really be
+// a refinement on pat.
 #[auto_serialize]
-type local_ =  /* FIXME: should really be a refinement on pat
-                  (pending discussion of #1697, #2178...)
-                */
-    {is_mutbl: bool, ty: @ty, pat: @pat,
-     init: option<initializer>, id: node_id};
+type local_ =  {is_mutbl: bool, ty: @ty, pat: @pat,
+                init: option<initializer>, id: node_id};
 
 #[auto_serialize]
 type local = spanned<local_>;
@@ -322,9 +319,8 @@ enum expr_ {
     expr_block(blk),
 
     /*
-     * FIXME: many of these @exprs should be constrained with
+     * FIXME (#34): many of these @exprs should be constrained with
      * is_lval once we have constrained types working.
-     * (See #34)
      */
     expr_copy(@expr),
     expr_move(@expr, @expr),
diff --git a/src/libsyntax/ast_map.rs b/src/libsyntax/ast_map.rs
index e11e673494c..9355da5779e 100644
--- a/src/libsyntax/ast_map.rs
+++ b/src/libsyntax/ast_map.rs
@@ -13,8 +13,8 @@ type path = [path_elt];
 fn path_to_str_with_sep(p: path, sep: str) -> str {
     let strs = vec::map(p) {|e|
         alt e {
-          path_mod(s) { /* FIXME: bad */ copy *s }
-          path_name(s) { /* FIXME: bad */ copy *s }
+          path_mod(s) { /* FIXME (#2543) */ copy *s }
+          path_name(s) { /* FIXME (#2543) */ copy *s }
         }
     };
     str::connect(strs, sep)
@@ -22,7 +22,7 @@ fn path_to_str_with_sep(p: path, sep: str) -> str {
 
 fn path_ident_to_str(p: path, i: ident) -> str {
     if vec::is_empty(p) {
-        /* FIXME: bad */ copy *i
+        /* FIXME (#2543) */ copy *i
     } else {
         #fmt["%s::%s", path_to_str(p), *i]
     }
@@ -98,7 +98,7 @@ fn map_decoded_item(diag: span_handler,
     // even if we did I think it only needs an ordering between local
     // variables that are simultaneously in scope).
     let cx = {map: map,
-              mut path: /* FIXME: bad */ copy path,
+              mut path: /* FIXME (#2543) */ copy path,
               mut local_id: 0u,
               diag: diag};
     let v = mk_ast_map_visitor();
@@ -124,27 +124,29 @@ fn map_decoded_item(diag: span_handler,
 fn map_fn(fk: visit::fn_kind, decl: fn_decl, body: blk,
           sp: codemap::span, id: node_id, cx: ctx, v: vt) {
     for decl.inputs.each {|a|
-        cx.map.insert(a.id, node_arg(/* FIXME: bad */ copy a, cx.local_id));
+        cx.map.insert(a.id,
+                      node_arg(/* FIXME (#2543) */
+                          copy a, cx.local_id));
         cx.local_id += 1u;
     }
     alt fk {
       visit::fk_ctor(nm, tps, self_id, parent_id) {
           let ct = @{node: {id: id,
                             self_id: self_id,
-                            dec: /* FIXME: bad */ copy decl,
-                            body: /* FIXME: bad */ copy body},
+                            dec: /* FIXME (#2543) */ copy decl,
+                            body: /* FIXME (#2543) */ copy body},
                     span: sp};
-          cx.map.insert(id, node_ctor(/* FIXME: bad */ copy nm,
-                                      /* FIXME: bad */ copy tps,
+          cx.map.insert(id, node_ctor(/* FIXME (#2543) */ copy nm,
+                                      /* FIXME (#2543) */ copy tps,
                                       class_ctor(ct, parent_id),
-                                      @/* FIXME: bad */ copy cx.path));
+                                      @/* FIXME (#2543) */ copy cx.path));
        }
       visit::fk_dtor(tps, self_id, parent_id) {
           let dt = @{node: {id: id, self_id: self_id,
-                     body: /* FIXME: bad */ copy body}, span: sp};
-          cx.map.insert(id, node_dtor(/* FIXME: bad */ copy tps, dt,
+                     body: /* FIXME (#2543) */ copy body}, span: sp};
+          cx.map.insert(id, node_dtor(/* FIXME (#2543) */ copy tps, dt,
                                       parent_id,
-                                      @/* FIXME: bad */ copy cx.path));
+                                      @/* FIXME (#2543) */ copy cx.path));
        }
 
        _ {}
@@ -153,7 +155,7 @@ fn map_fn(fk: visit::fn_kind, decl: fn_decl, body: blk,
 }
 
 fn map_block(b: blk, cx: ctx, v: vt) {
-    cx.map.insert(b.node.id, node_block(/* FIXME: bad */ copy b));
+    cx.map.insert(b.node.id, node_block(/* FIXME (#2543) */ copy b));
     visit::visit_block(b, cx, v);
 }
 
@@ -187,7 +189,7 @@ fn map_method(impl_did: def_id, impl_path: @path,
 }
 
 fn map_item(i: @item, cx: ctx, v: vt) {
-    let item_path = @/* FIXME: bad */ copy cx.path;
+    let item_path = @/* FIXME (#2543) */ copy cx.path;
     cx.map.insert(i.id, node_item(i, item_path));
     alt i.node {
       item_impl(_, _, _, _, ms) {
@@ -198,9 +200,10 @@ fn map_item(i: @item, cx: ctx, v: vt) {
         }
       }
       item_res(decl, tps, _, dtor_id, ctor_id, _) {
-        cx.map.insert(ctor_id, node_ctor(/* FIXME: bad */ copy i.ident,
-                                         /* FIXME: bad */ copy tps,
-                                         res_ctor(/* FIXME: bad */ copy decl,
+        cx.map.insert(ctor_id, node_ctor(/* FIXME (#2543) */ copy i.ident,
+                                         /* FIXME (#2543) */ copy tps,
+                                         res_ctor(/* FIXME (#2543) */
+                                                  copy decl,
                                                   ctor_id, i.span),
                                          item_path));
         cx.map.insert(dtor_id, node_item(i, item_path));
@@ -208,7 +211,7 @@ fn map_item(i: @item, cx: ctx, v: vt) {
       item_enum(vs, _, _) {
         for vs.each {|v|
             cx.map.insert(v.node.id, node_variant(
-                /* FIXME: bad */ copy v, i,
+                /* FIXME (#2543) */ copy v, i,
                 extend(cx, i.ident)));
         }
       }
@@ -220,7 +223,8 @@ fn map_item(i: @item, cx: ctx, v: vt) {
         for nm.items.each {|nitem|
             cx.map.insert(nitem.id,
                           node_native_item(nitem, abi,
-                                           @/* FIXME: bad */ copy cx.path));
+                                           /* FIXME (#2543) */
+                                           @copy cx.path));
         }
       }
       item_class(tps, ifces, items, ctor, dtor, _) {
@@ -251,7 +255,9 @@ fn map_view_item(vi: @view_item, cx: ctx, _v: vt) {
       view_item_export(vps) {
         for vps.each {|vp|
             let (id, name) = alt vp.node {
-              view_path_simple(nm, _, id) { (id, /* FIXME: bad */ copy nm) }
+              view_path_simple(nm, _, id) {
+                (id, /* FIXME (#2543) */ copy nm)
+              }
               view_path_glob(pth, id) | view_path_list(pth, _, id) {
                 (id, path_to_ident(pth))
               }
@@ -294,19 +300,19 @@ fn node_id_to_str(map: map, id: node_id) -> str {
       }
       // FIXMEs are as per #2410
       some(node_export(_, path)) {
-        #fmt["export %s (id=%?)", // FIXME: add more info here
+        #fmt["export %s (id=%?)", // add more info here
              path_to_str(*path), id]
       }
-      some(node_arg(_, _)) { // FIXME: add more info here
+      some(node_arg(_, _)) { // add more info here
         #fmt["arg (id=%?)", id]
       }
-      some(node_local(_)) { // FIXME: add more info here
+      some(node_local(_)) { // add more info here
         #fmt["local (id=%?)", id]
       }
-      some(node_ctor(*)) { // FIXME: add more info here
+      some(node_ctor(*)) { // add more info here
         #fmt["node_ctor (id=%?)", id]
       }
-      some(node_dtor(*)) { // FIXME: add more info here
+      some(node_dtor(*)) { // add more info here
         #fmt["node_dtor (id=%?)", id]
       }
       some(node_block(_)) {
diff --git a/src/libsyntax/ast_util.rs b/src/libsyntax/ast_util.rs
index e56bb25e55d..8ce34a06329 100644
--- a/src/libsyntax/ast_util.rs
+++ b/src/libsyntax/ast_util.rs
@@ -159,7 +159,7 @@ fn is_exported(i: ident, m: _mod) -> bool {
             for variants.each {|v|
                 if v.node.name == i {
                    local = true;
-                   parent_enum = some(/* FIXME: bad */ copy it.ident);
+                   parent_enum = some(/* FIXME (#2543) */ copy it.ident);
                 }
             }
           }
@@ -268,7 +268,7 @@ pure fn is_unguarded(&&a: arm) -> bool {
 }
 
 pure fn unguarded_pat(a: arm) -> option<[@pat]> {
-    if is_unguarded(a) { some(/* FIXME: bad */ copy a.pats) } else { none }
+    if is_unguarded(a) { some(/* FIXME (#2543) */ copy a.pats) } else { none }
 }
 
 // Provides an extra node_id to hang callee information on, in case the
@@ -278,8 +278,8 @@ fn op_expr_callee_id(e: @expr) -> node_id { e.id - 1 }
 
 pure fn class_item_ident(ci: @class_member) -> ident {
     alt ci.node {
-      instance_var(i,_,_,_,_) { /* FIXME: bad */ copy i }
-      class_method(it) { /* FIXME: bad */ copy it.ident }
+      instance_var(i,_,_,_,_) { /* FIXME (#2543) */ copy i }
+      class_method(it) { /* FIXME (#2543) */ copy it.ident }
     }
 }
 
@@ -297,7 +297,7 @@ fn split_class_items(cs: [@class_member]) -> ([ivar], [@method]) {
     for cs.each {|c|
       alt c.node {
         instance_var(i, t, cm, id, vis) {
-          vs += [{ident: /* FIXME: bad */ copy i,
+          vs += [{ident: /* FIXME (#2543) */ copy i,
                   ty: t,
                   cm: cm,
                   id: id,
@@ -319,11 +319,11 @@ pure fn class_member_visibility(ci: @class_member) -> visibility {
 impl inlined_item_methods for inlined_item {
     fn ident() -> ident {
         alt self {
-          ii_item(i) { /* FIXME: bad */ copy i.ident }
-          ii_native(i) { /* FIXME: bad */ copy i.ident }
-          ii_method(_, m) { /* FIXME: bad */ copy m.ident }
-          ii_ctor(_, nm, _, _) { /* FIXME: bad */ copy nm }
-          ii_dtor(_, nm, _, _) { /* FIXME: bad */ copy nm }
+          ii_item(i) { /* FIXME (#2543) */ copy i.ident }
+          ii_native(i) { /* FIXME (#2543) */ copy i.ident }
+          ii_method(_, m) { /* FIXME (#2543) */ copy m.ident }
+          ii_ctor(_, nm, _, _) { /* FIXME (#2543) */ copy nm }
+          ii_dtor(_, nm, _, _) { /* FIXME (#2543) */ copy nm }
         }
     }
 
diff --git a/src/libsyntax/attr.rs b/src/libsyntax/attr.rs
index 5dfe40b7ee0..fb9560065a8 100644
--- a/src/libsyntax/attr.rs
+++ b/src/libsyntax/attr.rs
@@ -91,9 +91,9 @@ fn get_attr_name(attr: ast::attribute) -> ast::ident {
 // All "bad" FIXME copies are as per #2543
 fn get_meta_item_name(meta: @ast::meta_item) -> ast::ident {
     alt meta.node {
-      ast::meta_word(n) { /* FIXME bad */ copy n }
-      ast::meta_name_value(n, _) { /* FIXME bad */ copy n }
-      ast::meta_list(n, _) { /* FIXME bad */ copy n }
+      ast::meta_word(n) { /* FIXME (#2543) */ copy n }
+      ast::meta_name_value(n, _) { /* FIXME (#2543) */ copy n }
+      ast::meta_list(n, _) { /* FIXME (#2543) */ copy n }
     }
 }
 
@@ -120,7 +120,7 @@ fn get_meta_item_value_str(meta: @ast::meta_item) -> option<@str> {
 #[doc = "Gets a list of inner meta items from a list meta_item type"]
 fn get_meta_item_list(meta: @ast::meta_item) -> option<[@ast::meta_item]> {
     alt meta.node {
-      ast::meta_list(_, l) { option::some(/* FIXME bad */ copy l) }
+      ast::meta_list(_, l) { option::some(/* FIXME (#2543) */ copy l) }
       _ { option::none }
     }
 }
@@ -266,15 +266,15 @@ fn last_meta_item_list_by_name(
 
 /* Higher-level applications */
 
-// FIXME: This needs to sort by meta_item variant in addition to the item name
-// (See [Fixme-sorting])
+// FIXME (#607): This needs to sort by meta_item variant in addition to
+// the item name (See [Fixme-sorting])
 fn sort_meta_items(+items: [@ast::meta_item]) -> [@ast::meta_item] {
     fn lteq(&&ma: @ast::meta_item, &&mb: @ast::meta_item) -> bool {
         fn key(m: @ast::meta_item) -> ast::ident {
             alt m.node {
-              ast::meta_word(name) { /* FIXME bad */ copy name }
-              ast::meta_name_value(name, _) { /* FIXME bad */ copy name }
-              ast::meta_list(name, _) { /* FIXME bad */ copy name }
+              ast::meta_word(name) { /* FIXME (#2543) */ copy name }
+              ast::meta_name_value(name, _) { /* FIXME (#2543) */ copy name }
+              ast::meta_list(name, _) { /* FIXME (#2543) */ copy name }
             }
         }
         ret key(ma) <= key(mb);
@@ -292,7 +292,7 @@ fn remove_meta_items_by_name(items: [@ast::meta_item], name: ast::ident) ->
     ret vec::filter_map(items, {
         |item|
         if get_meta_item_name(item) != name {
-            option::some(/* FIXME bad */ copy item)
+            option::some(/* FIXME (#2543) */ copy item)
         } else {
             option::none
         }
@@ -317,7 +317,7 @@ linkage
 fn find_linkage_metas(attrs: [ast::attribute]) -> [@ast::meta_item] {
     find_linkage_attrs(attrs).flat_map {|attr|
         alt check attr.node.value.node {
-          ast::meta_list(_, items) { /* FIXME bad */ copy items }
+          ast::meta_list(_, items) { /* FIXME (#2543) */ copy items }
         }
     }
 }
diff --git a/src/libsyntax/codemap.rs b/src/libsyntax/codemap.rs
index 97911f9d8b8..49560fb5bbd 100644
--- a/src/libsyntax/codemap.rs
+++ b/src/libsyntax/codemap.rs
@@ -123,7 +123,7 @@ fn lookup_char_pos_adj(map: codemap, pos: uint)
     let loc = lookup_char_pos(map, pos);
     alt (loc.file.substr) {
       fss_none {
-        {filename: /* FIXME bad */ copy loc.file.name,
+        {filename: /* FIXME (#2543) */ copy loc.file.name,
          line: loc.line,
          col: loc.col,
          file: some(loc.file)}
@@ -132,7 +132,7 @@ fn lookup_char_pos_adj(map: codemap, pos: uint)
         lookup_char_pos_adj(map, sp.lo + (pos - loc.file.start_pos.ch))
       }
       fss_external(eloc) {
-        {filename: /* FIXME bad */ copy eloc.filename,
+        {filename: /* FIXME (#2543) */ copy eloc.filename,
          line: eloc.line + loc.line - 1u,
          col: if loc.line == 1u {eloc.col + loc.col} else {loc.col},
          file: none}
@@ -178,7 +178,7 @@ type file_lines = {file: filemap, lines: [uint]};
 
 fn span_to_filename(sp: span, cm: codemap::codemap) -> filename {
     let lo = lookup_char_pos(cm, sp.lo);
-    ret /* FIXME bad */ copy lo.file.name;
+    ret /* FIXME (#2543) */ copy lo.file.name;
 }
 
 fn span_to_lines(sp: span, cm: codemap::codemap) -> @file_lines {
diff --git a/src/libsyntax/diagnostic.rs b/src/libsyntax/diagnostic.rs
index b65c6524d12..b8ebb27f51b 100644
--- a/src/libsyntax/diagnostic.rs
+++ b/src/libsyntax/diagnostic.rs
@@ -201,7 +201,7 @@ fn highlight_lines(cm: codemap::codemap, sp: span,
     // arbitrarily only print up to six lines of the error
     let max_lines = 6u;
     let mut elided = false;
-    let mut display_lines = /* FIXME bad */ copy lines.lines;
+    let mut display_lines = /* FIXME (#2543) */ copy lines.lines;
     if vec::len(display_lines) > max_lines {
         display_lines = vec::slice(display_lines, 0u, max_lines);
         elided = true;
diff --git a/src/libsyntax/ext/env.rs b/src/libsyntax/ext/env.rs
index ebb56fa3b58..26a906f8cf0 100644
--- a/src/libsyntax/ext/env.rs
+++ b/src/libsyntax/ext/env.rs
@@ -11,8 +11,8 @@ fn expand_syntax_ext(cx: ext_ctxt, sp: codemap::span, arg: ast::mac_arg,
                      _body: ast::mac_body) -> @ast::expr {
     let args = get_mac_args(cx, sp, arg, 1u, option::some(1u), "env");
 
-    // FIXME: if this was more thorough it would manufacture an
-    // option<str> rather than just an maybe-empty string. (Issue #2248)
+    // FIXME (#2248): if this was more thorough it would manufacture an
+    // option<str> rather than just an maybe-empty string.
 
     let var = expr_to_str(cx, args[0], "#env requires a string");
     alt os::getenv(var) {
diff --git a/src/libsyntax/ext/expand.rs b/src/libsyntax/ext/expand.rs
index ba44404fe24..26313e97494 100644
--- a/src/libsyntax/ext/expand.rs
+++ b/src/libsyntax/ext/expand.rs
@@ -109,10 +109,10 @@ fn new_span(cx: ext_ctxt, sp: span) -> span {
     ret {lo: sp.lo, hi: sp.hi, expn_info: cx.backtrace()};
 }
 
-// FIXME: this is a terrible kludge to inject some macros into the default
-// compilation environment. When the macro-definition system is substantially
-// more mature, these should move from here, into a compiled part of libcore
-// at very least. (Issue #2247)
+// FIXME (#2247): this is a terrible kludge to inject some macros into
+// the default compilation environment. When the macro-definition system
+// is substantially more mature, these should move from here, into a
+// compiled part of libcore at very least.
 
 fn core_macros() -> str {
     ret
diff --git a/src/libsyntax/ext/fmt.rs b/src/libsyntax/ext/fmt.rs
index 5ea8b677675..0cc4ba0a570 100644
--- a/src/libsyntax/ext/fmt.rs
+++ b/src/libsyntax/ext/fmt.rs
@@ -30,11 +30,10 @@ fn expand_syntax_ext(cx: ext_ctxt, sp: span, arg: ast::mac_arg,
     ret pieces_to_expr(cx, sp, pieces, args);
 }
 
-// FIXME: A lot of these functions for producing expressions can probably
-// be factored out in common with other code that builds expressions.
-// FIXME: Cleanup the naming of these functions
+// FIXME (#2249): A lot of these functions for producing expressions can
+// probably be factored out in common with other code that builds
+// expressions.  Also: Cleanup the naming of these functions.
 // NOTE: Moved many of the common ones to build.rs --kevina
-// See Issue #2249
 fn pieces_to_expr(cx: ext_ctxt, sp: span, pieces: [piece], args: [@ast::expr])
    -> @ast::expr {
     fn make_path_vec(_cx: ext_ctxt, ident: ast::ident) -> [ast::ident] {
diff --git a/src/libsyntax/ext/qquote.rs b/src/libsyntax/ext/qquote.rs
index 9830c379ef6..3f3eb001250 100644
--- a/src/libsyntax/ext/qquote.rs
+++ b/src/libsyntax/ext/qquote.rs
@@ -104,8 +104,8 @@ fn gather_anti_quotes<N: qq_helper>(lo: uint, node: N) -> aq_ctxt
               with *default_visitor()};
     let cx = @{lo:lo, gather: dvec()};
     node.visit(cx, mk_vt(v));
-    // FIXME: Maybe this is an overkill (merge_sort), it might be better
-    //   to just keep the gather array in sorted order ... (Issue #2250)
+    // FIXME (#2250): Maybe this is an overkill (merge_sort), it might
+    // be better to just keep the gather array in sorted order.
     cx.gather.swap { |v|
         vec::to_mut(std::sort::merge_sort({|a,b| a.lo < b.lo}, v))
     };
diff --git a/src/libsyntax/ext/simplext.rs b/src/libsyntax/ext/simplext.rs
index bf3014d1621..4dad13dc06a 100644
--- a/src/libsyntax/ext/simplext.rs
+++ b/src/libsyntax/ext/simplext.rs
@@ -466,8 +466,7 @@ fn p_t_s_rec(cx: ext_ctxt, m: matchable, s: selector, b: binders) {
               }
             }
           }
-          /* FIXME: handle embedded types and blocks, at least
-             (Issue #2251) */
+          /* FIXME (#2251): handle embedded types and blocks, at least */
           expr_mac(mac) {
             p_t_s_r_mac(cx, mac, s, b);
           }
@@ -722,8 +721,8 @@ fn add_new_extension(cx: ext_ctxt, sp: span, arg: ast::mac_arg,
                         [@{params: pattern_to_selectors(cx, arg),
                            body: elts[1u]}];
 
-                    // FIXME: check duplicates (or just simplify
-                    // the macro arg situation) (Issue #2251)
+                    // FIXME (#2251): check duplicates (or just simplify
+                    // the macro arg situation)
                   }
                   _ {
                       cx.span_bug(mac.span, "undocumented invariant in \
diff --git a/src/libsyntax/fold.rs b/src/libsyntax/fold.rs
index 0589e48489c..ff296eb5aad 100644
--- a/src/libsyntax/fold.rs
+++ b/src/libsyntax/fold.rs
@@ -88,11 +88,12 @@ fn fold_meta_item_(&&mi: @meta_item, fld: ast_fold) -> @meta_item {
                 meta_word(id) { meta_word(fld.fold_ident(id)) }
                 meta_list(id, mis) {
                   let fold_meta_item = {|x|fold_meta_item_(x, fld)};
-                  meta_list(/* FIXME: bad */ copy id,
+                  meta_list(/* FIXME: (#2543) */ copy id,
                             vec::map(mis, fold_meta_item))
                 }
                 meta_name_value(id, s) {
-                  meta_name_value(fld.fold_ident(id), /* FIXME: bad */ copy s)
+                  meta_name_value(fld.fold_ident(id),
+                                  /* FIXME (#2543) */ copy s)
                 }
               },
           span: fld.new_span(mi.span)};
@@ -123,8 +124,8 @@ fn fold_mac_(m: mac, fld: ast_fold) -> mac {
                mac_embed_type(ty) { mac_embed_type(fld.fold_ty(ty)) }
                mac_embed_block(blk) { mac_embed_block(fld.fold_block(blk)) }
                mac_ellipsis { mac_ellipsis }
-               mac_aq(_,_) { /* FIXME: bad */ copy m.node }
-               mac_var(_) { /* FIXME: bad */ copy m.node }
+               mac_aq(_,_) { /* FIXME (#2543) */ copy m.node }
+               mac_var(_) { /* FIXME (#2543) */ copy m.node }
              },
          span: fld.new_span(m.span)};
 }
@@ -145,7 +146,7 @@ fn fold_ty_param_bound(tpb: ty_param_bound, fld: ast_fold) -> ty_param_bound {
 }
 
 fn fold_ty_param(tp: ty_param, fld: ast_fold) -> ty_param {
-    {ident: /* FIXME: bad */ copy tp.ident,
+    {ident: /* FIXME (#2543) */ copy tp.ident,
      id: fld.new_id(tp.id),
      bounds: @vec::map(*tp.bounds, {|x|fold_ty_param_bound(x, fld)})}
 }
@@ -168,12 +169,12 @@ fn noop_fold_crate_directive(cd: crate_directive_, fld: ast_fold) ->
    crate_directive_ {
     ret alt cd {
           cdir_src_mod(id, attrs) {
-            cdir_src_mod(fld.fold_ident(id), /* FIXME: bad */ copy attrs)
+            cdir_src_mod(fld.fold_ident(id), /* FIXME (#2543) */ copy attrs)
           }
           cdir_dir_mod(id, cds, attrs) {
             cdir_dir_mod(fld.fold_ident(id),
                          vec::map(cds, fld.fold_crate_directive),
-                         /* FIXME: bad */ copy attrs)
+                         /* FIXME (#2543) */ copy attrs)
           }
           cdir_view_item(vi) { cdir_view_item(fld.fold_view_item(vi)) }
           cdir_syntax(_) { copy cd }
@@ -181,7 +182,7 @@ fn noop_fold_crate_directive(cd: crate_directive_, fld: ast_fold) ->
 }
 
 fn noop_fold_view_item(vi: view_item_, _fld: ast_fold) -> view_item_ {
-    ret /* FIXME: bad */ copy vi;
+    ret /* FIXME (#2543) */ copy vi;
 }
 
 
@@ -223,8 +224,8 @@ fn noop_fold_class_item(&&ci: @class_member, fld: ast_fold)
     -> @class_member {
     @{node: alt ci.node {
         instance_var(ident, t, cm, id, p) {
-           instance_var(/* FIXME: bad */ copy ident, fld.fold_ty(t), cm, id,
-                        p)
+           instance_var(/* FIXME (#2543) */ copy ident,
+                        fld.fold_ty(t), cm, id, p)
         }
         class_method(m) { class_method(fld.fold_method(m)) }
       },
@@ -260,7 +261,7 @@ fn noop_fold_item_underscore(i: item_, fld: ast_fold) -> item_ {
                         id: dtor_id with dtor.node}
                     with dtor}};
               item_class(
-                  /* FIXME: bad */ copy typms,
+                  /* FIXME (#2543) */ copy typms,
                   vec::map(ifaces, {|p| fold_iface_ref(p, fld) }),
                   vec::map(items, fld.fold_class_item),
                   {node: {body: ctor_body,
@@ -278,7 +279,7 @@ fn noop_fold_item_underscore(i: item_, fld: ast_fold) -> item_ {
           item_iface(tps, rp, methods) {
             item_iface(fold_ty_params(tps, fld),
                        rp,
-                       /* FIXME: bad */ copy methods)
+                       /* FIXME (#2543) */ copy methods)
           }
           item_res(decl, typms, body, did, cid, rp) {
             item_res(fold_fn_decl(decl, fld),
@@ -297,7 +298,7 @@ fn fold_iface_ref(&&p: @iface_ref, fld: ast_fold) -> @iface_ref {
 
 fn noop_fold_method(&&m: @method, fld: ast_fold) -> @method {
     ret @{ident: fld.fold_ident(m.ident),
-          attrs: /* FIXME: bad */ copy m.attrs,
+          attrs: /* FIXME (#2543) */ copy m.attrs,
           tps: fold_ty_params(m.tps, fld),
           decl: fold_fn_decl(m.decl, fld),
           body: fld.fold_block(m.body),
@@ -344,7 +345,7 @@ fn noop_fold_pat(p: pat_, fld: ast_fold) -> pat_ {
           pat_rec(fields, etc) {
             let mut fs = [];
             for fields.each {|f|
-                fs += [{ident: /* FIXME: bad */ copy f.ident,
+                fs += [{ident: /* FIXME (#2543) */ copy f.ident,
                         pat: fld.fold_pat(f.pat)}];
             }
             pat_rec(fs, etc)
@@ -507,13 +508,13 @@ fn noop_fold_ty(t: ty_, fld: ast_fold) -> ty_ {
 }
 
 fn noop_fold_constr(c: constr_, fld: ast_fold) -> constr_ {
-    {path: fld.fold_path(c.path), args: /* FIXME: bad */ copy c.args,
+    {path: fld.fold_path(c.path), args: /* FIXME (#2543) */ copy c.args,
      id: fld.new_id(c.id)}
 }
 
 fn noop_fold_ty_constr(c: ty_constr_, fld: ast_fold) -> ty_constr_ {
     let rslt: ty_constr_ =
-        {path: fld.fold_path(c.path), args: /* FIXME: bad */ copy c.args,
+        {path: fld.fold_path(c.path), args: /* FIXME (#2543) */ copy c.args,
          id: fld.new_id(c.id)};
     rslt
 }
@@ -542,7 +543,7 @@ fn noop_fold_variant(v: variant_, fld: ast_fold) -> variant_ {
       some(e) {some(fld.fold_expr(e))}
       none {none}
     };
-    ret {name: /* FIXME: bad */ copy v.name,
+    ret {name: /* FIXME (#2543) */ copy v.name,
          attrs: attrs,
          args: args, id: fld.new_id(v.id),
          disr_expr: de,
@@ -550,7 +551,7 @@ fn noop_fold_variant(v: variant_, fld: ast_fold) -> variant_ {
 }
 
 fn noop_fold_ident(&&i: ident, _fld: ast_fold) -> ident {
-    ret /* FIXME: bad */ copy i;
+    ret /* FIXME (#2543) */ copy i;
 }
 
 fn noop_fold_path(&&p: path, fld: ast_fold) -> path {
@@ -644,7 +645,7 @@ impl of ast_fold for ast_fold_precursor {
     fn fold_class_item(&&ci: @class_member) -> @class_member {
         @{node: alt ci.node {
            instance_var(nm, t, mt, id, p) {
-               instance_var(/* FIXME: bad */ copy nm,
+               instance_var(/* FIXME (#2543) */ copy nm,
                             (self as ast_fold).fold_ty(t), mt, id, p)
            }
            class_method(m) {
diff --git a/src/libsyntax/parse.rs b/src/libsyntax/parse.rs
index 4ebdd0dd5b5..d062f4bde6d 100644
--- a/src/libsyntax/parse.rs
+++ b/src/libsyntax/parse.rs
@@ -17,7 +17,7 @@ import attr::parser_attr;
 import common::parser_common;
 import ast::node_id;
 import util::interner;
-// FIXME: resolve badness
+// FIXME (#1935): resolve badness
 import lexer::*;//{string_reader_as_reader, tt_reader_as_reader,
                //reader, string_reader, tt_reader};
 import diagnostic::{span_handler, mk_span_handler, mk_handler, emitter};
@@ -75,7 +75,7 @@ fn parse_crate_from_crate_file(input: str, cfg: ast::crate_cfg,
     let cdirs = p.parse_crate_directives(token::EOF, first_cdir_attr);
     sess.chpos = rdr.chpos;
     sess.byte_pos = sess.byte_pos + rdr.pos;
-    let cx = @{sess: sess, cfg: /* FIXME: bad */ copy p.cfg};
+    let cx = @{sess: sess, cfg: /* FIXME (#2543) */ copy p.cfg};
     let (companionmod, _) = path::splitext(path::basename(input));
     let (m, attrs) = eval::eval_crate_directives_to_mod(
         cx, cdirs, prefix, option::some(companionmod));
@@ -85,7 +85,7 @@ fn parse_crate_from_crate_file(input: str, cfg: ast::crate_cfg,
                           {directives: cdirs,
                            module: m,
                            attrs: crate_attrs + attrs,
-                           config: /* FIXME: bad */ copy p.cfg});
+                           config: /* FIXME (#2543) */ copy p.cfg});
 }
 
 fn parse_crate_from_source_file(input: str, cfg: ast::crate_cfg,
diff --git a/src/libsyntax/parse/common.rs b/src/libsyntax/parse/common.rs
index b8362eb8734..52cb9366df8 100644
--- a/src/libsyntax/parse/common.rs
+++ b/src/libsyntax/parse/common.rs
@@ -93,8 +93,8 @@ impl parser_common for parser {
     fn eat_keyword(word: str) -> bool {
         self.require_keyword(word);
 
-        // FIXME: this gratuitous use of @ is to
-        // workaround LLVM bug #13042
+        // FIXME (#13042): this gratuitous use of @ is to
+        // workaround LLVM bug.
         alt @self.token {
           @token::IDENT(sid, false) {
             if str::eq(word, *self.get_str(sid)) {
diff --git a/src/libsyntax/parse/eval.rs b/src/libsyntax/parse/eval.rs
index 5ef8417ec6f..ae11c883443 100644
--- a/src/libsyntax/parse/eval.rs
+++ b/src/libsyntax/parse/eval.rs
@@ -103,7 +103,7 @@ fn eval_crate_directive(cx: ctx, cdir: @ast::crate_directive, prefix: str,
         let m0 = p0.parse_mod_items(token::EOF, first_item_outer_attrs);
 
         let i = p0.mk_item(cdir.span.lo, cdir.span.hi,
-                           /* FIXME: bad */ copy id,
+                           /* FIXME (#2543) */ copy id,
                            ast::item_mod(m0), ast::public, mod_attrs);
         // Thread defids, chpos and byte_pos through the parsers
         cx.sess.chpos = r0.chpos;
@@ -119,7 +119,7 @@ fn eval_crate_directive(cx: ctx, cdir: @ast::crate_directive, prefix: str,
         let (m0, a0) = eval_crate_directives_to_mod(
             cx, cdirs, full_path, none);
         let i =
-            @{ident: /* FIXME: bad */ copy id,
+            @{ident: /* FIXME (#2543) */ copy id,
               attrs: attrs + a0,
               id: cx.sess.next_id,
               node: ast::item_mod(m0),
diff --git a/src/libsyntax/parse/lexer.rs b/src/libsyntax/parse/lexer.rs
index bbf5330c18a..02b34e8dc86 100644
--- a/src/libsyntax/parse/lexer.rs
+++ b/src/libsyntax/parse/lexer.rs
@@ -414,9 +414,9 @@ fn scan_number(c: char, rdr: string_reader) -> token::token {
             bump(rdr);
             ret token::LIT_FLOAT(intern(*rdr.interner, @num_str),
                                  ast::ty_f64);
-            /* FIXME: if this is out of range for either a 32-bit or
-            64-bit float, it won't be noticed till the back-end (Issue #2252)
-            */
+            /* FIXME (#2252): if this is out of range for either a
+            32-bit or 64-bit float, it won't be noticed till the
+            back-end.  */
         } else {
             is_float = true;
         }
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs
index 146c3ab3de9..46e838fd4be 100644
--- a/src/libsyntax/parse/parser.rs
+++ b/src/libsyntax/parse/parser.rs
@@ -17,10 +17,10 @@ import dvec::{dvec, extensions};
 export file_type;
 export parser;
 
-// FIXME: #ast expects to find this here but it's actually defined in `parse`
-// Fixing this will be easier when we have export decls on individual items --
-// then parse can export this publicly, and everything else crate-visibly.
-// (See #1893)
+// FIXME (#1893): #ast expects to find this here but it's actually
+// defined in `parse` Fixing this will be easier when we have export
+// decls on individual items -- then parse can export this publicly, and
+// everything else crate-visibly.
 import parse_from_source_str;
 export parse_from_source_str;
 
@@ -172,10 +172,10 @@ class parser {
             {mode: mode, ty: p.parse_ty(false), ident: name,
              id: p.get_id()}
         };
-        // FIXME: constrs is empty because right now, higher-order functions
-        // can't have constrained types.
-        // Not sure whether that would be desirable anyway. See #34 for the
-        // story on constrained types.
+        // FIXME (#34): constrs is empty because right now, higher-order
+        // functions can't have constrained types. Not sure whether
+        // that would be desirable anyway. See bug for the story on
+        // constrained types.
         let constrs: [@constr] = [];
         let (ret_style, ret_ty) = self.parse_ret_ty();
         ret {inputs: inputs, output: ret_ty,
@@ -2039,7 +2039,7 @@ class parser {
     }
 
     fn parse_ctor(result_ty: ast::ty_) -> class_contents {
-        // Can ctors/dtors have attrs? FIXME
+        // FIXME (#2660): Can ctors/dtors have attrs?
         let lo = self.last_span.lo;
         let (decl_, _) = self.parse_fn_decl(impure_fn, {|p| p.parse_arg()});
         let decl = {output: @{id: self.get_id(),
@@ -2050,7 +2050,7 @@ class parser {
     }
 
     fn parse_dtor() -> class_contents {
-        // Can ctors/dtors have attrs? FIXME
+        // FIXME (#2660): Can ctors/dtors have attrs?
         let lo = self.last_span.lo;
         let body = self.parse_block();
         dtor_decl(body, mk_sp(lo, self.last_span.hi))
diff --git a/src/libsyntax/print/pprust.rs b/src/libsyntax/print/pprust.rs
index 6bd9e79b727..89f3b2d3aba 100644
--- a/src/libsyntax/print/pprust.rs
+++ b/src/libsyntax/print/pprust.rs
@@ -545,12 +545,11 @@ fn print_item(s: ps, &&item: @ast::item) {
           }
           for items.each {|ci|
                   /*
-                     FIXME: collect all private items and print them
-                     in a single "priv" section
+                     FIXME (#1893): collect all private items and print
+                     them in a single "priv" section
 
                      tjc: I'm not going to fix this yet b/c we might
                      change how exports work, including for class items
-                     (see #1893)
                    */
              hardbreak_if_not_bol(s);
              maybe_print_comment(s, ci.span.lo);
diff --git a/src/libsyntax/visit.rs b/src/libsyntax/visit.rs
index 3b5b73d78de..5d27ee1452f 100644
--- a/src/libsyntax/visit.rs
+++ b/src/libsyntax/visit.rs
@@ -28,7 +28,7 @@ enum fn_kind {
 fn name_of_fn(fk: fn_kind) -> ident {
     alt fk {
       fk_item_fn(name, _) | fk_method(name, _, _) | fk_res(name, _, _)
-          | fk_ctor(name, _, _, _) { /* FIXME: bad */ copy name }
+          | fk_ctor(name, _, _, _) { /* FIXME (#2543) */ copy name }
       fk_anon(*) | fk_fn_block(*) { @"anon" }
       fk_dtor(*)                  { @"drop" }
     }
@@ -38,7 +38,7 @@ fn tps_of_fn(fk: fn_kind) -> [ty_param] {
     alt fk {
       fk_item_fn(_, tps) | fk_method(_, tps, _) | fk_res(_, tps, _)
               | fk_ctor(_, tps, _, _) | fk_dtor(tps, _, _) {
-          /* FIXME: bad */ copy tps
+          /* FIXME (#2543) */ copy tps
       }
       fk_anon(*) | fk_fn_block(*) { [] }
     }
@@ -117,8 +117,8 @@ fn visit_item<E>(i: @item, e: E, v: vt<E>) {
     alt i.node {
       item_const(t, ex) { v.visit_ty(t, e, v); v.visit_expr(ex, e, v); }
       item_fn(decl, tp, body) {
-        v.visit_fn(fk_item_fn(/* FIXME: bad */ copy i.ident,
-                              /* FIXME: bad */ copy tp), decl, body,
+        v.visit_fn(fk_item_fn(/* FIXME (#2543) */ copy i.ident,
+                              /* FIXME (#2543) */ copy tp), decl, body,
                    i.span, i.id, e, v);
       }
       item_mod(m) { v.visit_mod(m, i.span, i.id, e, v); }
@@ -131,8 +131,8 @@ fn visit_item<E>(i: @item, e: E, v: vt<E>) {
         v.visit_ty_params(tps, e, v);
       }
       item_res(decl, tps, body, dtor_id, _, rp) {
-        v.visit_fn(fk_res(/* FIXME: bad */ copy i.ident,
-                          /* FIXME: bad */ copy tps,
+        v.visit_fn(fk_res(/* FIXME (#2543) */ copy i.ident,
+                          /* FIXME (#2543) */ copy tps,
                           rp),
                    decl, body, i.span, dtor_id, e, v);
       }
@@ -287,15 +287,16 @@ fn visit_fn_decl<E>(fd: fn_decl, e: E, v: vt<E>) {
 // because it is not a default impl of any method, though I doubt that really
 // clarifies anything. - Niko
 fn visit_method_helper<E>(m: @method, e: E, v: vt<E>) {
-    v.visit_fn(fk_method(/* FIXME: bad */ copy m.ident,
-                         /* FIXME: bad */ copy m.tps, m),
+    v.visit_fn(fk_method(/* FIXME (#2543) */ copy m.ident,
+                         /* FIXME (#2543) */ copy m.tps, m),
                m.decl, m.body, m.span, m.id, e, v);
 }
 
 // Similar logic to the comment on visit_method_helper - Tim
 fn visit_class_ctor_helper<E>(ctor: class_ctor, nm: ident, tps: [ty_param],
                               parent_id: def_id, e: E, v: vt<E>) {
-    v.visit_fn(fk_ctor(/* FIXME: bad */ copy nm, /* FIXME: bad */ copy tps,
+    v.visit_fn(fk_ctor(/* FIXME (#2543) */ copy nm,
+                       /* FIXME (#2543) */ copy tps,
                        ctor.node.self_id, parent_id), ctor.node.dec,
                ctor.node.body, ctor.span, ctor.node.id, e, v)
 
@@ -303,7 +304,7 @@ fn visit_class_ctor_helper<E>(ctor: class_ctor, nm: ident, tps: [ty_param],
 
 fn visit_class_dtor_helper<E>(dtor: class_dtor, tps: [ty_param],
                               parent_id: def_id, e: E, v: vt<E>) {
-    v.visit_fn(fk_dtor(/* FIXME: bad */ copy tps, dtor.node.self_id,
+    v.visit_fn(fk_dtor(/* FIXME (#2543) */ copy tps, dtor.node.self_id,
                        parent_id), ast_util::dtor_dec(),
                dtor.node.body, dtor.span, dtor.node.id, e, v)