aboutsummaryrefslogtreecommitdiff
path: root/cmd/santa-example/main.go
diff options
context:
space:
mode:
authorChris Wendt <chrismwendt@gmail.com>2022-06-08 03:16:02 -0600
committerChris Wendt <chrismwendt@gmail.com>2022-06-08 03:16:02 -0600
commit2ef3a53065a49ba3238203484588f1f72ccf25fd (patch)
tree2f59b6ef96aee1ec7ffd26c2793dc61ddb1142cb /cmd/santa-example/main.go
parentupdate README (diff)
downloadstm-2ef3a53065a49ba3238203484588f1f72ccf25fd.tar.gz
stm-2ef3a53065a49ba3238203484588f1f72ccf25fd.tar.xz
remove unnecessary type parameters
Diffstat (limited to 'cmd/santa-example/main.go')
-rw-r--r--cmd/santa-example/main.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/cmd/santa-example/main.go b/cmd/santa-example/main.go
index 1a93ae4..dcc8067 100644
--- a/cmd/santa-example/main.go
+++ b/cmd/santa-example/main.go
@@ -64,7 +64,7 @@ func (g gate) operate() {
func newGate(capacity int) gate {
return gate{
capacity: capacity,
- remaining: stm.NewVar[int](0), // gate starts out closed
+ remaining: stm.NewVar(0), // gate starts out closed
}
}
@@ -77,9 +77,9 @@ type group struct {
func newGroup(capacity int) *group {
return &group{
capacity: capacity,
- remaining: stm.NewVar[int](capacity), // group starts out with full capacity
- gate1: stm.NewVar[gate](newGate(capacity)),
- gate2: stm.NewVar[gate](newGate(capacity)),
+ remaining: stm.NewVar(capacity), // group starts out with full capacity
+ gate1: stm.NewVar(newGate(capacity)),
+ gate2: stm.NewVar(newGate(capacity)),
}
}