aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Joiner <anacrolix@gmail.com>2019-10-23 12:39:32 +1100
committerMatt Joiner <anacrolix@gmail.com>2019-10-23 12:39:32 +1100
commitd23cfa4d7445a8834bdaeed8ec6e1ea4c0d5fb75 (patch)
tree0a53471c2bb5ae8e7a040e4d79eb152bab184ca8
parentMerge pull request #2 from anacrolix/go.mod (diff)
downloadstm-d23cfa4d7445a8834bdaeed8ec6e1ea4c0d5fb75.tar.gz
stm-d23cfa4d7445a8834bdaeed8ec6e1ea4c0d5fb75.tar.xz
Make the santa example a cmd
-rw-r--r--cmd/santa-example/main.go (renamed from example_santa_test.go)4
1 files changed, 2 insertions, 2 deletions
diff --git a/example_santa_test.go b/cmd/santa-example/main.go
index 93de67f..29119cc 100644
--- a/example_santa_test.go
+++ b/cmd/santa-example/main.go
@@ -27,7 +27,7 @@
// and then delay for a random interval before trying to join a group again.
//
// See the paper for more details regarding the solution's implementation.
-package stm_test
+package main
import (
"fmt"
@@ -160,7 +160,7 @@ func spawnSanta(elves, reindeer *group) {
}
}
-func Example() {
+func main() {
elfGroup := newGroup(3)
for i := 0; i < 10; i++ {
go spawnElf(elfGroup, i)