Closed
Description
This issue tracks the adoption in gopls of go1.22's new types.Alias type. We will need to audit every place that type-switches or type-asserts a types.Type
to ensure that it works correctly with the new type. Initially the type checker will not produce instances of these types unless GODEBUG=gotypesalias=1 is set.
Things to resolve:
- go/types: Alias.String should not mention the aliased type #64584 (done)
- waiting for cmd/compile support for writing aliases (done)
- gcimporter support for reading and writing aliases (done)
- sprinkling Unalias in a great many places (done)
- supporting parameterized aliases (for now my goal is just to support with the new representation of simple aliases).
- adding tests to each x/tools package with aliases, both ordinary and parameterized.
- working with @dominikh to upgrade staticcheck in a similar way. (audit staticcheck for GODEBUG=gotypesalias=1 support dominikh/go-tools#1523)
- working with the vulncheck folks to do the same (done)
Related: