From 64e6c75924a57306d8009cef4802b0b9ca4b7891 Mon Sep 17 00:00:00 2001 From: Dan Scales Date: Mon, 28 Jun 2021 11:50:26 -0700 Subject: [dev.typeparams] cmd/compile: port fix for issue46725 to transform.go Allow fix for issue46725 to work for -G=3 mode. Change-Id: Id522fbc2278cf878cb3f95b3205a2122c164ae29 Reviewed-on: https://go-review.googlesource.com/c/go/+/331470 Trust: Dan Scales Run-TryBot: Dan Scales TryBot-Result: Go Bot Reviewed-by: Matthew Dempsky --- src/cmd/compile/internal/typecheck/typecheck.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/cmd/compile/internal/typecheck/typecheck.go') diff --git a/src/cmd/compile/internal/typecheck/typecheck.go b/src/cmd/compile/internal/typecheck/typecheck.go index f7de43c79f..232c0e66ef 100644 --- a/src/cmd/compile/internal/typecheck/typecheck.go +++ b/src/cmd/compile/internal/typecheck/typecheck.go @@ -962,12 +962,12 @@ func typecheckargs(n ir.InitNode) { } // Rewrite f(g()) into t1, t2, ... = g(); f(t1, t2, ...). - rewriteMultiValueCall(n, list[0]) + RewriteMultiValueCall(n, list[0]) } -// rewriteMultiValueCall rewrites multi-valued f() to use temporaries, +// RewriteMultiValueCall rewrites multi-valued f() to use temporaries, // so the backend wouldn't need to worry about tuple-valued expressions. -func rewriteMultiValueCall(n ir.InitNode, call ir.Node) { +func RewriteMultiValueCall(n ir.InitNode, call ir.Node) { // If we're outside of function context, then this call will // be executed during the generated init function. However, // init.go hasn't yet created it. Instead, associate the -- cgit v1.2.3-54-g00ecf