Add a test to make sure there's no invalid OCONVIFACEs when stenciling is done.
Use concrete types for the type of DOTTYPE and DOTTYPE2.
MarkTypeUsedInInterface - should we allow types with shape types
underneath? I think the itab CL will help with this (at least, for
a remaining cons.go issue).
Change-Id: I2c96d74e8daaca26cadc84ea94abb9a27c0bb240
Reviewed-on: https://go-review.googlesource.com/c/go/+/337069
Trust: Keith Randall <khr@golang.org>
Trust: Dan Scales <danscales@google.com>
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dan Scales <danscales@google.com>
Even if we can otherwise transform a return statement because of type
params, add CONVIFACE nodes where appropriate.
Change-Id: Ia2216d5f6805926075ba6802a4385eee1d63e37e
Reviewed-on: https://go-review.googlesource.com/c/go/+/337049
Trust: Dan Scales <danscales@google.com>
Run-TryBot: Dan Scales <danscales@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
This fix the case where a type param or derived type is converted to a
non-empty interface. Previously, we were converting to an empty
interface and then using DOTTYPE to convert to the correct non-empty
interface. In that case, we can get the needed itab directly from the
dictionary. This is needed for correctness from shapes, if the
destination interface is parameterized, else we will incorrectly convert
to the shape version of the interface.
Creating/writing an itab can involve generating wrappers for a bunch of
methods, which may use dictionaries. So, all the
dictionaries/instantiations are being generated on the fly and have
recursive relationships, it is simplest to finish creating/writing the
itabs at the end of the stenciling phase. So, we create a list of the
dictionaries which need to be completed by writing out their itab
entries.
The existing tests ordered.go, ifaceconv.go, and issue44688.go make use
of this optimization.
Got itab conversions for bound calls working, except for 13.go.
Also, want to get rid of the concretify, but I think we need more info
on the Bound from types2.
Change-Id: If552958a7b8a435500d6cc42c401572c367b30d1
Reviewed-on: https://go-review.googlesource.com/c/go/+/336993
Trust: Dan Scales <danscales@google.com>
Run-TryBot: Dan Scales <danscales@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
Changes to add CONVIFACE nodes where possible in noder2, even when the
args are typeparams. The transformation to insert a CONVIFACE node can
usually happen when there an obvious assignment/conversion to an
interface type from a non-interface type. So, we now do this
tranformation for:
- direct conversions to an interface type
- function arguments that are implicitly converted to an interface
based on the parameter types.
- EQ/NE comparison of an interface and a non-interface
With this change, we can remove some special case checks for CONVIFACE
nodes after transformation in node(), and instead just have the one
check in the CONVIFACE check.
Change-Id: I7cf2ef920aebf9e5553210aeaf19f344e128ca62
Reviewed-on: https://go-review.googlesource.com/c/go/+/336992
Trust: Dan Scales <danscales@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
Previously it was just printing <S>. Now it prints things like int32|~int64.
Change-Id: I960b011ce8ed360020a49ae7809d85d1d1fdbfb2
Reviewed-on: https://go-review.googlesource.com/c/go/+/336692
Trust: Keith Randall <khr@golang.org>
Trust: Dan Scales <danscales@google.com>
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dan Scales <danscales@google.com>
I don't know what this test is doing, but it very frequently flakes
for me while testing mundane compiler CLs. According to the issue log,
it's been flaky for ~3 years.
Updates #37331.
Change-Id: I81c43ad646ee12d4c6561290a54e4bf637695bc6
Reviewed-on: https://go-review.googlesource.com/c/go/+/336349
Trust: Matthew Dempsky <mdempsky@google.com>
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
This avoids a race when a new timerModifiedEarlier timer is created by
a different goroutine.
Fixes#47329
Change-Id: I6f6c87b4a9b5491b201c725c10bc98e23e0ed9d1
Reviewed-on: https://go-review.googlesource.com/c/go/+/336432
Trust: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
Make sure the instantiating types are the type parameters of the containing
function (or types derived from those).
The one exception is the argument of a OFUNCINST, whose type
parameters are those of the declaration site of the function or method
being instantiated. We skip those types.
Change-Id: I4b3ff22eb8a81a76476930cf8ed2a7dd6489d8b8
Reviewed-on: https://go-review.googlesource.com/c/go/+/336352
Trust: Keith Randall <khr@golang.org>
Trust: Dan Scales <danscales@google.com>
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dan Scales <danscales@google.com>
We now understand the root cause of #47227, it will be fixed in #47317.
Change-Id: Ifcd44f887a0bd3195818df33e409bd3e818e0b27
Reviewed-on: https://go-review.googlesource.com/c/go/+/336610
Trust: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Run-TryBot: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Changed the implementation such that the result is a variable rather than
a constant if the argument type (or the struct in case of unsafe.Offsetof)
has a size that depends on type parameters.
Minor unrelated adjustments.
For #40301.
Change-Id: I1e988f1479b95648ad95a455c764ead829d75749
Reviewed-on: https://go-review.googlesource.com/c/go/+/335413
Trust: Robert Griesemer <gri@golang.org>
Run-TryBot: Robert Griesemer <gri@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Findley <rfindley@google.com>
CL 330670 simplified usemethod, but dropped the previous condition to
ensure the function have 1 or 2 result. This CL restore that condition,
and also add a test for it.
Change-Id: I434e3736785b43ceea0b386d8d9d01ad78a4ccd2
Reviewed-on: https://go-review.googlesource.com/c/go/+/336609
Trust: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Run-TryBot: Cuong Manh Le <cuong.manhle.vn@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Even internally to the type checker, we should use the TParams and
RParams methods instead of accessing fields directly, as TParams may be
lazily expanded, and in the future we may want to pack receiver and
function type parameters into a single field on Signature.
We should also not differentiate a nil *TParamList from an empty
*TParamList.
Change-Id: I85c616e6c708a89b6a5eb1e69fe0b014276eda90
Reviewed-on: https://go-review.googlesource.com/c/go/+/336251
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
Reviewed-by: Robert Griesemer <gri@golang.org>
It is invalid to use a type parameter for more than one type, so we can
avoid passing the type parameter index to NewTypeParam and just set it
when type parameters are bound to a type via SetTParams or during type
checking.
In order to enforce the correctness of this change, introduce a
TypeParams type to represent a list of type parameters that have been
associated with a type. For now, expose this new type as the API for
type parameters, but this is of course not necessarily a final API.
Allowing *TypeParams to be nil also decreases the size of Named and
Signature, which is good as most instances of these types will not be
parameterized.
Change-Id: Ia1e39ba51edb05bb535eb5f41c34e9dd02d39c38
Reviewed-on: https://go-review.googlesource.com/c/go/+/336249
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This CL makes two related changes:
1. It uses 'go env -json' to query the environment configuration,
rather than attempting to manually reconstruct the values that cmd/go
is going to use.
2. It changes the -goexperiment flag to *extend* any ambient
GOEXPERIMENT configuration. Notably, this means that '-goexperiment
fieldtrack' now tests fieldtracking in conjunction with any other
experiments (e.g., unified IR). Tests that want to test an exact
GOEXPERIMENT config should use '-goexperiment none,foo' instead.
Change-Id: I96a97198209e540e934fe7035110c3ae3a8f0e6a
Reviewed-on: https://go-review.googlesource.com/c/go/+/332610
Trust: Matthew Dempsky <mdempsky@google.com>
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
It was not safe to do mcache profiling updates outside the critical
section, but we got lucky because the runtime was not preemptible.
Adding chunked memory clearing (CL 270943) created preemption
opportunities, which led to corruption of runtime data structures.
Fixes#47304.
Fixes#47302.
Change-Id: I461615470d62328a83ccbac537fbdc6dcde81c85
Reviewed-on: https://go-review.googlesource.com/c/go/+/336449
Trust: David Chase <drchase@google.com>
Run-TryBot: David Chase <drchase@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Austin Clements <austin@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
The refactoring of CL 335929 to merge the instance and Named types
resulted in type instances only being evaluated once. As a side effect,
we only verified constraints once per unique instantiation expression.
This can be confusing if type instantations are occurring far apart in
the code. Resolve this by lifting up the verification logic into
Instantiate and InstantiateLazy.
Change-Id: Icd5a482d097d983073955c62931441edfd92f5c2
Reviewed-on: https://go-review.googlesource.com/c/go/+/335978
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
Storing temporary syntactic information using an *instance type forces
us to be careful not to leak references to *instance in the checker
output. This is complex and error prone, as types are written in many
places during type checking.
Instead, temporarily pin the necessary syntactic information directly to
the Named type during the type checking pass. This allows us to avoid
having to sanitize references.
This includes a couple of small, unrelated changes that were made in the
process of debugging:
- eliminate the expandf indirection: it is no longer necessary
- include type parameters when printing objects
For #46151
Change-Id: I767e35b289f2fea512a168997af0f861cd242175
Reviewed-on: https://go-review.googlesource.com/c/go/+/335929
Trust: Robert Findley <rfindley@google.com>
Trust: Robert Griesemer <gri@golang.org>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
Removed a case in transformCall() where we were setting a type on n,
which isn't needed, since noder2 already set the type of n. More
importantly, we are losing information, since the type of the results
may be a shape type, but the actual type of call is the known type
from types2, which may be a concrete type (in this case Zero[MyInt]).
That concrete type will then be used correctly if the concrete result is
converted to an interface.
If we are inlining the call to Zero[MyInt], we need to add an implicit
CONVNOP operation, since we are going to use the result variable
directly, which has a shape type. So, add an implicit CONVNOP to
remember that the known type is the concrete type.
Also cleaned up 14.go a bit, so it is more understandable. Renamed type
T to AnyInt, since T is used elsewhere as a type parameter. Reformatted
Zero function and added a comment.
Change-Id: Id917a2e054e0bbae9bd302232853fa8741d49b64
Reviewed-on: https://go-review.googlesource.com/c/go/+/336430
Trust: Dan Scales <danscales@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
METHVALUE in a generic function (that is not called) was not causing
buildClosure() to be called and therefore not using dictionaries. Also,
had to add an extra check to make sure that if we have a FUNCINST
node above a METHVALUE, we only call buildClosure once.
Change-Id: I49756152fc343e5ac1c449e697960fc2a0f482ae
Reviewed-on: https://go-review.googlesource.com/c/go/+/336429
Reviewed-by: Keith Randall <khr@golang.org>
Trust: Dan Scales <danscales@google.com>
Run-TryBot: Dan Scales <danscales@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
types2 doesn't actually give us the type of an instantiated
function/method after the type args have been applied. So, do a
substitution at the point that we create the OFUNCINST nodes.
We also needed to add in translation of the typeparams of a function
signature in the type substituter. If the type params of the function
become all concrete after the substitution, then we just drop them,
since the whole signature must now be concrete.
Change-Id: I6116d2aa248be6924ec9e6d8516678db45aa65c4
Reviewed-on: https://go-review.googlesource.com/c/go/+/336370
Run-TryBot: Dan Scales <danscales@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Trust: Dan Scales <danscales@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
types2 will have already proved the expression's type is compatible, so
just assign the one const to have the same type as the operand.
Fixes#47258.
Change-Id: If0844e6bf6d0a5e6b11453b87df71353863ccc5d
Reviewed-on: https://go-review.googlesource.com/c/go/+/336009
Run-TryBot: Dan Scales <danscales@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
Trust: Dan Scales <danscales@google.com>
The builtins.go test is derived from
cmd/compile/internal/types2/testdata/check/builtins.go2, after removing
the error cases. Added a few extra tests for len/cap/append.
Fixed one bug, which is that DELETE operations can't be transformed if
their argument is a typeparam. Also, the tranform of LEN/CAP calls does
not need to be delayed. Removed out-date references to the old
typechecker in the comments.
Change-Id: If7a21506a7ff63ff7c8e87ccd614ef4ff3a0d3c8
Reviewed-on: https://go-review.googlesource.com/c/go/+/336010
Run-TryBot: Dan Scales <danscales@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
Trust: Dan Scales <danscales@google.com>
Remaining stuff from Dan's CL 335412 to get tests passing.
- Removed PTRLIT case in node() that was added with the gcshape change.
I don't think it is needed anymore.
- Modified (*itab).init() to add an irrelevant pointer (the itab
itself) for the '==' entry of interfaces with 'comparable'. That
entry is not used, so we just want to avoid the error that the given
type doesn't actually have an '==' method.
Change-Id: I9b2d4c8342c0b2048d76e003d95023f4ccd559f5
Reviewed-on: https://go-review.googlesource.com/c/go/+/336149
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dan Scales <danscales@google.com>
Trust: Dan Scales <danscales@google.com>
Trust: Keith Randall <khr@golang.org>
FUNCINST nodes aren't instantiated correctly. Skip those types when
adding to the set of types considered for the dictionary. Those types
include those which are uninstantiated(have tparams), and those with
type parameters that aren't a parameter of the containing function
(they are the type parameter of the function being called).
Allow func types to be put in the dictionary.
Change-Id: I26bab85d3eebc2f54d02b4bba5e31407faf7c5b2
Reviewed-on: https://go-review.googlesource.com/c/go/+/336129
Reviewed-by: Dan Scales <danscales@google.com>
Trust: Dan Scales <danscales@google.com>
Trust: Keith Randall <khr@golang.org>
Calling MarkTypeUsedInInterface before inlining is problematic (when
using the containing function as the reference source), because we end
up attaching a relocation to the original function, which is then
deadcode removed because all instances of it were inlined. (All other
current uses of MarkTypeUsedInInterface happen after inlining, so they
don't have this problem.)
Instead, attach the relocation to the dictionary in which the type
appears. This should always work, because if the dictionary is ever
deadcode eliminated, then the type can never be put in an interface,
which means we indeed don't need its methods.
This CL is a bit overkill, as not *all* types in the dictionary need
this mark, but it is sufficient for now.
Change-Id: I2d39456691f1c3df8efe3bddc3b9017e0ef37a7f
Reviewed-on: https://go-review.googlesource.com/c/go/+/336012
Trust: Keith Randall <khr@golang.org>
Trust: Dan Scales <danscales@google.com>
Reviewed-by: Dan Scales <danscales@google.com>
We'll have to revisit eventually, but disabling for now.
Change-Id: Ic34cfe451939d61884079bb125b9290db1e05e47
Reviewed-on: https://go-review.googlesource.com/c/go/+/335829
Run-TryBot: Keith Randall <khr@golang.org>
Trust: Keith Randall <khr@golang.org>
Trust: Dan Scales <danscales@google.com>
Reviewed-by: Dan Scales <danscales@google.com>
Still 1-1 with real types, but now with their own names!
Shape types are implicitly convertible to (and convertible from)
the types they represent.
Change-Id: I0133a8d8fbeb369380574b075a32b3c987e314d5
Reviewed-on: https://go-review.googlesource.com/c/go/+/335170
Run-TryBot: Keith Randall <khr@golang.org>
Trust: Keith Randall <khr@golang.org>
Trust: Dan Scales <danscales@google.com>
Reviewed-by: Dan Scales <danscales@google.com>
Change-Id: I5a2f7203f83be02b03aa7be5fe386e485bf68ca3
Reviewed-on: https://go-review.googlesource.com/c/go/+/336189
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Trust: Robert Findley <rfindley@google.com>
For #395
For #46746
Change-Id: I4bfc094cf1cecd27ce48e31f92384cf470f371a6
Reviewed-on: https://go-review.googlesource.com/c/go/+/334669
Trust: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
Reviewed-by: Joe Tsai <thebrokentoaster@gmail.com>
This CL makes two changes:
1. It moves object symbols and code tags into a new "relocName"
relocation, which should eventually allow getting rid of objStub.
2. It moves the type parameter data into the relocObjDict relocation,
so everything related to writing out dictionaries is contained there.
Change-Id: If0f7ff7d9384e8664957c3180bf6f20e97bcff6e
Reviewed-on: https://go-review.googlesource.com/c/go/+/336051
Trust: Matthew Dempsky <mdempsky@google.com>
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com>
CL 330330 moved logic for wrapping go/defer from order to esacpe
analysis. It introduced a bug involves go/defer statement with ABI0
functions.
Consider this following code:
package p
//go:cgo_unsafe_args
func g(*int) (r1 struct{}) {
return
}
func f() {
defer g(new(int))
}
g is a cgo-like generated function with ABI0. While compiling g, we set
the offset per ABI0.
The function f is rewritten into:
func f() {
_0, _1 := g, new(int)
defer func() { _0(_1) }()
}
The temporary _0 hold function value with the same type as g, but with
class PAUTO. Thus ssagen/ssa.go:state.call cannot handle it and use
ABIDefault to set the offset, causes the offset of r1 changed
CL 330332 intended to optimize code generated for wrapping function, by
rewriting the wrapper function into:
func f() {
_0 := new(int)
defer func() { g(_0) }()
}
So it fixed the bug unintentionally.
This CL add regression test for this bug, and also add a comment to
explain while not wrapping declared function is important.
Updates #47227
Change-Id: I75c83d1d9cc7fd4699e6b218a295d0c0a10ef471
Reviewed-on: https://go-review.googlesource.com/c/go/+/334882
Trust: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Run-TryBot: Cuong Manh Le <cuong.manhle.vn@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
We have almost 200 uses of the "assert" helper functions in noder and
typecheck. Clearly the tiny bit of extra convenience of writing a
one-line assertion rather than an if+panic is helpful, so we might as
well add functions for this to base itself so that it's easier to
write more informative error messages.
Change-Id: I06e2db2f0455af063937b25a53ca42f9413cf496
Reviewed-on: https://go-review.googlesource.com/c/go/+/336050
Trust: Matthew Dempsky <mdempsky@google.com>
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
No test because a real test requires installing two different compilers.
For #40042
For #47251
Change-Id: Iefddd67830d242a119378b7ce20be481904806e4
Reviewed-on: https://go-review.googlesource.com/c/go/+/335409
Trust: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Jay Conrod <jayconrod@google.com>
This test has been failing since the builder was updated to
NetBSD 9. While the issue is under investigation, skip the test
so that we do not miss other breakage.
Update issue #45026
Change-Id: Id083901c517f3f88e6b4bc2b51208f65170d47a6
Reviewed-on: https://go-review.googlesource.com/c/go/+/335909
Reviewed-by: Than McIntosh <thanm@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
Trust: Benny Siegert <bsiegert@gmail.com>
Run-TryBot: Benny Siegert <bsiegert@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
For traceback argument printing, we want to print at most 10
words, then print "..." if there are still more args and/or
fields. The current code has off-by-one error that for 11
non-aggregate typed args, it prints the first 10 but without the
"...". Also, for aggregate-typed args, in some cases it may print
an extra "..." when there is actually no more fields.
The problem for this is that visitType return false (meaning not
to continue visiting) if it reaches the limit anywhere during the
recursive visit. It doesn't distinguish whether it has printed
anything for the current arg. If it reaches the limit before it
prints anything, it means that we're visiting the extra arg/field,
so the caller should print "..." and stop. If it prints
something then reaches the limit, however, the caller should keep
going, and only print "..." at the next iteration when there is
actually an extra arg/field. This CL does so.
Fixes#47159.
Change-Id: I93fc25b73ada2b5a98df780c45e5b0c9565dc2fc
Reviewed-on: https://go-review.googlesource.com/c/go/+/334710
Trust: Cherry Mui <cherryyz@google.com>
Run-TryBot: Cherry Mui <cherryyz@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
We should preserve type parameter indices when transforming them using
applyTypeFunc.
Change-Id: Ib75f5cf1a146bd7e6850368fa954c1affcba3ad1
Reviewed-on: https://go-review.googlesource.com/c/go/+/327269
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
Reviewed-by: Robert Griesemer <gri@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Change-Id: I523d5fd810b82154a204670d46fc250a0fc66791
Reviewed-on: https://go-review.googlesource.com/c/go/+/333849
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
This is a port of CL 334911 to go/types.
Change-Id: I2cafdc76cb4d06ba82188c530f35952c1f77d292
Reviewed-on: https://go-review.googlesource.com/c/go/+/335569
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This is a port of CL 334151 to go/types.
Fixes#47127
Change-Id: I57d69c498d2649a9e1657559e4c0271333096c88
Reviewed-on: https://go-review.googlesource.com/c/go/+/335082
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This is a port of CL 333890 to go/types.
Change-Id: I8ee20f405dad98083bb5e91636044d132a95d909
Reviewed-on: https://go-review.googlesource.com/c/go/+/335081
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This is a port of CL 333889 to go/types.
Change-Id: I66cefb81a33f4677efc18c1ca923ded374a87f12
Reviewed-on: https://go-review.googlesource.com/c/go/+/335080
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This is a port of CL 333770 to go/types, adjusted for the error
reporting API and to not support compiler error messages. An error
message changed (to 'invalid receiver type' from just 'invalid
receiver'), so a test had to be adjusted.
Change-Id: I166e8831d8c9f98ebfb0270fe5221586fc112825
Reviewed-on: https://go-review.googlesource.com/c/go/+/335079
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This is a port of CL 333729 to go/types.
Change-Id: I8682f549a7a15124b1b338f8c73e83a57d138368
Reviewed-on: https://go-review.googlesource.com/c/go/+/335078
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This is a port of CL 333713 to go/types.
Change-Id: I517f52592f65cc76e11a12d9148b20c12d9e3e81
Reviewed-on: https://go-review.googlesource.com/c/go/+/335077
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
This is a port of CL 333712 to go/types, adjusted for the different
error reporting API and to position errors on the arrows.
Fixes#43671
Change-Id: I7d2de249e86d272c89a046f60e632e75848ff865
Reviewed-on: https://go-review.googlesource.com/c/go/+/335076
Trust: Robert Findley <rfindley@google.com>
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>