go/src
Keith Randall 731bdc5115 runtime: fix aeshash of empty string
Aeshash currently computes the hash of the empty string as
hash("", seed) = seed.  This is bad because the hash of a compound
object with empty strings in it doesn't include information about
where those empty strings were.  For instance [2]string{"", "foo"}
and [2]string{"foo", ""} might get the same hash.

Fix this by returning a scrambled seed instead of the seed itself.
With this fix, we can remove the scrambling done by the generated
array hash routines.

The test also rejects hash("", seed) = 0, if we ever thought
it would be a good idea to try that.

The fallback hash is already OK in this regard.

Change-Id: Iaedbaa5be8d6a246dc7e9383d795000e0f562037
Reviewed-on: https://go-review.googlesource.com/14129
Reviewed-by: jcd . <jcd@golang.org>
2015-09-15 17:51:23 +00:00
..
archive archive/zip: fixes unexpected EOF when reading archive 2015-09-11 00:32:59 +00:00
bufio bufio: Remove unneeded error initialization 2015-07-18 18:05:23 +00:00
builtin builtin: remove errant space in hyphenated adjective phrase 2015-06-28 21:41:38 +00:00
bytes bytes: improve Compare function on amd64 for large byte arrays 2015-08-26 03:52:20 +00:00
cmd runtime: fix aeshash of empty string 2015-09-15 17:51:23 +00:00
compress compress/lzw: tidy up some flush calls. 2015-09-09 01:45:00 +00:00
container
crypto crypto/x509: map/slice literals janitoring 2015-09-11 14:04:11 +00:00
database/sql database/sql: fix typo 2015-09-14 00:20:55 +00:00
debug all: remove executable bit from several files 2015-09-04 02:59:49 +00:00
encoding encoding/base64,xml: map/slice literals janitoring 2015-09-11 14:05:40 +00:00
errors
expvar
flag flag: add comment stating that Set is called in sequence across the command line 2015-07-16 05:33:47 +00:00
fmt fmt: allow any type in a format's width argument 2015-09-10 20:53:22 +00:00
go go/parser: better error message for unexpected ',' in struct type 2015-09-14 23:37:18 +00:00
hash hash/*: document the byte order used by the Sum methods 2015-09-10 03:34:23 +00:00
html html/template: preserve attr in stateBeforeValue 2015-09-09 23:31:06 +00:00
image image/png: reject zero-width and zero-height images. 2015-09-09 02:53:58 +00:00
index/suffixarray
internal runtime,internal/trace: map/slice literals janitoring 2015-09-11 14:03:43 +00:00
io io: add WriteString support to MultiWriter 2015-09-01 04:00:12 +00:00
log log: fix flaky test 2015-06-18 18:08:17 +00:00
math math/big: Add small complete example of big.Rat usage 2015-09-15 17:46:22 +00:00
mime mime: fix docs for WordDecoder.Decode 2015-09-10 21:50:17 +00:00
net net: remove named parameters in Listener.Accept doc signature 2015-09-15 04:07:24 +00:00
os os: remove a redundant branch in File.Read. 2015-08-31 04:42:04 +00:00
path all: fix some vet-caught formatting errors, mostly but not only in tests 2015-08-21 05:37:36 +00:00
reflect runtime: on map update, don't overwrite key if we don't need to. 2015-09-09 21:06:49 +00:00
regexp regexp: small correction to test comment 2015-06-14 17:09:13 +00:00
runtime runtime: fix aeshash of empty string 2015-09-15 17:51:23 +00:00
sort sort: Fix typo in Stable() comment 2015-08-17 06:58:16 +00:00
strconv strconv: fix comment 2015-09-10 21:31:07 +00:00
strings all: link to https for golang subdomains too 2015-07-12 04:42:40 +00:00
sync runtime, sync/atomic: add memory barriers in arm cas routines 2015-07-30 20:11:11 +00:00
syscall syscall: implement getwd on Solaris 2015-09-09 19:58:33 +00:00
testing testing/quick: terminate for arbitrary recursive types 2015-08-29 19:23:37 +00:00
text text/template: verify that names in FuncMap are valid identifiers 2015-09-15 16:09:55 +00:00
time time: allow any one- or two-digit day of the month when parsing. 2015-09-10 20:27:53 +00:00
unicode unicode: include rune 0 in RangeTables. 2015-08-24 15:05:48 +00:00
unsafe
Make.dist
all.bash
all.bat
all.rc
androidtest.bash androidtest.bash: robust cleanup in case of failure. 2015-07-17 21:12:12 +00:00
bootstrap.bash build: Fix bootstrap.bash for official source tarballs 2015-09-01 19:52:59 +00:00
buildall.bash buildall.bash: exit 1 when make.bash fails 2015-05-17 01:40:33 +00:00
clean.bash build: clean current tree in clean.bash 2015-08-05 19:36:15 +00:00
clean.bat build: fix clean scripts 2015-06-18 16:13:13 +00:00
clean.rc build: fix clean scripts 2015-06-18 16:13:13 +00:00
iostest.bash
make.bash make.bash: abort if $GOROOT_BOOTSTRAP == $GOROOT 2015-08-24 03:04:52 +00:00
make.bat doc: replace references to {5..9}{g,l} with go tool compile and go tool link 2015-06-17 04:05:50 +00:00
make.rc doc: replace references to {5..9}{g,l} with go tool compile and go tool link 2015-06-17 04:05:50 +00:00
nacltest.bash
race.bash all: link to https instead of http 2015-07-11 14:36:33 +00:00
race.bat all: link to https instead of http 2015-07-11 14:36:33 +00:00
run.bash
run.bat
run.rc