cmd/go: run examples in source order, not name order

Add Order field to doc.Example and write doc comments there.

Fixes issue 4662.

R=golang-dev, iant
CC=golang-dev
https://codereview.appspot.com/7229071
lib9/main.c: don't show the crash dialog on windows
Fixes issue 3202. (Or rather, work around issue 3202)

R=alex.brainman, rsc
CC=golang-dev
https://codereview.appspot.com/7202053
testing: add AllocsPerRun

This CL also replaces similar loops in other stdlib
package tests with calls to AllocsPerRun.

Fixes issue 4461.

R=minux.ma, rsc
CC=golang-dev
https://codereview.appspot.com/7002055

Committer: Russ Cox <rsc@golang.org>
cmd/gc: remove spurious newline from node dump

R=ken2
CC=golang-dev
https://codereview.appspot.com/7276048
cmd/gc: avoid duplicate allocation during inlining

Fixes issue 4667.

R=ken2
CC=golang-dev
https://codereview.appspot.com/7275046
cmd/gc: treat &T{} like new(T): allocate on stack if possible

Fixes issue 4618.

R=ken2
CC=golang-dev
https://codereview.appspot.com/7278048
cmd/gc: allow new conversion syntax

For consistency with conversions that look like function calls,
conversions that don't look like function calls now allow an
optional trailing comma.

That is, int(x,) has always been syntactically valid.
Now []int(x,) is valid too.

Fixes issue 4162.

R=ken2
CC=golang-dev
https://codereview.appspot.com/7288045
cmd/gc: elide self-assignment during return

More efficient, less racy code.

Fixes issue 4014.

R=ken2, ken
CC=golang-dev
https://codereview.appspot.com/7275047
cmd/gc: remove reference to ? and @ symbols in error message

Those symbols are only allowed during imports;
the parser may expect them but saying that doesn't help users.

Fixes issue 3434.

R=ken2
CC=golang-dev
https://codereview.appspot.com/7277045
exp/gotype: disable broken test

R=golang-dev, iant
CC=golang-dev
https://codereview.appspot.com/7275045
cmd/gc: update ideal bool rules to match latest spec

Fixes issue 3915.
Fixes issue 3923.

R=ken2
CC=golang-dev
https://codereview.appspot.com/7281044
cmd/gc: clean up string index errors

Unify with array/slice errors, which were already good.

Fixes issue 4232.

R=ken2
CC=golang-dev
https://codereview.appspot.com/7271046
cmd/gc: make inlined labels distinct

Fixes issue 4748.

R=ken2
CC=golang-dev
https://codereview.appspot.com/7261044
xml: omit newline at beginning of MarshalIndent output

(Still valid XML.)

Fixes issue 3354.

R=golang-dev, dave
CC=golang-dev
https://codereview.appspot.com/7288047

Committer: Russ Cox <rsc@golang.org>
cmd/5l, cmd/ld: support generating ELF binaries for NetBSD/ARM

R=golang-dev, dave
CC=golang-dev
https://codereview.appspot.com/7261043
cmd/go: update 'go get' help message

It accepts all the build flags.
Say that instead of making a copy that will go stale.

Fixes issue 4742.

R=golang-dev, minux.ma
CC=golang-dev
https://codereview.appspot.com/7229081
cmd/gc: implement latest rules for checking make sizes

Fixes issue 4085.

R=ken2
CC=golang-dev
https://codereview.appspot.com/7277047
A+C: add Yusuke Kagiwada (Individual CLA)

R=golang-dev, rsc
CC=golang-dev
https://codereview.appspot.com/7292043
cmd/gc: slightly better code generation

* Avoid treating CALL fn(SB) as justification for introducing
and tracking a registerized variable for fn(SB).

* Remove USED(n) after declaration and zeroing of n.
It was left over from when the compiler emitted more
aggressive set and not used errors, and it was keeping
the optimizer from removing a redundant zeroing of n
when n was a pointer or integer variable.

Update issue 597.

R=ken2
CC=golang-dev
https://codereview.appspot.com/7277048