aboutsummaryrefslogtreecommitdiff
path: root/cmd/j1e/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/j1e/main.go')
-rw-r--r--cmd/j1e/main.go10
1 files changed, 4 insertions, 6 deletions
diff --git a/cmd/j1e/main.go b/cmd/j1e/main.go
index 8f31aeb..934d416 100644
--- a/cmd/j1e/main.go
+++ b/cmd/j1e/main.go
@@ -3,16 +3,14 @@ package main
//go:generate file2go -in ../../testdata/j1e.bin
import (
- "context"
-
"dim13.org/j1"
"dim13.org/j1/console"
)
func main() {
- vm := j1.New()
+ con := console.New()
+ defer con.Stop()
+ vm := j1.New(con)
vm.LoadBytes(J1eBin)
- ctx, cancel := context.WithCancel(context.Background())
- defer cancel()
- vm.Run(ctx, cancel, console.New(ctx))
+ vm.Run()
}