github.com/bir3/gocompiler@v0.9.2202/src/cmd/compile/internal/noder/stmt.go (about) 1 // Copyright 2021 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 package noder 6 7 import ( 8 "github.com/bir3/gocompiler/src/cmd/compile/internal/ir" 9 "github.com/bir3/gocompiler/src/cmd/compile/internal/syntax" 10 ) 11 12 // TODO(mdempsky): Investigate replacing with switch statements or dense arrays. 13 14 var branchOps = [...]ir.Op{ 15 syntax.Break: ir.OBREAK, 16 syntax.Continue: ir.OCONTINUE, 17 syntax.Fallthrough: ir.OFALL, 18 syntax.Goto: ir.OGOTO, 19 } 20 21 var callOps = [...]ir.Op{ 22 syntax.Defer: ir.ODEFER, 23 syntax.Go: ir.OGO, 24 }