mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
[dev.typeparams] cmd/compile: add derived-type dictionaries to unified IR
This CL updates the unified IR export data serialization to explicitly and separately record the derived types used by a declaration. The readers currently just use this data to construct types/IR the same as before, but eventually we can use it for emitting GC-shape dictionaries. Change-Id: I7d67ad9b3f1fbe69664bf19e056bc94f73507220 Reviewed-on: https://go-review.googlesource.com/c/go/+/331829 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com> Trust: Cuong Manh Le <cuong.manhle.vn@gmail.com> Trust: Matthew Dempsky <mdempsky@google.com>
This commit is contained in:
parent
6a5f7e8498
commit
f503740ccf
6 changed files with 381 additions and 223 deletions
|
|
@ -122,7 +122,7 @@ func unified(noders []*noder) {
|
|||
|
||||
// Instantiated generic function: add to Decls for typechecking
|
||||
// and compilation.
|
||||
if len(pri.implicits) != 0 && fn.OClosure == nil {
|
||||
if pri.dict != nil && len(pri.dict.targs) != 0 && fn.OClosure == nil {
|
||||
target.Decls = append(target.Decls, fn)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue