bolt/assert.go

13 lines
307 B
Go

package bolt
import "fmt"
// TODO(benbjohnson): Remove assertions before release.
// _assert will panic with a given formatted message if the given condition is false.
func _assert(condition bool, msg string, v ...interface{}) {
if !condition {
panic(fmt.Sprintf("assertion failed: "+msg, v...))
}
}