diff options
| author | Marijn Haverbeke <[email protected]> | 2011-05-06 22:13:13 +0200 |
|---|---|---|
| committer | Marijn Haverbeke <[email protected]> | 2011-05-06 22:51:19 +0200 |
| commit | a3ec0b1f643d00b9418e4884bd7caa07bf052201 (patch) | |
| tree | 82000510ac9c9cf3f0c7cf4ae5f3c6b123b559cb /src/comp/front/codemap.rs | |
| parent | Register new snapshots. (diff) | |
| download | rust-a3ec0b1f643d00b9418e4884bd7caa07bf052201.tar.xz rust-a3ec0b1f643d00b9418e4884bd7caa07bf052201.zip | |
Rename std modules to be camelcased
(Have fun mergining your stuff with this.)
Diffstat (limited to 'src/comp/front/codemap.rs')
| -rw-r--r-- | src/comp/front/codemap.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/comp/front/codemap.rs b/src/comp/front/codemap.rs index 402b4884..578f574b 100644 --- a/src/comp/front/codemap.rs +++ b/src/comp/front/codemap.rs @@ -1,4 +1,4 @@ -import std._vec; +import std.Vec; /* A codemap is a thing that maps uints to file/line/column positions * in a crate. This to make it possible to represent the positions @@ -24,18 +24,18 @@ fn new_filemap(str filename, uint start_pos) -> filemap { } fn next_line(filemap file, uint pos) { - _vec.push[uint](file.lines, pos); + Vec.push[uint](file.lines, pos); } fn lookup_pos(codemap map, uint pos) -> loc { - auto a = 0u; auto b = _vec.len[filemap](map.files); + auto a = 0u; auto b = Vec.len[filemap](map.files); while (b - a > 1u) { auto m = (a + b) / 2u; if (map.files.(m).start_pos > pos) { b = m; } else { a = m; } } auto f = map.files.(a); - a = 0u; b = _vec.len[uint](f.lines); + a = 0u; b = Vec.len[uint](f.lines); while (b - a > 1u) { auto m = (a + b) / 2u; if (f.lines.(m) > pos) { b = m; } |