diff options
| author | Marijn Haverbeke <[email protected]> | 2011-04-08 18:44:20 +0200 |
|---|---|---|
| committer | Marijn Haverbeke <[email protected]> | 2011-04-09 01:05:18 +0200 |
| commit | 1af3174fe3b565371a5978381f604ea9c01e86d3 (patch) | |
| tree | 1690b133b0690fdf6a2c005528355c2d00313129 /src/comp/util | |
| parent | Make lexer buffer the whole file (diff) | |
| download | rust-1af3174fe3b565371a5978381f604ea9c01e86d3.tar.xz rust-1af3174fe3b565371a5978381f604ea9c01e86d3.zip | |
Move to single-uint file-position representation.
This makes passing them around cheaper. There is now a table (see
front/codemap.rs) that is needed to transform such an uint into an
actual filename/line/col location.
Also cleans up the span building in the parser a bit.
Diffstat (limited to 'src/comp/util')
| -rw-r--r-- | src/comp/util/common.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/comp/util/common.rs b/src/comp/util/common.rs index 6dec6c00..b33a7db2 100644 --- a/src/comp/util/common.rs +++ b/src/comp/util/common.rs @@ -5,8 +5,7 @@ import front.ast; type filename = str; -type pos = rec(uint line, uint col); -type span = rec(filename filename, pos lo, pos hi); +type span = rec(uint lo, uint hi); type spanned[T] = rec(T node, span span); tag ty_mach { |