]> ocean-lang.org Git - ocean/blobdiff - csrc/oceani-tests.mdc
oceani: move ->prepare_type call (back) into val_alloc()
[ocean] / csrc / oceani-tests.mdc
index 90bfc19da11d84241256fdba41c6b06bd5376db9..e7e9f22486df6bdac410d996b2d7de05f7bd4e1b 100644 (file)
@@ -533,7 +533,7 @@ ad-hoc things array related.
 
                for i:=0; then i=i+1; while i<5:
                        j ::= i
-                       ra:[5]number
+                       ra:[j]number
                        ra[i-1] = i*i
                        ra[6] = 42 // mustn't crash
                        print '', bools[i], ra[j-1],
@@ -551,8 +551,9 @@ Time to test if structure declarations and accesses work correctly.
 
 ###### test: structs
 
+       const three ::= 3
        struct foo
-               size:[3]number
+               size:[three]number
                name:string
                active:Boolean