about summary refs log tree commit diff stats
path: root/032array.cc
diff options
context:
space:
mode:
Diffstat (limited to '032array.cc')
-rw-r--r--032array.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/032array.cc b/032array.cc
index 085e2b52..2bdafbbf 100644
--- a/032array.cc
+++ b/032array.cc
@@ -254,6 +254,18 @@ recipe main [
 ]
 +error: main: 'index' on *8:address:array:point can't be saved in 9:number; type should be point
 
+//: we might want to call 'index' without saving the results, say in a sandbox
+
+:(scenario index_without_product)
+recipe main [
+  1:array:number:3 <- create-array
+  2:number <- copy 14
+  3:number <- copy 15
+  4:number <- copy 16
+  index 1:array:number:3, 0
+]
+# just don't die
+
 //:: To write to elements of containers, you need their address.
 
 :(scenario index_address)
c@akkartik.com> 2022-05-17 22:22:45 -0700 committer Kartik K. Agaram <vc@akkartik.com> 2022-05-17 22:22:45 -0700 bugfix: duplicate character on enter' href='/akkartik/text.love/commit/manual_tests?id=dcfa2d04cace094775ba4fd468a75ed2831ebcc6'>dcfa2d0 ^
7e6705a ^







c28f6ba ^
ce94f8b ^
7e6705a ^
c28f6ba ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28