From 9cf271fe96b474d514b1052935db70c4056cf076 Mon Sep 17 00:00:00 2001 From: Niko Matsakis Date: Tue, 18 Sep 2012 21:41:37 -0700 Subject: De-mode vec::each() and many of the str iteration routines Note that the method foo.each() is not de-moded, nor the other vec routines. --- src/libsyntax/ext/qquote.rs | 2 +- src/libsyntax/ext/simplext.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src/libsyntax/ext') diff --git a/src/libsyntax/ext/qquote.rs b/src/libsyntax/ext/qquote.rs index d97124d5f44..da37e44b58c 100644 --- a/src/libsyntax/ext/qquote.rs +++ b/src/libsyntax/ext/qquote.rs @@ -228,7 +228,7 @@ fn finish let mut state = active; let mut i = 0u, j = 0u; let g_len = cx.gather.len(); - do str::chars_iter(*str) |ch| { + for str::chars_each(*str) |ch| { if (j < g_len && i == cx.gather[j].lo) { assert ch == '$'; let repl = fmt!("$%u ", j); diff --git a/src/libsyntax/ext/simplext.rs b/src/libsyntax/ext/simplext.rs index 08fa427d078..2061be58488 100644 --- a/src/libsyntax/ext/simplext.rs +++ b/src/libsyntax/ext/simplext.rs @@ -211,7 +211,7 @@ pure fn follow(m: arb_depth, idx_path: &[uint]) -> for vec::each(idx_path) |idx| { res = match res { leaf(_) => return res,/* end of the line */ - seq(new_ms, _) => new_ms[idx] + seq(new_ms, _) => new_ms[*idx] } } return res; -- cgit 1.4.1-3-g733a5