1
0
mirror of https://github.com/golang/go synced 2024-11-18 20:04:52 -07:00
go/src
Robert Griesemer 32db3f2756 cmd/compile/internal/syntax: support for alias declarations
Permits parsing of alias declarations with -newparser

	const/type/var/func T => p.T

but the compiler will reject it with an error. For now this
also accepts

	type T = p.T

so we can experiment with a type-alias only scenario.

- renamed _Arrow token to _Larrow (<-)
- introduced _Rarrow token (=>)
- introduced AliasDecl node
- extended scanner to accept _Rarrow
- extended parser and printer to handle alias declarations

Change-Id: I0170d10a87df8255db9186d466b6fd405228c38e
Reviewed-on: https://go-review.googlesource.com/29355
Run-TryBot: Robert Griesemer <gri@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2016-09-16 20:58:20 +00:00
..
archive archive/tar: reapply Header.Size to regFileReader after merging 2016-09-02 21:58:53 +00:00
bufio
builtin builtin: clarify that make(map[K]V, n) allocates space for n elements 2016-09-10 12:57:37 +00:00
bytes bytes: cut 10 seconds off the race builder's benchmark test 2016-09-14 18:22:16 +00:00
cmd cmd/compile/internal/syntax: support for alias declarations 2016-09-16 20:58:20 +00:00
compress compress/flate: clarify the behavior of Writer.Flush 2016-09-04 03:09:08 +00:00
container
context context: add examples 2016-09-09 22:50:41 +00:00
crypto crypto/rsa: ensure that generating toy RSA keys doesn't loop. 2016-09-13 20:22:42 +00:00
database/sql database/sql: don't hang if the driver Exec method panics 2016-08-29 16:51:56 +00:00
debug all: use testing.GoToolPath instead of "go" 2016-08-30 22:49:11 +00:00
encoding encoding/asn1: reduce allocations in Marshal 2016-09-13 21:05:27 +00:00
errors
expvar
flag flag: use strconv instead of fmt in values' String funcs 2016-09-10 10:29:44 +00:00
fmt doc: avoid mentioning non-existence of u flag to fmt.Printf. 2016-09-09 00:04:21 +00:00
go plugin: new package for loading plugins 2016-09-16 17:54:40 +00:00
hash hash/crc32: cleanup code and improve tests 2016-08-31 15:17:57 +00:00
html
image image/draw: optimize drawFillOver as drawFillSrc for opaque fills. 2016-09-09 01:17:26 +00:00
index/suffixarray
internal internal/testenv: add GoTool 2016-09-10 20:50:12 +00:00
io io/ioutil: return better error when TempDir called with non-extant dir 2016-09-08 15:08:35 +00:00
log
math math/big: cut 2 minutes off race tests 2016-09-14 19:11:43 +00:00
mime mime/quotedprintable: accept trailing soft line-break at the end of message 2016-09-11 01:51:07 +00:00
net net: document dummy byte in ReadMsgUnix and WriteMsgUnix 2016-09-15 23:42:46 +00:00
os os/exec: add examples for CombinedOutput, StdinPipe, StderrPipe 2016-09-16 03:41:53 +00:00
path path/filepath: handle "C:." correctly in EvalSymlinks on Windows 2016-09-05 00:53:32 +00:00
plugin plugin: new package for loading plugins 2016-09-16 17:54:40 +00:00
reflect reflect: update location of vet tool in comment 2016-09-09 15:02:46 +00:00
regexp regexp: don't run slow benchmarks on race builders 2016-09-14 18:17:06 +00:00
runtime plugin: new package for loading plugins 2016-09-16 17:54:40 +00:00
sort sort: add examples for sort.Search 2016-09-16 04:47:43 +00:00
strconv strconv: fix function name in errors for Atoi 2016-09-04 00:17:58 +00:00
strings strings: use AVX2 for Index if available 2016-09-07 10:43:13 +00:00
sync cmd/compile: intrinsify sync/atomic for amd64 2016-08-30 15:23:23 +00:00
syscall syscall: add bounds checking and error returns to ParseNetlinkMessage 2016-09-14 08:42:28 +00:00
testing testing: improve the documentation for the -run flag 2016-09-12 06:12:35 +00:00
text text/template: improve lexer performance in finding left delimiters. 2016-09-13 12:51:13 +00:00
time time: document in UnixNano when the value is valid 2016-09-14 21:07:35 +00:00
unicode unicode/utf8: reduce bounds checks in EncodeRune 2016-09-03 20:05:36 +00:00
unsafe
vendor/golang_org/x/net net/http: update bundled x/net/http2 2016-09-13 19:15:41 +00:00
all.bash
all.bat
all.rc
androidtest.bash androidtest.bash: use go list to get pkg dir 2016-08-29 15:24:39 +00:00
bootstrap.bash
buildall.bash
clean.bash
clean.bat
clean.rc
cmp.bash
iostest.bash
make.bash
make.bat
Make.dist
make.rc
naclmake.bash
nacltest.bash
race.bash
race.bat
run.bash
run.bat
run.rc