• Robert Griesemer's avatar
    go/types: if base type for an alias is known, use it when needed · e7bce084
    Robert Griesemer authored
    Because methods are type-checked before the receiver base type
    is "complete" (i.e., they are checked as part of the receiver
    base type), situations occur where aliases of those base types
    are used (in those methods) but the alias types are not known
    yet (even though their base types are known).
    
    This fix is a temporary work-around that looks syntactically
    for the base types of alias types and uses those base types
    when we refer to an "incomplete" alias type. The work-around
    is completely localized and guarded with a flag so it can be
    disabled at short notice.
    
    The correct fix (slated for 1.12) is to decouple type-checking
    of methods from their receiver base types. See issue #26854.
    
    Fixes #26390.
    
    Change-Id: I66cc9d834b220c254ac00e671a137cf8a3da59c1
    Reviewed-on: https://go-review.googlesource.com/128435Reviewed-by: 's avatarIan Lance Taylor <iant@golang.org>
    Reviewed-by: 's avatarAlan Donovan <adonovan@google.com>
    e7bce084
Name
Last commit
Last update
.github Loading commit data...
api Loading commit data...
doc Loading commit data...
lib/time Loading commit data...
misc Loading commit data...
src Loading commit data...
test Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
AUTHORS Loading commit data...
CONTRIBUTING.md Loading commit data...
CONTRIBUTORS Loading commit data...
LICENSE Loading commit data...
PATENTS Loading commit data...
README.md Loading commit data...
favicon.ico Loading commit data...
robots.txt Loading commit data...