mirror of
https://git.numenor-labs.us/dsfx.git
synced 2025-04-29 16:20:34 +00:00
11 lines
212 B
Go
11 lines
212 B
Go
package assert
|
|
|
|
import "fmt"
|
|
|
|
// Assert panics if the given truth value is false, with the given message.
|
|
func Assert(truth bool, msg string) {
|
|
if !truth {
|
|
panic(fmt.Sprintf("Assertion Failed: %s", msg))
|
|
}
|
|
}
|