Add test for #6155
rustc::typeck: fix array out of bounds

Fixes #6155
pass correct flags to jemalloc for cross-compiling
A reminder that a block is a single expr in closures

This is something that's only been briefly mentioned in the beginning of
the tutorial and all of the closure examples within this subsection
include only one expression between { and }.
Lexer: Fix offset handling in get_str_from()

As the comment said, the subtraction is bogus for multibyte characters.
Fortunately, we can just use last_pos instead of pos to get the correct
position without any subtraction hackery.
add the Iterator trait to the prelude
testsuite: Add test cases that pass
auto merge of #6695 : catamorphism/rust/moretestcases, r=catamorphism
auto merge of #6920 : catamorphism/rust/issue-4765, r=bstrie

r? anybody As per #4765
auto merge of #7000 : Blei/rust/fix-6155, r=catamorphism
auto merge of #7003 : alco/rust/tutorial-block-expr, r=bstrie

This is something that's only been briefly mentioned in the beginning of
the tutorial and all of the closure examples within this subsection
include only one expression between { and }.
auto merge of #7005 : dotdash/rust/fix_get_str_from, r=bstrie

As the comment said, the subtraction is bogus for multibyte characters.
Fortunately, we can just use last_pos instead of pos to get the correct
position without any subtraction hackery.
auto merge of #7007 : thestinger/rust/jemalloc, r=catamorphism

It's still broken because `jemalloc`'s `configure` script doesn't work when the build triple doesn't match the target triple due to missing a way to get the page size. I'm not entirely sure how to pass a hardcoded value to autoconf/configure.

This at least gets it a bit further along.
auto merge of #7008 : thestinger/rust/iterator, r=catamorphism

The `IteratorUtil` trait hits a bug in method resolve, but the basic trait has no issue.
std: add reverse vec iterators, replace vec::each*_reverse.
std: remove {all*,any*,count} in favour of iterators
std: remove fold[lr] in favour of iterators
std: remove foldr and alli methods in vec
std: remove each_char* fns and methods from str, replaced by iterators.
std: replace the str::each* fns/methods with byte iterators