aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlukechampine <luke.champine@gmail.com>2016-03-29 23:49:50 -0400
committerlukechampine <luke.champine@gmail.com>2016-03-29 23:49:50 -0400
commitcb6cf9ef3c67a46477c7ab7a7fe3fb032bbe0840 (patch)
tree0d5fa725f7a802e0bc5eda92fa19ad85cbf2f7e9
parentreplace OrElse with Select (diff)
downloadstm-cb6cf9ef3c67a46477c7ab7a7fe3fb032bbe0840.tar.gz
stm-cb6cf9ef3c67a46477c7ab7a7fe3fb032bbe0840.tar.xz
rename Check -> Assert
-rw-r--r--stm.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/stm.go b/stm.go
index e3c965e..973734c 100644
--- a/stm.go
+++ b/stm.go
@@ -149,9 +149,9 @@ func (tx *Tx) Retry() {
panic(Retry)
}
-// Check is a helper function that retries a transaction if the condition is
+// Assert is a helper function that retries a transaction if the condition is
// not satisfied.
-func (tx *Tx) Check(p bool) {
+func (tx *Tx) Assert(p bool) {
if !p {
tx.Retry()
}