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.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/cmd/j1e/main.go b/cmd/j1e/main.go
index 057e106..8f31aeb 100644
--- a/cmd/j1e/main.go
+++ b/cmd/j1e/main.go
@@ -6,10 +6,13 @@ import (
"context"
"dim13.org/j1"
+ "dim13.org/j1/console"
)
func main() {
vm := j1.New()
vm.LoadBytes(J1eBin)
- vm.Run(context.Background())
+ ctx, cancel := context.WithCancel(context.Background())
+ defer cancel()
+ vm.Run(ctx, cancel, console.New(ctx))
}