Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 889be71

Browse files
committedJul 5, 2012
Comments only: change TODOs to FIXMEs and annotate them
1 parent 50d2e7e commit 889be71

File tree

13 files changed

+19
-20
lines changed

13 files changed

+19
-20
lines changed
 

‎src/libstd/rope.rs

+5-3
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,8 @@ mod node {
588588
* Used for rebalancing and to allocate stacks for traversals.
589589
*/
590590
type concat = {
591-
left: @node,//TODO: Perhaps a `vec` instead of `left`/`right`
591+
//FIXME (#2744): Perhaps a `vec` instead of `left`/`right`
592+
left: @node,
592593
right: @node,
593594
char_len: uint,
594595
byte_len: uint,
@@ -732,7 +733,8 @@ mod node {
732733
}
733734

734735
pure fn byte_len(node: @node) -> uint {
735-
alt(*node) {//TODO: Could we do this without the pattern-matching?
736+
//FIXME (#2744): Could we do this without the pattern-matching?
737+
alt(*node) {
736738
leaf(y) { ret y.byte_len; }
737739
concat(y){ ret y.byte_len; }
738740
}
@@ -805,7 +807,7 @@ mod node {
805807
alt(leaf_iterator::next(it)) {
806808
option::none { break; }
807809
option::some(x) {
808-
//TODO: Replace with memcpy or something similar
810+
//FIXME (#2744): Replace with memcpy or something similar
809811
let mut local_buf: ~[u8] =
810812
unsafe::reinterpret_cast(*x.content);
811813
let mut i = x.byte_offset;

‎src/libstd/term.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
33
import core::option;
44

5-
// TODO: Windows support.
5+
// FIXME (#2807): Windows support.
66

77
const color_black: u8 = 0u8;
88
const color_red: u8 = 1u8;

‎src/libstd/treemap.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ fn find<K: copy, V: copy>(m: &const tree_edge<K, V>, k: K) -> option<V> {
5555
alt copy *m {
5656
none { none }
5757

58-
// TODO: was that an optimization?
58+
// FIXME (#2808): was that an optimization?
5959
some(node) {
6060
if k == node.key {
6161
some(node.value)

‎src/libsyntax/attr.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ enum inline_attr {
368368

369369
/// True if something like #[inline] is found in the list of attrs.
370370
fn find_inline_attr(attrs: ~[ast::attribute]) -> inline_attr {
371-
// TODO---validate the usage of #[inline] and #[inline(always)]
371+
// FIXME (#2809)---validate the usage of #[inline] and #[inline(always)]
372372
do vec::foldl(ia_none, attrs) |ia,attr| {
373373
alt attr.node.value.node {
374374
ast::meta_word(@"inline") { ia_hint }

‎src/libsyntax/ext/auto_serialize.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ Similarly, the code to deserialize an instance of a non-built-in type
5858
where `c_Ti` is the code to deserialize an instance of `Ti` using the
5959
deserializer `d`.
6060
61-
TODO--Hygiene. Search for "__" strings. We also assume "std" is the
61+
FIXME (#2810)--Hygiene. Search for "__" strings. We also assume "std" is the
6262
standard library.
6363
6464
Misc notes:

‎src/libsyntax/parse/lexer.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ enum tt_frame_up { /* to break a circularity */
2323
tt_frame_up(option<tt_frame>)
2424
}
2525

26-
/* TODO: figure out how to have a uniquely linked stack, and change to `~` */
26+
/* FIXME (#2811): figure out how to have a uniquely linked stack,
27+
and change to `~` */
2728
/// an unzipping of `token_tree`s
2829
type tt_frame = @{
2930
readme: ~[ast::token_tree],

‎src/rustc/back/link.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,8 @@ mod write {
5858
let td = mk_target_data(
5959
sess.targ_cfg.target_strs.data_layout);
6060
llvm::LLVMAddTargetData(td.lltd, pm.llpm);
61-
// TODO: run the linter here also, once there are llvm-c bindings for
62-
// it.
61+
// FIXME (#2812): run the linter here also, once there are llvm-c
62+
// bindings for it.
6363

6464
// Generate a pre-optimization intermediate file if -save-temps was
6565
// specified.

‎src/rustc/middle/astencode.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ impl translation_routines for extended_decode_ctxt {
162162
{crate: ast::local_crate, node: self.tr_id(did.node)}
163163
}
164164
fn tr_span(_span: span) -> span {
165-
ast_util::dummy_sp() // TODO...
165+
ast_util::dummy_sp() // FIXME (#1972): handle span properly
166166
}
167167
}
168168

‎src/rustc/middle/ty.rs

-3
Original file line numberDiff line numberDiff line change
@@ -2758,9 +2758,6 @@ fn lookup_field_type(tcx: ctxt, class_id: def_id, id: def_id,
27582758
some(tpt) { tpt.ty }
27592759
none {
27602760
let tpt = csearch::get_field_type(tcx, class_id, id);
2761-
// ok b/c fields are monomorphic
2762-
// TODO: Comment might be a lie, what if it mentions
2763-
// class-bound ty params?
27642761
tcx.tcache.insert(id, tpt);
27652762
tpt.ty
27662763
}

‎src/rustc/middle/typeck/collect.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,8 @@ fn convert(ccx: @crate_ctxt, it: @ast::item) {
344344
inputs: t_args,
345345
output: t_res,
346346
ret_style: ast::return_val,
347-
constraints: ~[]}); // tjc TODO
347+
constraints: ~[]}); // FIXME (#2813): allow ctors to have
348+
// constraints, or remove constraints from the language
348349
write_ty_to_tcx(tcx, ctor.node.id, t_ctor);
349350
tcx.tcache.insert(local_def(ctor.node.id),
350351
{bounds: tpt.bounds,

‎src/rustc/middle/typeck/infer.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -554,8 +554,8 @@ impl transaction_methods for infer_ctxt {
554554

555555
let r <- self.try(f);
556556

557-
// TODO---could use a vec::clear() that ran destructors but kept
558-
// the vec at its currently allocated length
557+
// FIXME (#2814)---could use a vec::clear() that ran destructors but
558+
// kept the vec at its currently allocated length
559559
self.tvb.bindings = ~[];
560560
self.rb.bindings = ~[];
561561

‎src/test/bench/task-perf-word-count-generic.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ fn main(argv: ~[str]) {
235235

236236
out.write_line(#fmt["Usage: %s <filename> ...", argv[0]]);
237237

238-
// TODO: run something just to make sure the code hasn't
238+
// FIXME (#2815): run something just to make sure the code hasn't
239239
// broken yet. This is the unit test mode of this program.
240240

241241
ret;

‎src/test/run-pass/unchecked-predicates.rs

-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
// Uses foldl to exhibit the unchecked block syntax.
2-
// TODO: since list's head/tail require the predicate "is_not_empty" now and
3-
// we have unit tests for list, this test might me not necessary anymore?
42
use std;
53

64
import std::list::*;

0 commit comments

Comments
 (0)
Please sign in to comment.