1
0
mirror of https://github.com/golang/go synced 2024-09-30 02:14:29 -06:00
The Go programming language
Go to file
Robert Griesemer d2b512160e cmd/compile/internal/types2: differently named types are not assignable
When checking assignability, a value of a named type (incl. a type parameter)
can never be assigned to a variable of a differently named type. Specifically,
if the types are two differently named type parameters, then values of one are
never assignable to variables of the other.

This CL clarifies the assignabiliy rules and simplifies the implementation.

Fixes #49242.

Change-Id: Id72a2c9bed5cdb726855e7a707137db1009e7953
Reviewed-on: https://go-review.googlesource.com/c/go/+/360274
Trust: Robert Griesemer <gri@golang.org>
Reviewed-by: Robert Findley <rfindley@google.com>
2021-11-01 15:55:20 +00:00
.github .github: update IRC server 2021-09-30 19:56:27 +00:00
api cmd/go: stamp VCS revision and uncommitted status into binaries 2021-10-14 18:44:37 +00:00
doc Revert "cmd/go: remove support for -buildmode=shared" 2021-10-29 17:32:24 +00:00
lib/time lib/time: fix RFC 6557 url 2021-08-15 02:18:46 +00:00
misc Revert "cmd/go: remove support for -buildmode=shared" 2021-10-29 17:32:24 +00:00
src cmd/compile/internal/types2: differently named types are not assignable 2021-11-01 15:55:20 +00:00
test test/codegen: updated arithmetic tests to verify on ppc64,ppc64le 2021-11-01 13:12:37 +00:00
.gitattributes
.gitignore internal/buildcfg: move build configuration out of cmd/internal/objabi 2021-04-16 19:20:53 +00:00
AUTHORS net/http: guarantee that the Transport dial functions are respected in js/wasm 2021-10-28 17:57:57 +00:00
codereview.cfg
CONTRIBUTING.md
CONTRIBUTORS net/http: guarantee that the Transport dial functions are respected in js/wasm 2021-10-28 17:57:57 +00:00
LICENSE
PATENTS
README.md README.md: update contribute URL 2021-09-30 13:33:21 +00:00
SECURITY.md

The Go Programming Language

Go is an open source programming language that makes it easy to build simple, reliable, and efficient software.

Gopher image Gopher image by Renee French, licensed under Creative Commons 3.0 Attributions license.

Our canonical Git repository is located at https://go.googlesource.com/go. There is a mirror of the repository at https://github.com/golang/go.

Unless otherwise noted, the Go source files are distributed under the BSD-style license found in the LICENSE file.

Download and Install

Binary Distributions

Official binary distributions are available at https://golang.org/dl/.

After downloading a binary release, visit https://golang.org/doc/install for installation instructions.

Install From Source

If a binary distribution is not available for your combination of operating system and architecture, visit https://golang.org/doc/install/source for source installation instructions.

Contributing

Go is the work of thousands of contributors. We appreciate your help!

To contribute, please read the contribution guidelines at https://golang.org/doc/contribute.

Note that the Go project uses the issue tracker for bug reports and proposals only. See https://golang.org/wiki/Questions for a list of places to ask questions about the Go language.