diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2015-01-07 17:26:58 -0800 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2015-01-07 17:26:58 -0800 |
| commit | 6e806bdefde91af102567ef4b5dbd3ccf0c5c2ec (patch) | |
| tree | b8627ad2c80976f618b661ec14695f6a322ad1b3 /src/libterm/terminfo/parser/compiled.rs | |
| parent | f6a7dc5528a9a9ac36867bbca2a6044b7be5bce2 (diff) | |
| parent | 7d72719efc25c6cdb8963c187e93df646ba65245 (diff) | |
| download | rust-6e806bdefde91af102567ef4b5dbd3ccf0c5c2ec.tar.gz rust-6e806bdefde91af102567ef4b5dbd3ccf0c5c2ec.zip | |
rollup merge of #20721: japaric/snap
Conflicts: src/libcollections/vec.rs src/libcore/fmt/mod.rs src/librustc/lint/builtin.rs src/librustc/session/config.rs src/librustc_trans/trans/base.rs src/librustc_trans/trans/context.rs src/librustc_trans/trans/type_.rs src/librustc_typeck/check/_match.rs src/librustdoc/html/format.rs src/libsyntax/std_inject.rs src/libsyntax/util/interner.rs src/test/compile-fail/mut-pattern-mismatched.rs
Diffstat (limited to 'src/libterm/terminfo/parser/compiled.rs')
| -rw-r--r-- | src/libterm/terminfo/parser/compiled.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libterm/terminfo/parser/compiled.rs b/src/libterm/terminfo/parser/compiled.rs index 7a06849abd1..4735b6e8f2a 100644 --- a/src/libterm/terminfo/parser/compiled.rs +++ b/src/libterm/terminfo/parser/compiled.rs @@ -284,13 +284,13 @@ pub fn parse(file: &mut io::Reader, longnames: bool) // Find the offset of the NUL we want to go to - let nulpos = string_table.index(&((offset as uint) .. (string_table_bytes as uint))) + let nulpos = string_table[(offset as uint) .. (string_table_bytes as uint)] .iter().position(|&b| b == 0); match nulpos { Some(len) => { string_map.insert(name.to_string(), - string_table.index(&((offset as uint) .. - (offset as uint + len))).to_vec()) + string_table[(offset as uint) .. + (offset as uint + len)].to_vec()) }, None => { return Err("invalid file: missing NUL in \ |
