-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
go/internal/gcimporter: support unique naming for blank type parameters
As described in golang/go#50481, in the existing export data schema blank type parameters do not have unique names, and therefore types with multiple blank (receiver) type parameters cannot be correctly imported. This CL implements the fix proposed in that issue, using the schema <prefix>.$<index> as the exported name of a blank type parameter, where <prefix> is the qualifying prefix and <index> is the index of the type parameter in its type parameter list. The importer is backwards compatible with the old schema: it will continue to import <prefix>._ as long as there are not multiple blank type parameters. I considered not making the exporter change simultaneously with the importer change, so that we interleave the corresponding changes in the standard library. However, that made it harder to test the importer, and updating both seems unlikely to cause problems. For golang/go#50481 Change-Id: Id24428c6ea2b256312156894f9f76fa8e9ee38d4 Reviewed-on: https://go-review.googlesource.com/c/tools/+/379855 Trust: Robert Findley <[email protected]> Run-TryBot: Robert Findley <[email protected]> Trust: Dan Scales <[email protected]> Reviewed-by: Dan Scales <[email protected]> Reviewed-by: Robert Griesemer <[email protected]> gopls-CI: kokoro <[email protected]> TryBot-Result: Gopher Robot <[email protected]>
- Loading branch information
Showing
3 changed files
with
74 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters