about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--edit/004-programming-environment.mu1
-rw-r--r--edit/005-sandbox.mu13
2 files changed, 13 insertions, 1 deletions
diff --git a/edit/004-programming-environment.mu b/edit/004-programming-environment.mu
index c825a503..95b7ca62 100644
--- a/edit/004-programming-environment.mu
+++ b/edit/004-programming-environment.mu
@@ -10,7 +10,6 @@ recipe! main [
   initial-sandbox:address:array:character <- new []
   hide-screen 0/screen
   env:address:programming-environment-data <- new-programming-environment 0/screen, initial-recipe, initial-sandbox
-  env <- restore-sandboxes env
   render-all 0/screen, env
   event-loop 0/screen, 0/console, env
   # never gets here
diff --git a/edit/005-sandbox.mu b/edit/005-sandbox.mu
index 5d2e575e..4aad213b 100644
--- a/edit/005-sandbox.mu
+++ b/edit/005-sandbox.mu
@@ -4,6 +4,19 @@
 # (non-editable) sandboxes below the editor, showing the result and a maybe
 # few other things.
 
+recipe! main [
+  local-scope
+  open-console
+  initial-recipe:address:array:character <- restore [recipes.mu]
+  initial-sandbox:address:array:character <- new []
+  hide-screen 0/screen
+  env:address:programming-environment-data <- new-programming-environment 0/screen, initial-recipe, initial-sandbox
+  env <- restore-sandboxes env
+  render-all 0/screen, env
+  event-loop 0/screen, 0/console, env
+  # never gets here
+]
+
 container programming-environment-data [
   sandbox:address:sandbox-data  # list of sandboxes, from top to bottom
 ]