github.com/hyperledger/burrow@v0.34.5-0.20220512172541-77f09336001d/util/debug.go (about) 1 package util 2 3 import "fmt" 4 5 // If we ever want to ship some specific debug we could make this a string var and set it through -ldflags "-X ..." 6 7 //const debug = true 8 const debug = false 9 10 // Using this in place of Printf statements makes it easier to find any errant debug statements and the switch means 11 // we can turn them off at minimal runtime cost. 12 func Debugf(format string, args ...interface{}) { 13 if debug { 14 fmt.Printf(format+"\n", args...) 15 } 16 }