mirror of https://github.com/golang/go.git
- This change implements the correct type-based equivalence relation for aggregate types. e.g. comparison of struct types no longer compares the anonymous fields. We do analogous things for hash(). - equals() and eqnil() have been separated: the former panics for uncomparable types, the latter permits comparisons of slice/map/func types against a literal nil and is intended for use only by "static" ssa.BinOp(EQL), not "dynamic" slice comparisons encountered during (e.g.) interface comparisons, which should panic regardless of operand nilness. - we use a (global) typemap.Hasher to compute type hashes; hashing the Type.String() value was not sound. + tests. NB, this change unearthed a bug in defer/recover within init(); it will be fixed in a followup change. R=gri, crawshaw CC=golang-dev https://golang.org/cl/13719043 |
||
|---|---|---|
| .. | ||
| interp | ||
| testdata | ||
| blockopt.go | ||
| builder.go | ||
| builder_test.go | ||
| const.go | ||
| create.go | ||
| doc.go | ||
| dom.go | ||
| emit.go | ||
| example_test.go | ||
| func.go | ||
| lift.go | ||
| lvalue.go | ||
| print.go | ||
| promote.go | ||
| sanity.go | ||
| source.go | ||
| source_test.go | ||
| ssa.go | ||
| stdlib_test.go | ||
| testmain.go | ||
| util.go | ||
| visit.go | ||