mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
[dev.regabi] cmd/compile: move helpers into package base [generated]
[git-generate] cd src/cmd/compile/internal/gc rf ' # Move EnableTrace constant into base, with the other flags. mv enableTrace EnableTrace mv EnableTrace base.go # Move compilation checks to base. mv instrumenting Instrumenting mv ispkgin Compiling mv omit_pkgs NoInstrumentPkgs mv norace_inst_pkgs NoRacePkgs mv Instrumenting Compiling NoInstrumentPkgs NoRacePkgs base.go # Move AutogeneratedPos to package base, next to Pos. mv autogeneratedPos AutogeneratedPos mv AutogeneratedPos print.go mv timings Timer mv base.go print.go timings.go cmd/compile/internal/base ' cd ../base rf ' mv Instrumenting Flag.Cfg.Instrumenting ' Change-Id: I534437fa75857d31531fc499d833c9930c0a06d0 Reviewed-on: https://go-review.googlesource.com/c/go/+/279420 Trust: Russ Cox <rsc@golang.org> Run-TryBot: Russ Cox <rsc@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
This commit is contained in:
parent
440308ffd7
commit
ead4957892
17 changed files with 120 additions and 122 deletions
|
|
@ -460,7 +460,7 @@ func walkrange(nrange *ir.RangeStmt) ir.Node {
|
|||
//
|
||||
// where == for keys of map m is reflexive.
|
||||
func isMapClear(n *ir.RangeStmt) bool {
|
||||
if base.Flag.N != 0 || instrumenting {
|
||||
if base.Flag.N != 0 || base.Flag.Cfg.Instrumenting {
|
||||
return false
|
||||
}
|
||||
|
||||
|
|
@ -523,7 +523,7 @@ func mapClear(m ir.Node) ir.Node {
|
|||
//
|
||||
// Parameters are as in walkrange: "for v1, v2 = range a".
|
||||
func arrayClear(loop *ir.RangeStmt, v1, v2, a ir.Node) ir.Node {
|
||||
if base.Flag.N != 0 || instrumenting {
|
||||
if base.Flag.N != 0 || base.Flag.Cfg.Instrumenting {
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue