Enhance auto_encode to take number of struct fields

emit_struct and read_struct takes an additional len:uint parameter which tells
us how many fields the struct we are working on has.

This is required to implement an Encoder for the msgpack [1] serialization
format. To serialize a struct with msgpack you have to use arrays and the size
of the array has to be know before each of the elements are written out. JSON
as an example doesn't have this problem as it uses '[' and ']' delimiters for
arrays.

[1]: www.msgpack.org
doc: Fold information from the memory model interlude in the tutorial elsewhere
Reflect on char as u32, not uint (which may be u64).

Fixes mozilla/rust#4473.
Add a test for vec::retain
Use vec::truncate for vec::retain
spelling fixes for iter module docstrings
Merge pull request #4486 from thestinger/spelling

spelling fixes for iter module docstrings
Merge remote-tracking branch 'mneumann/f-serialize'
Add cfg attrs to handle auto_encode transition
Add Kyeongwoon Lee to AUTHORS
Merge pull request #4477 from jld/char-repr

Reflect on char as u32, not uint (which may be u64).
allowing the entry point name to be something other than main
add build tests
Merge pull request #4484 from sanxiyn/test-retain

Add a test for vec::retain
Add Seo Sanghyeon to AUTHORS
Merge pull request #4485 from sanxiyn/use-truncate

Use vec::truncate for vec::retain
syntax/rustc: Eliminate some bad copies

r=pcwalton
removed self-import (minor cleanup)
Merge pull request #4491 from jbclements/removed-ast-self-import

removed self-import (minor cleanup)
s/moved variable/moved value/
Change ast::path into a struct.