]> Cypherpunks repositories - gostls13.git/commit
[dev.regabi] cmd/compile: cleanup export code further
authorMatthew Dempsky <mdempsky@google.com>
Wed, 23 Dec 2020 11:33:03 +0000 (03:33 -0800)
committerMatthew Dempsky <mdempsky@google.com>
Wed, 23 Dec 2020 12:01:07 +0000 (12:01 +0000)
commit53f082b0ee81f14d1b1a1c997e2f8e9164af37bc
tree5c83cb0ef494caf07d97e57d35f9a77d5a5d9491
parent31267f82e16249a1d9065099c615a936dc32688b
[dev.regabi] cmd/compile: cleanup export code further

This CL rips off a number of toolstash bandages:

- Fixes position information for string concatenation.

- Adds position information for struct literal fields.

- Removes unnecessary exprsOrNil calls or replaces them with plain
  expr calls when possible.

- Reorders conversion expressions to put type first, which matches
  source order and also the order the importer needs for calling the
  ConvExpr constructor.

Change-Id: I44cdc6035540d9ecefd9c1bcd92b8711d6ed813c
Reviewed-on: https://go-review.googlesource.com/c/go/+/279957
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>
src/cmd/compile/internal/typecheck/iexport.go
src/cmd/compile/internal/typecheck/iimport.go