summaryrefslogtreecommitdiff
path: root/tests/lexers/extempore/example.txt
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lexers/extempore/example.txt')
-rw-r--r--tests/lexers/extempore/example.txt8479
1 files changed, 8479 insertions, 0 deletions
diff --git a/tests/lexers/extempore/example.txt b/tests/lexers/extempore/example.txt
new file mode 100644
index 00000000..f7b156aa
--- /dev/null
+++ b/tests/lexers/extempore/example.txt
@@ -0,0 +1,8479 @@
+---input---
+;;; example.xtm -- Extempore code examples
+
+;; Author: Ben Swift, Andrew Sorensen
+;; Keywords: extempore
+
+;;; Commentary:
+
+
+
+;;; Code:
+
+;; bit twiddling
+
+(xtmtest '(bind-func test_bit_twiddle_1
+ (lambda ()
+ (bitwise-and 65535 255 15 1)))
+
+ (test_bit_twiddle_1) 1)
+
+(xtmtest '(bind-func test_bit_twiddle_2
+ (lambda ()
+ (bitwise-not -1)))
+
+ (test_bit_twiddle_2) 0)
+
+(xtmtest '(bind-func test_bit_twiddle_3
+ (lambda ()
+ (bitwise-not 0)))
+
+ (test_bit_twiddle_3) -1)
+
+(xtmtest '(bind-func test_bit_twiddle_4
+ (lambda ()
+ (bitwise-shift-right 65535 8)
+ (bitwise-shift-right 65535 4 4)))
+
+ (test_bit_twiddle_4) 255)
+
+(xtmtest '(bind-func test_bit_twiddle_5
+ (lambda ()
+ (bitwise-shift-left (bitwise-shift-right 65535 8) 4 4)))
+
+ (test_bit_twiddle_5) 65280)
+
+(xtmtest '(bind-func test_bit_twiddle_6
+ (lambda ()
+ (bitwise-and (bitwise-or (bitwise-eor 21844 65534) (bitwise-eor 43690 65534)) 1)))
+
+ (test_bit_twiddle_6) 0)
+
+;; integer literals default to 64 bit integers
+(xtmtest '(bind-func int-literal-test
+ (lambda (a)
+ (* a 5)))
+
+ (int-literal-test 6) 30)
+
+;; float literals default to doubles
+(xtmtest '(bind-func float-literal-test
+ (lambda (a)
+ (* a 5.0)))
+
+ (float-literal-test 6.0) 30.0)
+
+;; you are free to recompile an existing closure
+(xtmtest '(bind-func int-literal-test
+ (lambda (a)
+ (/ a 5)))
+
+ (int-literal-test 30))
+
+(xtmtest '(bind-func closure-test1
+ (let ((power 0))
+ (lambda (x)
+ (set! power (+ power 1)) ;; set! for closure mutation as per scheme
+ (* x power))))
+
+ (closure-test1 2))
+
+(xtmtest '(bind-func closure-returns-closure-test
+ (lambda ()
+ (lambda (x)
+ (* x 3))))
+
+ (closure-returns-closure-test))
+
+(xtmtest '(bind-func incrementer-test1
+ (lambda (i:i64)
+ (lambda (incr)
+ (set! i (+ i incr))
+ i)))
+
+ (incrementer-test1 0))
+
+(define myf (incrementer-test1 0))
+
+;; so we need to type f properly
+(xtmtest '(bind-func incrementer-test2
+ (lambda (f:[i64,i64]* x)
+ (f x)))
+ (incrementer-test2 myf 1) 1)
+
+;; and we can call my-in-maker-wrapper
+;; to appy myf
+(xtmtest-result (incrementer-test2 myf 1) 2)
+(xtmtest-result (incrementer-test2 myf 1) 3)
+(xtmtest-result (incrementer-test2 myf 1) 4)
+
+;; of course the wrapper is only required if you
+;; need interaction with the scheme world.
+;; otherwise you just call my-inc-maker directly
+
+;; this avoids the wrapper completely
+(xtmtest '(bind-func incrementer-test3
+ (let ((f (incrementer-test1 0)))
+ (lambda ()
+ (f 1))))
+
+ (incrementer-test3) 1)
+
+(xtmtest-result (incrementer-test3) 2)
+(xtmtest-result (incrementer-test3) 3)
+
+;; hopefully you're getting the idea.
+;; note that once we've compiled something
+;; we can then use it any of our new
+;; function definitions.
+
+;; do a little 16bit test
+(xtmtest '(bind-func bitsize-sixteen
+ (lambda (a:i16)
+ (dtoi16 (* (i16tod a) 5.0))))
+
+ (bitsize-sixteen 5) 25)
+
+;; while loop test
+
+(xtmtest '(bind-func test_while_loop_1
+ (lambda ()
+ (let ((count 0))
+ (while (< count 5)
+ (printf "count = %lld\n" count)
+ (set! count (+ count 1)))
+ count)))
+
+ (test_while_loop_1) 5)
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; Closures can be recursive
+;;
+
+(xtmtest '(bind-func recursive-closure-test
+ (lambda (a)
+ (if (< a 1)
+ (printf "done\n")
+ (begin (printf "a: %lld\n" a)
+ (recursive-closure-test (- a 1))))))
+
+ (recursive-closure-test 3))
+
+;; check TAIL OPTIMIZATION
+;; if there is no tail call optimiation
+;; in place then this should blow the
+;; stack and crash the test
+
+;; CANNOT RUN THIS TEST ON WINDOWS (i.e. no salloc)!
+(if (not (equal? (sys:platform) "Windows"))
+ (xtmtest '(bind-func tail_opt_test
+ (lambda (n:i64)
+ (let ((a:float* (salloc 8000)))
+ (if (= n 0)
+ (printf "tail opt test passed!\n")
+ (tail_opt_test (- n 1))))))
+
+ (tail_opt_test 200)))
+
+(println 'A 'segfault 'here 'incidates 'that 'tail-call-optimizations 'are 'not 'working!)
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; some anon lambda tests
+;;
+
+(xtmtest '(bind-func infer_lambdas_test
+ (lambda ()
+ (let ((a 5)
+ (b (lambda (x) (* x x)))
+ (c (lambda (y) (* y y))))
+ (c (b a)))))
+
+ (infer_lambdas_test))
+
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; a simple tuple example
+;;
+;; tuple types are represented as <type,type,type>*
+;;
+
+;; make and return a simple tuple
+(xtmtest '(bind-func tuple-test1
+ (lambda ()
+ (let ((t:<i64,double,i32>* (alloc)))
+ t)))
+
+ (tuple-test1))
+
+;; logview shows [<i64,double,i32>*]*
+;; i.e. a closure that takes no arguments
+;; and returns the tuple <i64,double,i32>*
+
+
+;; here's another tuple example
+;; note that my-test-7's return type is inferred
+;; by the tuple-reference index
+;; (i.e. i64 being tuple index 0)
+(xtmtest '(bind-func tuple-test2
+ (lambda ()
+ (let ((a:<i64,double>* (alloc)) ; returns pointer to type <i64,double>
+ (b 37)
+ (c 6.4))
+ (tuple-set! a 0 b) ;; set i64 to 64
+ (tset! a 1 c) ;; set double to 6.4 - tset! is an alias for tuple-set!
+ (printf "tuple:1 %lld::%f\n" (tuple-ref a 0) (tref a 1))
+ ;; we can fill a tuple in a single call by using tfill!
+ (tfill! a 77 77.7)
+ (printf "tuple:2 %lld::%f\n" (tuple-ref a 0) (tuple-ref a 1))
+ (tuple-ref a 0))))
+
+ (tuple-test2) 77)
+
+;; return first element which is i64
+;; should be 64 as we return the
+;; first element of the tuple
+;; (println (my-test-7)) ; 77
+
+
+;; tbind binds variables to values
+;; based on tuple structure
+;; _ (underscore) means don't attempt
+;; to match against this position in
+;; the tuple (i.e. skip)
+(xtmtest '(bind-func tuple-bind-test
+ (lambda ()
+ (let ((t1:<i32,float,<i32,float>*,double>* (alloc))
+ (t2:<i32,float>* (alloc))
+ (a 0) (b:float 0.0) (c 0.0))
+ (tfill! t2 3 3.3)
+ (tfill! t1 1 2.0 t2 4.0)
+ (tbind t1 a b _ c)
+ c)))
+
+ (tuple-bind-test) 4.0)
+
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; some array code with *casting*
+;; this function returns void
+(xtmtest '(bind-func array-test1
+ (lambda ()
+ (let ((v1:|5,float|* (alloc))
+ (v2:|5,float|* (alloc))
+ (i 0)
+ (k 0))
+ (dotimes (i 5)
+ ;; random returns double so "truncate" to float
+ ;; which is what v expects
+ (array-set! v1 i (dtof (random))))
+ ;; we can use the afill! function to fill an array
+ (afill! v2 1.1 2.2 3.3 4.4 5.5)
+ (dotimes (k 5)
+ ;; unfortunately printf doesn't like floats
+ ;; so back to double for us :(
+ (printf "val: %lld::%f::%f\n" k
+ (ftod (array-ref v1 k))
+ (ftod (aref v2 k)))))))
+
+ (array-test1))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; some crazy array code with
+;; closures and arrays
+;; try to figure out what this all does
+;;
+;; this example uses the array type
+;; the pretty print for this type is
+;; |num,type| num elements of type
+;; |5,i64| is an array of 5 x i64
+;;
+;; An array is not a pointer type
+;; i.e. |5,i64| cannot be bitcast to i64*
+;;
+;; However an array can be a pointer
+;; i.e. |5,i64|* can be bitcast to i64*
+;; i.e. |5,i64|** to i64** etc..
+;;
+;; make-array returns a pointer to an array
+;; i.e. (make-array 5 i64) returns type |5,i64|*
+;;
+;; aref (array-ref) and aset! (array-set!)
+;; can operate with either pointers to arrays or
+;; standard pointers.
+;;
+;; in other words aref and aset! are happy
+;; to work with either i64* or |5,i64|*
+
+(bind-func array-test2
+ (lambda (v:|5,i64|*)
+ (let ((f (lambda (x)
+ (* (array-ref v 2) x))))
+ f)))
+
+(bind-func array-test3
+ (lambda (v:|5,[i64,i64]*|*)
+ (let ((ff (aref v 0))) ; aref alias for array-ref
+ (ff 5))))
+
+(xtmtest '(bind-func array-test4
+ (lambda ()
+ (let ((v:|5,[i64,i64]*|* (alloc)) ;; make an array of closures!
+ (vv:|5,i64|* (alloc)))
+ (array-set! vv 2 3)
+ (aset! v 0 (array-test2 vv)) ;; aset! alias for array-set!
+ (array-test3 v))))
+
+ ;; try to guess the answer before you call this!!
+ (array-test4))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; some conditionals
+
+(xtmtest '(bind-func cond-test1
+ (lambda (x:i64 y)
+ (if (> x y)
+ x
+ y)))
+
+ (cond-test1 12 13))
+
+;; returns boolean true
+(xtmtest '(bind-func cond-test2
+ (lambda (x:i64)
+ (cond ((= x 1) (printf "A\n"))
+ ((= x 2) (printf "B\n"))
+ ((= x 3) (printf "C\n"))
+ ((= x 4) (printf "D\n"))
+ (else (printf "E\n")))
+ #t))
+
+ (cond-test2 1))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; making a linear envelop generator
+;; for signal processing and alike
+
+(bind-func envelope-segments
+ (lambda (points:double* num-of-points:i64)
+ (let ((lines:[double,double]** (zone-alloc num-of-points))
+ (k 0))
+ (dotimes (k num-of-points)
+ (let* ((idx (* k 2))
+ (x1 (pointer-ref points (+ idx 0)))
+ (y1 (pointer-ref points (+ idx 1)))
+ (x2 (pointer-ref points (+ idx 2)))
+ (y2 (pointer-ref points (+ idx 3)))
+ (m (if (= 0.0 (- x2 x1)) 0.0 (/ (- y2 y1) (- x2 x1))))
+ (c (- y2 (* m x2)))
+ (l (lambda (time) (+ (* m time) c))))
+ (pointer-set! lines k l)))
+ lines)))
+
+(bind-func make-envelope
+ (lambda (points:double* num-of-points)
+ (let ((klines:[double,double]** (envelope-segments points num-of-points))
+ (line-length num-of-points))
+ (lambda (time)
+ (let ((res -1.0)
+ (k:i64 0))
+ (dotimes (k num-of-points)
+ (let ((line (pointer-ref klines k))
+ (time-point (pointer-ref points (* k 2))))
+ (if (or (= time time-point)
+ (< time-point time))
+ (set! res (line time)))))
+ res)))))
+
+;; make a convenience wrapper
+(xtmtest '(bind-func env-wrap
+ (let* ((points 3)
+ (data:double* (zone-alloc (* points 2))))
+ (pointer-set! data 0 0.0) ;; point data
+ (pset! data 1 0.0)
+ (pset! data 2 2.0)
+ (pset! data 3 1.0)
+ (pset! data 4 4.0)
+ (pset! data 5 0.0)
+ (let ((f (make-envelope data points)))
+ (lambda (time:double)
+ (f time)))))
+ (env-wrap 0.0) 0.0)
+
+(xtmtest-result (env-wrap 1.0) 0.5)
+(xtmtest-result (env-wrap 2.0) 1.0)
+(xtmtest-result (env-wrap 2.5) 0.75)
+(xtmtest-result (env-wrap 4.0) 0.0)
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; direct access to a closures environment
+;;
+;; it is possible to directly access a closures
+;; environment in order to read or modify data
+;; at runtime.
+;;
+;; You do this using a dot operator
+;; To access an environment slot you use
+;; closure.slot:type
+;; So for example
+;; (f.a:i32)
+;; would return the 32bit integer symbol 'a'
+;; from the closure 'f'
+;;
+;; To set an environment slot you just
+;; add a value of the correct type
+;; for example
+;; (f.a:i32 565)
+;; would set 'a' in 'f' to 565
+;;
+;; let's create a closure that capture's 'a'
+
+
+(xtmtest '(bind-func dot-access-test1
+ (let ((a:i32 6))
+ (lambda ()
+ (printf "a:%d\n" a)
+ a)))
+ (dot-access-test1))
+
+;; now let's create a new function
+;; that calls my-test14 twice
+;; once normally
+;; then we directly set the closures 'a' binding
+;; then call again
+;;
+(xtmtest '(bind-func dot-access-test2
+ (lambda (x:i32)
+ (dot-access-test1)
+ (dot-access-test1.a:i32 x)
+ (dot-access-test1)))
+
+ (dot-access-test2 9))
+
+;; of course this works just as well for
+;; non-global closures
+(xtmtest '(bind-func dot-access-test3
+ (lambda (a:i32)
+ (let ((f (lambda ()
+ (* 3 a))))
+ f)))
+ (dot-access-test3 1))
+
+(xtmtest '(bind-func dot-access-test4
+ (lambda ()
+ (let ((f (dot-access-test3 5)))
+ (f.a:i32 7)
+ (f))))
+
+ (dot-access-test4)
+ 21)
+
+;; and you can get and set closures also!
+(xtmtest '(bind-func dot-access-test5
+ (lambda ()
+ (let ((f (lambda (x:i64) x)))
+ (lambda (z)
+ (f z)))))
+
+ (dot-access-test5))
+
+(xtmtest '(bind-func dot-access-test6
+ (lambda ()
+ (let ((t1 (dot-access-test5))
+ (t2 (dot-access-test5)))
+ ;; identity of 5
+ (printf "%lld:%lld\n" (t1 5) (t2 5))
+ (t1.f:[i64,i64]* (lambda (x:i64) (* x x)))
+ ;; square of 5
+ (printf "%lld:%lld\n" (t1 5) (t2 5))
+ ;; cube of 5
+ (t2.f:[i64,i64]* (lambda (y:i64) (* y y y)))
+ (printf "%lld:%lld\n" (t1 5) (t2 5))
+ void)))
+
+ (dot-access-test6)) ;; 5:5 > 25:5 > 25:125
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; named types
+
+;; it can sometimes be helpful to allocate
+;; a predefined tuple type on the stack
+;; you can do this using allocate
+(bind-type vec3 <double,double,double>)
+
+;; String printing!
+(bind-func vec3_print:[void,vec3*]*
+ (lambda (x)
+ (printf "<%d,%d,%d>" (tref x 0) (tref x 1) (tref x 2))
+ void))
+
+(bind-poly print vec3_print)
+
+;; note that point is deallocated at the
+;; end of the function call. You can
+;; stack allocate (stack-alloc)
+;; any valid type (i64 for example)
+(xtmtest '(bind-func salloc-test
+ (lambda ()
+ (let ((point:vec3* (stack-alloc)))
+ (tset! point 0 0.0)
+ (tset! point 1 -1.0)
+ (tset! point 2 1.0)
+ 1)))
+
+ (salloc-test)) ;; 1
+
+;; all named types have 2 default constructors
+;; name (zone alloation) + name_h (heap allocation)
+;; and a default print poly
+(xtmtest '(bind-func data-constructor-test
+ (lambda ()
+ (let ((v1 (vec3 1.0 2.0 3.0))
+ (v2 (vec3_h 4.0 5.0 6.0)))
+ (println v1 v2)
+ ;; halloced vec3 needs freeing
+ (free v2)
+ void)))
+
+ (data-constructor-test))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; aref-ptr and tref-ptr
+;;
+
+;; aref-ptr and tref-ptr return a pointer to an element
+;; just as aref and tref return elements aref-ptr and
+;; tref-ptr return a pointer to those elements.
+
+;; This allows you to do things like create an array
+;; with an offset
+(xtmtest '(bind-func aref-ptr-test
+ (lambda ()
+ (let ((arr:|32,i64|* (alloc))
+ (arroff (aref-ptr arr 16))
+ (i 0)
+ (k 0))
+ ;; load arr
+ (dotimes (i 32) (aset! arr i i))
+ (dotimes (k 16)
+ (printf "index: %lld\tarr: %lld\tarroff: %lld\n"
+ k (aref arr k) (pref arroff k))))))
+
+ (aref-ptr-test))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; arrays
+;; Extempore lang supports arrays as for first class
+;; aggregate types (in other words as distinct from
+;; a pointer).
+;;
+;; an array is made up of a size and a type
+;; |32,i64| is an array of 32 elements of type i64
+;;
+
+(bind-type tuple-with-array <double,|32,|4,i32||,float>)
+
+(xtmtest '(bind-func array-test5
+ (lambda ()
+ (let ((tup:tuple-with-array* (stack-alloc))
+ (t2:|32,i64|* (stack-alloc)))
+ (aset! t2 0 9)
+ (tset! tup 2 5.5)
+ (aset! (aref-ptr (tref-ptr tup 1) 0) 0 0)
+ (aset! (aref-ptr (tref-ptr tup 1) 0) 1 1)
+ (aset! (aref-ptr (tref-ptr tup 1) 0) 2 2)
+ (printf "val: %lld %lld %f\n"
+ (aref (aref-ptr (tref-ptr tup 1) 0) 1)
+ (aref t2 0) (ftod (tref tup 2)))
+ (aref (aref-ptr (tref-ptr tup 1) 0) 1))))
+
+ (array-test5) 1) ;; val: 1 9 5.5
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; Global Variables
+;;
+;; You can allocate global variables using bind-val
+;;
+
+(bind-val g_var_a i32 5)
+
+;; increment g_var_a by inc
+;; and return new value of g_var_a
+(xtmtest '(bind-func global_var_test1
+ (lambda (incr)
+ (set! g_var_a (+ g_var_a incr))
+ g_var_a))
+
+ (global_var_test1 3) 8) ;; 8
+
+;; you can bind any primitive type
+(bind-val g_var_b double 5.5)
+(bind-val g_var_c i1 0)
+
+(xtmtest '(bind-func global_var_test1b
+ (lambda ()
+ (* g_var_b (if g_var_c 1.0 4.0))))
+
+ (global_var_test1b) 22.0)
+
+;; global strings
+
+(bind-val g_cstring i8* "Jiblet.")
+
+(xtmtest '(bind-func test_g_cstring
+ (lambda ()
+ (let ((i 0))
+ (dotimes (i 7)
+ (printf "g_cstring[%lld] = %c\n" i (pref g_cstring i)))
+ (printf "\nSpells... %s\n" g_cstring))))
+
+ (test_g_cstring))
+
+(xtmtest '(bind-func test_g_cstring1
+ (lambda ()
+ (let ((test_cstring "Niblot.")
+ (i 0)
+ (total 0))
+ (dotimes (i 7)
+ (let ((c1 (pref g_cstring i))
+ (c2 (pref test_cstring i)))
+ (printf "checking %c against %c\n" c1 c2)
+ (if (= c1 c2)
+ (set! total (+ total 1)))))
+ total)))
+
+ (test_g_cstring1) 5)
+
+
+
+
+
+;; for tuples, arrays and vectors, bind-val only takes *two*
+;; arguments. The tuple/array/vector will be initialised to zero.
+
+(bind-val g_tuple1 <i64,i64>)
+(bind-val g_tuple2 <double,double>)
+
+(xtmtest '(bind-func test_g_tuple
+ (lambda ()
+ (tfill! g_tuple1 1 4)
+ (tfill! g_tuple2 4.0 1.0)
+ (and (= (tref g_tuple1 0) (dtoi64 (tref g_tuple2 1)))
+ (= (dtoi64 (tref g_tuple2 0)) (tref g_tuple1 1)))))
+
+ (test_g_tuple) 1)
+
+;; same thing with arrays
+
+(bind-val g_array1 |10,double|)
+(bind-val g_array2 |10,i64|)
+
+;; if we just loop over and print the values in each array
+
+(xtmtest '(bind-func test_g_array11
+ (lambda ()
+ (let ((i 0))
+ (dotimes (i 10)
+ (printf "garray_1[%lld] = %f garray_2[%lld] = %lld\n"
+ i (aref g_array1 i) i (aref g_array2 i))))))
+
+ (test_g_array11) 1)
+
+;; but if we loop over and set some values into the arrays
+
+(xtmtest '(bind-func test_g_array2
+ (lambda ()
+ (let ((i 0))
+ (dotimes (i 10)
+ (aset! g_array1 i (i64tod i))
+ (aset! g_array2 i i)
+ (printf "garray_1[%lld] = %f garray_2[%lld] = %lld\n"
+ i (aref g_array1 i) i (aref g_array2 i)))
+ (= (dtoi64 (aref g_array1 5))
+ (aref g_array2 5)))))
+
+ (test_g_array2) 1)
+
+;; just to test, let's try a large array
+
+(bind-val g_array3 |100000000,i64|)
+
+(xtmtest '(bind-func test_g_array3
+ (lambda ()
+ (let ((i 0))
+ (dotimes (i 100000000)
+ (aset! g_array3 i i))
+ (= (pref g_array3 87654321)
+ 87654321))))
+
+ (test_g_array3) 1)
+
+;; if you want to bind a global pointer, then the third 'value'
+;; argument is the size of the memory to allocate (in elements, not in bytes)
+
+(bind-val g_ptr0 double* 10)
+
+(xtmtest '(bind-func test_g_ptr0
+ (lambda ()
+ (let ((total 0.0)
+ (i 0))
+ (dotimes (i 10)
+ (pset! g_ptr0 i (i64tod i))
+ (set! total (+ total (pref g_ptr0 i))))
+ total)))
+
+ (test_g_ptr0) 45.0)
+
+(bind-val g_ptr1 |4,i32|* 2)
+(bind-val g_ptr2 <i64,double>* 4)
+
+(xtmtest '(bind-func test_g_ptr1
+ (lambda ()
+ (afill! g_ptr1 11 66 35 81)
+ (tset! g_ptr2 1 35.0)
+ (printf "%f :: %d\n" (tref g_ptr2 1) (aref g_ptr1 2))
+ (aref g_ptr1 3)))
+
+ (test_g_ptr1) 81) ;; should also print 35.000000 :: 35
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; Callbacks
+
+(xtmtest '(bind-func callback-test
+ (lambda (time:i64 count:i64)
+ (printf "time: %lld:%lld\n" time count)
+ (callback (+ time 1000) callback-test (+ time 22050) (+ count 1))))
+
+ (callback-test (now) 0))
+
+;; compiling this will stop the callbacks
+;;
+;; of course we need to keep the type
+;; signature the same [void,i64,i64]*
+;;
+(xtmtest '(bind-func callback-test
+ (lambda (time:i64 count:i64)
+ #t))
+
+ (callback-test))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; some memzone tests
+
+(xtmtest '(bind-func memzone-test1
+ (lambda ()
+ (let ((b:|5,double|* (zalloc)))
+ (aset! b 0
+ (memzone 1024
+ (let ((a:|10,double|* (zalloc)))
+ (aset! a 0 3.5)
+ (aref a 0))))
+ (let ((c:|9,i32|* (zalloc)))
+ (aset! c 0 99)
+ (aref b 0)))))
+
+ (memzone-test1) 3.5)
+
+(xtmtest '(bind-func memzone-test2
+ (lambda ()
+ (memzone 1024
+ (let ((k:|15,double|* (zalloc))
+ (f (lambda (fa:|15,double|*)
+ (memzone 1024
+ (let ((a:|10,double|* (zalloc))
+ (i 0))
+ (dotimes (i 10)
+ (aset! a i (* (aref fa i) (random))))
+ a)))))
+ (f k)))))
+
+ (memzone-test2))
+
+(xtmtest '(bind-func memzone-test3
+ (lambda ()
+ (let ((v (memzone-test2))
+ (i 0))
+ (dotimes (i 10) (printf "%lld:%f\n" i (aref v i))))))
+
+ (memzone-test3)) ;; should print all 0.0's
+
+(xtmtest '(bind-func memzone-test4
+ (lambda ()
+ (memzone 1024 (* 44100 10)
+ (let ((a:|5,double|* (alloc)))
+ (aset! a 0 5.5)
+ (aref a 0)))))
+
+ (memzone-test4) 5.50000)
+
+;;
+;; Large allocation of memory on BUILD (i.e. when the closure is created)
+;; requires an optional argument (i.e. an amount of memory to allocate
+;; specifically for closure creation)
+;;
+;; This memory is automatically free'd whenever you recompile the closure
+;; (it will be destroyed and replaced by a new allocation of the
+;; same amount or whatever new amount you have allocated for closure
+;; compilation)
+;;
+(xtmtest '(bind-func closure-zalloc-test 1000000
+ (let ((k:|100000,double|* (zalloc)))
+ (lambda ()
+ (aset! k 0 1.0)
+ (aref k 0))))
+
+ (closure-zalloc-test 1000000))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; Ad-Hoc Polymorphism
+;;
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+;; extempore supports ad-hoc polymorphism
+;; at some stage in the future this will
+;; be implicit - but for the moment
+;; it is explicitly defined using bind-poly
+
+;; ad-hoc polymorphism allows you to provide
+;; different specialisations depending on
+;; type. In other words, a single 'name'
+;; can be bound to multiple function
+;; implementations each with a uniqute
+;; type.
+
+
+;; poly variables can be for functions of
+;; mixed argument lengths
+;;
+;; so for example:
+(bind-func poly-test4
+ (lambda (a:i8*)
+ (printf "%s\n" a)))
+
+(bind-func poly-test5
+ (lambda (a:i8* b:i8*)
+ (printf "%s %s\n" a b)))
+
+(bind-func poly-test6
+ (lambda (a:i8* b:i8* c:i8*)
+ (printf "%s %s %s\n" a b c)))
+
+;; bind these three functions to poly 'print'
+(bind-poly testprint poly-test4)
+(bind-poly testprint poly-test5)
+(bind-poly testprint poly-test6)
+
+(xtmtest '(bind-func poly-test7
+ (lambda ()
+ (testprint "extempore's")
+ (testprint "extempore's" "polymorphism")
+ (testprint "extempore's" "polymorphism" "rocks")))
+
+ (poly-test7))
+
+;; polys can Also specialize
+;; on the return type
+(bind-func poly-test8
+ (lambda (a:double)
+ (* a a)))
+
+(bind-func poly-test9
+ (lambda (a:double)
+ (dtoi64 (* a a))))
+
+(bind-poly sqrd poly-test8)
+(bind-poly sqrd poly-test9)
+
+;; specialize on [i64,double]*
+;;
+(xtmtest '(bind-func poly-test10:[i64,double]*
+ (lambda (a)
+ (+ 1 (sqrd a))))
+ (poly-test10 5.0))
+
+;; specialize on [double,doube]*
+(xtmtest '(bind-func poly-test11:[double,double]*
+ (lambda (a)
+ (+ 1.0 (sqrd a))))
+
+ (poly-test11 5.0))
+
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; a little test for zone cleanup
+;;
+(bind-func MyLittleCleanupTest
+ (lambda ()
+ (let ((tmp2:i8* (alloc 8)))
+ (cleanup (println "Clean up before leaving zone!"))
+ tmp2)))
+
+(xtmtest '(bind-func cleanup-test
+ (lambda ()
+ (letz ((tmp:i8* (alloc 8))
+ (t2 (MyLittleCleanupTest)))
+ (begin
+ (println "In Zone ...")
+ 1))
+ (println "Out of zone ...")
+ void))
+
+ (cleanup-test))
+
+;;;;;;;;;;;;;;;;;;
+;; vector types
+
+;; (bind-func vector-test1
+;; (lambda ()
+;; (let ((v1:/4,float/* (alloc))
+;; (v2:/4,float/* (alloc))
+;; (v3:/4,float/* (alloc)))
+;; (vfill! v1 4.0 3.0 2.0 1.0)
+;; (vfill! v2 1.0 2.0 3.0 4.0)
+;; (vfill! v3 5.0 5.0 5.0 5.0)
+;; (let ((v4 (* v1 v2))
+;; (v5 (> v3 v4))) ;; unforunately vector conditionals don't work!
+;; (printf "mul:%f:%f:%f:%f\n" (ftod (vref v4 0)) (ftod (vref v4 1)) (ftod (vref v4 2)) (ftod (vref v4 3)))
+;; (printf "cmp:%d:%d:%d:%d\n" (i1toi32 (vref v5 0)) (i1toi32 (vref v5 1)) (i1toi32 (vref v5 2)) (i1toi32 (vref v5 3)))
+;; void))))
+
+;; (test-xtfunc (vector-test1))
+
+(bind-func vector-test2
+ (lambda ()
+ (let ((v1:/4,float/* (alloc))
+ (v2:/4,float/* (alloc)))
+ (vfill! v1 1.0 2.0 4.0 8.0)
+ (vfill! v2 2.0 2.5 2.25 2.125)
+ (* v1 v2))))
+
+(xtmtest '(bind-func vector-test3
+ (lambda ()
+ (let ((a (vector-test2)))
+ (printf "%f:%f:%f:%f\n"
+ (ftod (vref a 0))
+ (ftod (vref a 1))
+ (ftod (vref a 2))
+ (ftod (vref a 3)))
+ void)))
+
+ (vector-test3))
+
+;; vectorised sine func
+(bind-func vsinf4
+ (let ((p:/4,float/* (alloc))
+ (b:/4,float/* (alloc))
+ (c:/4,float/* (alloc))
+ (f1:/4,float/* (alloc))
+ (f2:/4,float/* (alloc))
+ (i:i32 0)
+ (p_ 0.225)
+ (b_ (dtof (/ 4.0 3.1415)))
+ (c_ (dtof (/ -4.0 (* 3.1415 3.1415)))))
+ (dotimes (i 4) (vset! p i p_) (vset! b i b_) (vset! c i c_))
+ (lambda (x:/4,float/)
+ ;; no SIMD for abs yet!
+ (dotimes (i 4) (vset! f1 i (fabs (vref x i))))
+ (let ((y (+ (* b x) (* c x f1))))
+ ;; no SIMD for abs yet!
+ (dotimes (i 4) (vset! f2 i (fabs (vref y i))))
+ (+ (* p (- (* y f2) y)) y)))))
+
+(bind-func vcosf4
+ (let ((p:/4,float/* (alloc))
+ (b:/4,float/* (alloc))
+ (c:/4,float/* (alloc))
+ (d:/4,float/* (alloc))
+ (f1:/4,float/* (alloc))
+ (f2:/4,float/* (alloc))
+ (i:i32 0)
+ (p_ 0.225)
+ (d_ (dtof (/ 3.1415 2.0)))
+ (b_ (dtof (/ 4.0 3.1415)))
+ (c_ (dtof (/ -4.0 (* 3.1415 3.1415)))))
+ (dotimes (i 4)
+ (vset! p i p_) (vset! b i b_) (vset! c i c_) (vset! d i d_))
+ (lambda (x:/4,float/)
+ ;; offset x for cos
+ (set! x (+ x d))
+ ;; no SIMD for abs yet!
+ (dotimes (i 4) (vset! f1 i (fabs (vref x i))))
+ (let ((y (+ (* b x) (* c x f1))))
+ ;; no SIMD for abs yet!
+ (dotimes (i 4) (vset! f2 i (fabs (vref y i))))
+ (+ (* p (- (* y f2) y)) y)))))
+
+
+(xtmtest '(bind-func vector-test4
+ (lambda ()
+ (let ((a:/4,float/* (alloc)))
+ (vfill! a 0.1 0.2 0.3 0.4)
+ (let ((b (vsinf4 (pref a 0)))
+ (c (vcosf4 (pref a 0))))
+ (printf "precision inaccuracy is expected:\n")
+ (printf " sinf:\t%f,%f,%f,%f\n"
+ (ftod (sin 0.1:f))
+ (ftod (sin 0.2:f))
+ (ftod (sin 0.3:f))
+ (ftod (sin 0.4:f)))
+ (printf "vsinf:\t%f,%f,%f,%f\n"
+ (ftod (vref b 0))
+ (ftod (vref b 1))
+ (ftod (vref b 2))
+ (ftod (vref b 3)))
+ (printf " cosf:\t%f,%f,%f,%f\n"
+ (ftod (cos 0.1:f))
+ (ftod (cos 0.2:f))
+ (ftod (cos 0.3:f))
+ (ftod (cos 0.4:f)))
+ (printf "vcosf:\t%f,%f,%f,%f\n"
+ (ftod (vref c 0))
+ (ftod (vref c 1))
+ (ftod (vref c 2))
+ (ftod (vref c 3)))
+ void))))
+
+ (vector-test4))
+
+;; test the call-as-xtlang macro
+
+;; make sure it'll handle multiple body forms
+(xtmtest-result (call-as-xtlang (println 1) (println 2) 5)
+ 5)
+
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;; test globalvar as closure
+;;
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+(bind-func testinc
+ (lambda (incr:i64)
+ (lambda (x:i64)
+ (+ x incr))))
+
+(bind-val GlobalInc [i64,i64]* (testinc 2))
+
+(xtmtest '(bind-func ginc
+ (lambda ()
+ (GlobalInc 5)))
+ (ginc) 7)
+
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; syntax highlighting tests ;;
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; these don't return any values, they're visual tests---do they look
+;; right?
+
+(bind-func hl_test1a:[i32,double,|4,i32|**]* 4000
+ "docstring"
+ (lambda (a b)
+ (printf "done\n")))
+
+(bind-func hl_test1b:[i32]*
+ (lambda ()
+ (let ((i:i32 6))
+ (printf "done\n"))))
+
+(bind-val hl_test2 <i32,i32>)
+(bind-val hl_test3 |4,i8|)
+(bind-val hl_test4 double* 10)
+(bind-val hl_test5 i8* "teststr")
+
+(bind-type hl_test_type <i64>)
+
+(println '(bind-lib testlib testfn [i32,i32]*))
+
+;; (and 4 5)
+;; (bind-val hl_test4 double* 10)
+;; (bind-type hl_test_type <i64> "docstring")
+;; (bind-lib testlib testfn [i32,i32]*)
+
+---tokens---
+';;; example.xtm -- Extempore code examples ' Comment.Single
+'\n\n' Text
+
+';; Author: Ben Swift, Andrew Sorensen' Comment.Single
+'\n' Text
+
+';; Keywords: extempore' Comment.Single
+'\n\n' Text
+
+';;; Commentary:' Comment.Single
+'\n\n\n\n' Text
+
+';;; Code:' Comment.Single
+'\n\n' Text
+
+';; bit twiddling' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_bit_twiddle_1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'bitwise-and' Name.Variable
+' ' Text
+'65535' Literal.Number.Integer
+' ' Text
+'255' Literal.Number.Integer
+' ' Text
+'15' Literal.Number.Integer
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_bit_twiddle_1' Name.Variable
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_bit_twiddle_2' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'bitwise-not' Name.Variable
+' ' Text
+'-1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_bit_twiddle_2' Name.Variable
+')' Punctuation
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_bit_twiddle_3' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'bitwise-not' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_bit_twiddle_3' Name.Variable
+')' Punctuation
+' ' Text
+'-1' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_bit_twiddle_4' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'bitwise-shift-right' Name.Variable
+' ' Text
+'65535' Literal.Number.Integer
+' ' Text
+'8' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'bitwise-shift-right' Name.Variable
+' ' Text
+'65535' Literal.Number.Integer
+' ' Text
+'4' Literal.Number.Integer
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_bit_twiddle_4' Name.Variable
+')' Punctuation
+' ' Text
+'255' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_bit_twiddle_5' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'bitwise-shift-left' Name.Variable
+' ' Text
+'(' Punctuation
+'bitwise-shift-right' Name.Variable
+' ' Text
+'65535' Literal.Number.Integer
+' ' Text
+'8' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'4' Literal.Number.Integer
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_bit_twiddle_5' Name.Variable
+')' Punctuation
+' ' Text
+'65280' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_bit_twiddle_6' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'bitwise-and' Name.Variable
+' ' Text
+'(' Punctuation
+'bitwise-or' Name.Variable
+' ' Text
+'(' Punctuation
+'bitwise-eor' Name.Variable
+' ' Text
+'21844' Literal.Number.Integer
+' ' Text
+'65534' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'bitwise-eor' Name.Variable
+' ' Text
+'43690' Literal.Number.Integer
+' ' Text
+'65534' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_bit_twiddle_6' Name.Variable
+')' Punctuation
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; integer literals default to 64 bit integers' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'int-literal-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'int-literal-test' Name.Variable
+' ' Text
+'6' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'30' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; float literals default to doubles' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'float-literal-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'5.0' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'float-literal-test' Name.Variable
+' ' Text
+'6.0' Literal.Number.Float
+')' Punctuation
+' ' Text
+'30.0' Literal.Number.Float
+')' Punctuation
+'\n\n' Text
+
+';; you are free to recompile an existing closure' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'int-literal-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'/' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'int-literal-test' Name.Variable
+' ' Text
+'30' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'closure-test1' Name.Function
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'power' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'set!' Keyword
+' ' Text
+'power' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'power' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+' ' Text
+';; set! for closure mutation as per scheme' Comment.Single
+'\n ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'power' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'closure-test1' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'closure-returns-closure-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'closure-returns-closure-test' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'incrementer-test1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'incr' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'set!' Keyword
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'i' Name.Variable
+' ' Text
+'incr' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'incrementer-test1' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'define' Keyword
+' ' Text
+'myf' Name.Variable
+' ' Text
+'(' Punctuation
+'incrementer-test1' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; so we need to type f properly' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'incrementer-test2' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'f' Name.Variable
+':[i64,i64]*' Keyword.Type
+' ' Text
+'x' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'x' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'incrementer-test2' Name.Variable
+' ' Text
+'myf' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; and we can call my-in-maker-wrapper' Comment.Single
+'\n' Text
+
+';; to appy myf' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'incrementer-test2' Name.Variable
+' ' Text
+'myf' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'incrementer-test2' Name.Variable
+' ' Text
+'myf' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'incrementer-test2' Name.Variable
+' ' Text
+'myf' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; of course the wrapper is only required if you' Comment.Single
+'\n' Text
+
+';; need interaction with the scheme world.' Comment.Single
+'\n' Text
+
+';; otherwise you just call my-inc-maker directly' Comment.Single
+'\n\n' Text
+
+';; this avoids the wrapper completely' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'incrementer-test3' Name.Function
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'(' Punctuation
+'incrementer-test1' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'incrementer-test3' Name.Variable
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'incrementer-test3' Name.Variable
+')' Punctuation
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'incrementer-test3' Name.Variable
+')' Punctuation
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+";; hopefully you're getting the idea." Comment.Single
+'\n' Text
+
+";; note that once we've compiled something" Comment.Single
+'\n' Text
+
+';; we can then use it any of our new' Comment.Single
+'\n' Text
+
+';; function definitions.' Comment.Single
+'\n\n' Text
+
+';; do a little 16bit test' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'bitsize-sixteen' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+':i16' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dtoi16' Name.Variable
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'(' Punctuation
+'i16tod' Name.Variable
+' ' Text
+'a' Name.Variable
+')' Punctuation
+' ' Text
+'5.0' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'bitsize-sixteen' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'25' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; while loop test' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_while_loop_1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'count' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'while' Name.Variable
+' ' Text
+'(' Punctuation
+'<' Name.Function
+' ' Text
+'count' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"count = %lld\\n"' Literal.String
+' ' Text
+'count' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'set!' Keyword
+' ' Text
+'count' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'count' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'count' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_while_loop_1' Name.Variable
+')' Punctuation
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; Closures can be recursive' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'recursive-closure-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'if' Keyword
+' ' Text
+'(' Punctuation
+'<' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"done\\n"' Literal.String
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'begin' Keyword
+' ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"a: %lld\\n"' Literal.String
+' ' Text
+'a' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'recursive-closure-test' Name.Variable
+' ' Text
+'(' Punctuation
+'-' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'recursive-closure-test' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; check TAIL OPTIMIZATION' Comment.Single
+'\n' Text
+
+';; if there is no tail call optimiation' Comment.Single
+'\n' Text
+
+';; in place then this should blow the' Comment.Single
+'\n' Text
+
+';; stack and crash the test' Comment.Single
+'\n\n' Text
+
+';; CANNOT RUN THIS TEST ON WINDOWS (i.e. no salloc)!' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'if' Keyword
+' ' Text
+'(' Punctuation
+'not' Name.Function
+' ' Text
+'(' Punctuation
+'equal?' Name.Function
+' ' Text
+'(' Punctuation
+'sys:platform' Name.Variable
+')' Punctuation
+' ' Text
+'"Windows"' Literal.String
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'tail_opt_test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'n' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'a' Name.Variable
+':float*' Keyword.Type
+' ' Text
+'(' Punctuation
+'salloc' Name.Function
+' ' Text
+'8000' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'if' Keyword
+' ' Text
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'n' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"tail opt test passed!\\n"' Literal.String
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tail_opt_test' Name.Variable
+' ' Text
+'(' Punctuation
+'-' Name.Function
+' ' Text
+'n' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'tail_opt_test' Name.Variable
+' ' Text
+'200' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n \n' Text
+
+'(' Punctuation
+'println' Name.Function
+' ' Text
+"'A" Literal.String.Symbol
+' ' Text
+"'segfault" Literal.String.Symbol
+' ' Text
+"'here" Literal.String.Symbol
+' ' Text
+"'incidates" Literal.String.Symbol
+' ' Text
+"'that" Literal.String.Symbol
+' ' Text
+"'tail-call-optimizations" Literal.String.Symbol
+' ' Text
+"'are" Literal.String.Symbol
+' ' Text
+"'not" Literal.String.Symbol
+' ' Text
+"'working!" Literal.String.Symbol
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; some anon lambda tests' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'infer_lambdas_test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'a' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'b' Name.Variable
+' ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'x' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'c' Name.Variable
+' ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'y' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'y' Name.Variable
+' ' Text
+'y' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+' \n ' Text
+'(' Punctuation
+'c' Name.Variable
+' ' Text
+'(' Punctuation
+'b' Name.Variable
+' ' Text
+'a' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'infer_lambdas_test' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';; a simple tuple example' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; tuple types are represented as <type,type,type>*' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n\n' Text
+
+';; make and return a simple tuple' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'tuple-test1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'t' Name.Variable
+':<i64,double,i32>*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'t' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'tuple-test1' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; logview shows [<i64,double,i32>*]*' Comment.Single
+'\n' Text
+
+';; i.e. a closure that takes no arguments' Comment.Single
+'\n' Text
+
+';; and returns the tuple <i64,double,i32>*' Comment.Single
+'\n\n\n' Text
+
+";; here's another tuple example" Comment.Single
+'\n' Text
+
+";; note that my-test-7's return type is inferred" Comment.Single
+'\n' Text
+
+';; by the tuple-reference index' Comment.Single
+'\n' Text
+
+';; (i.e. i64 being tuple index 0)' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'tuple-test2' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'a' Name.Variable
+':<i64,double>*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+' ' Text
+'; returns pointer to type <i64,double>' Comment.Single
+'\n ' Text
+'(' Punctuation
+'b' Name.Variable
+' ' Text
+'37' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'c' Name.Variable
+' ' Text
+'6.4' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tuple-set!' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'b' Name.Variable
+')' Punctuation
+' ' Text
+';; set i64 to 64' Comment.Single
+'\n ' Text
+'(' Punctuation
+'tset!' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+' ' Text
+'c' Name.Variable
+')' Punctuation
+' ' Text
+';; set double to 6.4 - tset! is an alias for tuple-set!' Comment.Single
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"tuple:1 %lld::%f\\n"' Literal.String
+' ' Text
+'(' Punctuation
+'tuple-ref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+';; we can fill a tuple in a single call by using tfill!' Comment.Single
+'\n ' Text
+'(' Punctuation
+'tfill!' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'77' Literal.Number.Integer
+' ' Text
+'77.7' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"tuple:2 %lld::%f\\n"' Literal.String
+' ' Text
+'(' Punctuation
+'tuple-ref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'tuple-ref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tuple-ref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'tuple-test2' Name.Variable
+')' Punctuation
+' ' Text
+'77' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; return first element which is i64' Comment.Single
+'\n' Text
+
+';; should be 64 as we return the' Comment.Single
+'\n' Text
+
+';; first element of the tuple' Comment.Single
+'\n' Text
+
+';; (println (my-test-7)) ; 77' Comment.Single
+'\n\n\n' Text
+
+';; tbind binds variables to values' Comment.Single
+'\n' Text
+
+';; based on tuple structure' Comment.Single
+'\n' Text
+
+";; _ (underscore) means don't attempt" Comment.Single
+'\n' Text
+
+';; to match against this position in' Comment.Single
+'\n' Text
+
+';; the tuple (i.e. skip)' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'tuple-bind-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'t1' Name.Variable
+':<i32,float,<i32,float>*,double>*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'t2' Name.Variable
+':<i32,float>*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'b' Name.Variable
+':float' Keyword.Type
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+' ' Text
+'(' Punctuation
+'c' Name.Variable
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tfill!' Name.Function
+' ' Text
+'t2' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+' ' Text
+'3.3' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tfill!' Name.Function
+' ' Text
+'t1' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+' ' Text
+'2.0' Literal.Number.Float
+' ' Text
+'t2' Name.Variable
+' ' Text
+'4.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tbind' Name.Function
+' ' Text
+'t1' Name.Variable
+' ' Text
+'a' Name.Variable
+' ' Text
+'b' Name.Variable
+' ' Text
+'_' Name.Variable
+' ' Text
+'c' Name.Variable
+')' Punctuation
+'\n ' Text
+'c' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'tuple-bind-test' Name.Variable
+')' Punctuation
+' ' Text
+'4.0' Literal.Number.Float
+')' Punctuation
+'\n\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';; some array code with *casting*' Comment.Single
+'\n' Text
+
+';; this function returns void' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'array-test1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'v1' Name.Variable
+':|5,float|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'v2' Name.Variable
+':|5,float|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'k' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+';; random returns double so "truncate" to float' Comment.Single
+'\n ' Text
+';; which is what v expects' Comment.Single
+'\n ' Text
+'(' Punctuation
+'array-set!' Name.Function
+' ' Text
+'v1' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'dtof' Name.Function
+' ' Text
+'(' Punctuation
+'random' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+';; we can use the afill! function to fill an array' Comment.Single
+'\n ' Text
+'(' Punctuation
+'afill!' Name.Function
+' ' Text
+'v2' Name.Variable
+' ' Text
+'1.1' Literal.Number.Float
+' ' Text
+'2.2' Literal.Number.Float
+' ' Text
+'3.3' Literal.Number.Float
+' ' Text
+'4.4' Literal.Number.Float
+' ' Text
+'5.5' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'k' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+";; unfortunately printf doesn't like floats" Comment.Single
+'\n ' Text
+';; so back to double for us :(' Comment.Single
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"val: %lld::%f::%f\\n"' Literal.String
+' ' Text
+'k' Name.Variable
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'array-ref' Name.Function
+' ' Text
+'v1' Name.Variable
+' ' Text
+'k' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'v2' Name.Variable
+' ' Text
+'k' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'array-test1' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';; some crazy array code with' Comment.Single
+'\n' Text
+
+';; closures and arrays' Comment.Single
+'\n' Text
+
+';; try to figure out what this all does' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; this example uses the array type' Comment.Single
+'\n' Text
+
+';; the pretty print for this type is' Comment.Single
+'\n' Text
+
+';; |num,type| num elements of type' Comment.Single
+'\n' Text
+
+';; |5,i64| is an array of 5 x i64' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; An array is not a pointer type' Comment.Single
+'\n' Text
+
+';; i.e. |5,i64| cannot be bitcast to i64*' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; However an array can be a pointer' Comment.Single
+'\n' Text
+
+';; i.e. |5,i64|* can be bitcast to i64*' Comment.Single
+'\n' Text
+
+';; i.e. |5,i64|** to i64** etc..' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; make-array returns a pointer to an array' Comment.Single
+'\n' Text
+
+';; i.e. (make-array 5 i64) returns type |5,i64|*' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; aref (array-ref) and aset! (array-set!)' Comment.Single
+'\n' Text
+
+';; can operate with either pointers to arrays or' Comment.Single
+'\n' Text
+
+';; standard pointers.' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; in other words aref and aset! are happy' Comment.Single
+'\n' Text
+
+';; to work with either i64* or |5,i64|*' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'array-test2' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'v' Name.Variable
+':|5,i64|*' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+')' Punctuation
+'\n\t\t ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'(' Punctuation
+'array-ref' Name.Function
+' ' Text
+'v' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'x' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'f' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'array-test3' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'v' Name.Variable
+':|5,[i64,i64]*|*' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'ff' Name.Variable
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'v' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+' ' Text
+'; aref alias for array-ref' Comment.Single
+'\n ' Text
+'(' Punctuation
+'ff' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'array-test4' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'v' Name.Variable
+':|5,[i64,i64]*|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+' ' Text
+';; make an array of closures!' Comment.Single
+'\n ' Text
+'(' Punctuation
+'vv' Name.Variable
+':|5,i64|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'array-set!' Name.Function
+' ' Text
+'vv' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'v' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'(' Punctuation
+'array' Name.Function
+'-test2' Name.Variable
+' ' Text
+'vv' Name.Variable
+')' Punctuation
+')' Punctuation
+' ' Text
+';; aset! alias for array-set!' Comment.Single
+'\n ' Text
+'(' Punctuation
+'array' Name.Function
+'-test3' Name.Variable
+' ' Text
+'v' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+';; try to guess the answer before you call this!!' Comment.Single
+'\n ' Text
+'(' Punctuation
+'array-test4' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';; some conditionals' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'cond-test1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+':i64' Keyword.Type
+' ' Text
+'y' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'if' Keyword
+' ' Text
+'(' Punctuation
+'>' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'y' Name.Variable
+')' Punctuation
+'\n ' Text
+'x' Name.Variable
+'\n ' Text
+'y' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'cond' Keyword
+'-test1' Name.Variable
+' ' Text
+'12' Literal.Number.Integer
+' ' Text
+'13' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; returns boolean true' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'cond-test2' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'cond' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"A\\n"' Literal.String
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"B\\n"' Literal.String
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"C\\n"' Literal.String
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"D\\n"' Literal.String
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'else' Keyword
+' ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"E\\n"' Literal.String
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'#t' Name.Constant
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'cond' Keyword
+'-test2' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';; making a linear envelop generator' Comment.Single
+'\n' Text
+
+';; for signal processing and alike' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'envelope-segments' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'points' Name.Variable
+':double*' Keyword.Type
+' ' Text
+'num-of-points' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'lines' Name.Variable
+':[double,double]**' Keyword.Type
+' ' Text
+'(' Punctuation
+'zone-alloc' Name.Function
+' ' Text
+'num-of-points' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'k' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'k' Name.Variable
+' ' Text
+'num-of-points' Name.Variable
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'let*' Keyword.Type
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'idx' Name.Variable
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'k' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'x1' Name.Variable
+' ' Text
+'(' Punctuation
+'pointer-ref' Name.Function
+' ' Text
+'points' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'idx' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'y1' Name.Variable
+' ' Text
+'(' Punctuation
+'pointer-ref' Name.Function
+' ' Text
+'points' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'idx' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'x2' Name.Variable
+' ' Text
+'(' Punctuation
+'pointer-ref' Name.Function
+' ' Text
+'points' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'idx' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'y2' Name.Variable
+' ' Text
+'(' Punctuation
+'pointer-ref' Name.Function
+' ' Text
+'points' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'idx' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'m' Name.Variable
+' ' Text
+'(' Punctuation
+'if' Keyword
+' ' Text
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'0.0' Literal.Number.Float
+' ' Text
+'(' Punctuation
+'-' Name.Function
+' ' Text
+'x2' Name.Variable
+' ' Text
+'x1' Name.Variable
+')' Punctuation
+')' Punctuation
+' ' Text
+'0.0' Literal.Number.Float
+' ' Text
+'(' Punctuation
+'/' Name.Function
+' ' Text
+'(' Punctuation
+'-' Name.Function
+' ' Text
+'y2' Name.Variable
+' ' Text
+'y1' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'-' Name.Function
+' ' Text
+'x2' Name.Variable
+' ' Text
+'x1' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'c' Name.Variable
+' ' Text
+'(' Punctuation
+'-' Name.Function
+' ' Text
+'y2' Name.Variable
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'m' Name.Variable
+' ' Text
+'x2' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'l' Name.Variable
+' ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'time' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'m' Name.Variable
+' ' Text
+'time' Name.Variable
+')' Punctuation
+' ' Text
+'c' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'pointer-set!' Name.Function
+' ' Text
+'lines' Name.Variable
+' ' Text
+'k' Name.Variable
+' ' Text
+'l' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'lines' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'make-envelope' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'points' Name.Variable
+':double*' Keyword.Type
+' ' Text
+'num-of-points' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'klines' Name.Variable
+':[double,double]**' Keyword.Type
+' ' Text
+'(' Punctuation
+'envelope-segments' Name.Variable
+' ' Text
+'points' Name.Variable
+' ' Text
+'num-of-points' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'line-length' Name.Variable
+' ' Text
+'num-of-points' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'time' Name.Variable
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'res' Name.Variable
+' ' Text
+'-1.0' Literal.Number.Float
+')' Punctuation
+'\n\t\t ' Text
+'(' Punctuation
+'k' Name.Variable
+':i64' Keyword.Type
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'k' Name.Variable
+' ' Text
+'num-of-points' Name.Variable
+')' Punctuation
+'\n\t\t ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'line' Name.Variable
+' ' Text
+'(' Punctuation
+'pointer-ref' Name.Function
+' ' Text
+'klines' Name.Variable
+' ' Text
+'k' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\t\t\t' Text
+'(' Punctuation
+'time-point' Name.Variable
+' ' Text
+'(' Punctuation
+'pointer-ref' Name.Function
+' ' Text
+'points' Name.Variable
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'k' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t\t ' Text
+'(' Punctuation
+'if' Keyword
+' ' Text
+'(' Punctuation
+'or' Keyword
+' ' Text
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'time' Name.Variable
+' ' Text
+'time-point' Name.Variable
+')' Punctuation
+'\n\t\t\t ' Text
+'(' Punctuation
+'<' Name.Function
+' ' Text
+'time-point' Name.Variable
+' ' Text
+'time' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\t\t\t ' Text
+'(' Punctuation
+'set!' Keyword
+' ' Text
+'res' Name.Variable
+' ' Text
+'(' Punctuation
+'line' Name.Variable
+' ' Text
+'time' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'res' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; make a convenience wrapper' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'env-wrap' Name.Function
+'\n ' Text
+'(' Punctuation
+'let*' Keyword.Type
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'points' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'data' Name.Variable
+':double*' Keyword.Type
+' ' Text
+'(' Punctuation
+'zone-alloc' Name.Function
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'points' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'pointer-set!' Name.Function
+' ' Text
+'data' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+' ' Text
+';; point data' Comment.Single
+'\n ' Text
+'(' Punctuation
+'pset!' Name.Function
+' ' Text
+'data' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'pset!' Name.Function
+' ' Text
+'data' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+' ' Text
+'2.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'pset!' Name.Function
+' ' Text
+'data' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+' ' Text
+'1.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'pset!' Name.Function
+' ' Text
+'data' Name.Variable
+' ' Text
+'4' Literal.Number.Integer
+' ' Text
+'4.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'pset!' Name.Function
+' ' Text
+'data' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'(' Punctuation
+'make-env' Name.Function
+'elope' Name.Variable
+' ' Text
+'data' Name.Variable
+' ' Text
+'points' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'time' Name.Variable
+':double' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'time' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'env-wrap' Name.Variable
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'env-wrap' Name.Variable
+' ' Text
+'1.0' Literal.Number.Float
+')' Punctuation
+' ' Text
+'0.5' Literal.Number.Float
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'env-wrap' Name.Variable
+' ' Text
+'2.0' Literal.Number.Float
+')' Punctuation
+' ' Text
+'1.0' Literal.Number.Float
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'env-wrap' Name.Variable
+' ' Text
+'2.5' Literal.Number.Float
+')' Punctuation
+' ' Text
+'0.75' Literal.Number.Float
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'env-wrap' Name.Variable
+' ' Text
+'4.0' Literal.Number.Float
+')' Punctuation
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; direct access to a closures environment' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; it is possible to directly access a closures' Comment.Single
+'\n' Text
+
+';; environment in order to read or modify data' Comment.Single
+'\n' Text
+
+';; at runtime.' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; You do this using a dot operator' Comment.Single
+'\n' Text
+
+';; To access an environment slot you use' Comment.Single
+'\n' Text
+
+';; closure.slot:type' Comment.Single
+'\n' Text
+
+';; So for example' Comment.Single
+'\n' Text
+
+';; (f.a:i32)' Comment.Single
+'\n' Text
+
+";; would return the 32bit integer symbol 'a'" Comment.Single
+'\n' Text
+
+";; from the closure 'f'" Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; To set an environment slot you just' Comment.Single
+'\n' Text
+
+';; add a value of the correct type' Comment.Single
+'\n' Text
+
+';; for example' Comment.Single
+'\n' Text
+
+';; (f.a:i32 565)' Comment.Single
+'\n' Text
+
+";; would set 'a' in 'f' to 565" Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+";; let's create a closure that capture's 'a'" Comment.Single
+'\n\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'dot-access-test1' Name.Function
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'a' Name.Variable
+':i32' Keyword.Type
+' ' Text
+'6' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"a:%d\\n"' Literal.String
+' ' Text
+'a' Name.Variable
+')' Punctuation
+'\n ' Text
+'a' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'do' Keyword
+'t-access-test1' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+";; now let's create a new function" Comment.Single
+'\n' Text
+
+';; that calls my-test14 twice' Comment.Single
+'\n' Text
+
+';; once normally' Comment.Single
+'\n' Text
+
+";; then we directly set the closures 'a' binding" Comment.Single
+'\n' Text
+
+';; then call again' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'dot-access-test2' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+':i32' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dot-access-test1' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dot-access-test1.a' Name.Variable
+':i32' Keyword.Type
+' ' Text
+'x' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dot-access-test1' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'do' Keyword
+'t-access-test2' Name.Variable
+' ' Text
+'9' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; of course this works just as well for' Comment.Single
+'\n' Text
+
+';; non-global closures' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'dot-access-test3' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+':i32' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'3' Literal.Number.Integer
+' ' Text
+'a' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'f' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'do' Keyword
+'t-access-test3' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'dot-access-test4' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'(' Punctuation
+'dot-access-test3' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f.a' Name.Variable
+':i32' Keyword.Type
+' ' Text
+'7' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'do' Keyword
+'t-access-test4' Name.Variable
+')' Punctuation
+'\n ' Text
+'21' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; and you can get and set closures also!' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'dot-access-test5' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+' ' Text
+'x' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'z' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'z' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'do' Keyword
+'t-access-test5' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'dot-access-test6' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'t1' Name.Variable
+' ' Text
+'(' Punctuation
+'dot-access-test5' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'t2' Name.Variable
+' ' Text
+'(' Punctuation
+'dot-access-test5' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+';; identity of 5' Comment.Single
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"%lld:%lld\\n"' Literal.String
+' ' Text
+'(' Punctuation
+'t1' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'t2' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'t1.f' Name.Variable
+':[i64,i64]*' Keyword.Type
+' ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'x' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+';; square of 5' Comment.Single
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"%lld:%lld\\n"' Literal.String
+' ' Text
+'(' Punctuation
+'t1' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'t2' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+';; cube of 5' Comment.Single
+'\n ' Text
+'(' Punctuation
+'t2.f' Name.Variable
+':[i64,i64]*' Keyword.Type
+' ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'y' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'y' Name.Variable
+' ' Text
+'y' Name.Variable
+' ' Text
+'y' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"%lld:%lld\\n"' Literal.String
+' ' Text
+'(' Punctuation
+'t1' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'t2' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'void' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'do' Keyword
+'t-access-test6' Name.Variable
+')' Punctuation
+')' Punctuation
+' ' Text
+';; 5:5 > 25:5 > 25:125' Comment.Single
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; named types' Comment.Single
+'\n\n' Text
+
+';; it can sometimes be helpful to allocate' Comment.Single
+'\n' Text
+
+';; a predefined tuple type on the stack' Comment.Single
+'\n' Text
+
+';; you can do this using allocate' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'bind-type' Keyword
+' ' Text
+'vec3' Name.Function
+' ' Text
+'<double,double,double>' Keyword.Type
+')' Punctuation
+'\n\n' Text
+
+';; String printing!' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'vec3_print' Name.Function
+':[void,vec3*]*' Keyword.Type
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"<%d,%d,%d>"' Literal.String
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'void' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-poly' Keyword
+' ' Text
+'print' Name.Function
+' ' Text
+'vec3_print' Name.Variable
+')' Punctuation
+'\n\n' Text
+
+';; note that point is deallocated at the' Comment.Single
+'\n' Text
+
+';; end of the function call. You can' Comment.Single
+'\n' Text
+
+';; stack allocate (stack-alloc)' Comment.Single
+'\n' Text
+
+';; any valid type (i64 for example)' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'salloc-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'point' Name.Variable
+':vec3*' Keyword.Type
+' ' Text
+'(' Punctuation
+'stack-alloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tset!' Name.Function
+' ' Text
+'point' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tset!' Name.Function
+' ' Text
+'point' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+' ' Text
+'-1.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tset!' Name.Function
+' ' Text
+'point' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+' ' Text
+'1.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'salloc-test' Name.Variable
+')' Punctuation
+')' Punctuation
+' ' Text
+';; 1' Comment.Single
+'\n\n' Text
+
+';; all named types have 2 default constructors' Comment.Single
+'\n' Text
+
+';; name (zone alloation) + name_h (heap allocation)' Comment.Single
+'\n' Text
+
+';; and a default print poly' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'data-constructor-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'v1' Name.Variable
+' ' Text
+'(' Punctuation
+'vec3' Name.Variable
+' ' Text
+'1.0' Literal.Number.Float
+' ' Text
+'2.0' Literal.Number.Float
+' ' Text
+'3.0' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'v2' Name.Variable
+' ' Text
+'(' Punctuation
+'vec3_h' Name.Variable
+' ' Text
+'4.0' Literal.Number.Float
+' ' Text
+'5.0' Literal.Number.Float
+' ' Text
+'6.0' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'println' Name.Function
+' ' Text
+'v1' Name.Variable
+' ' Text
+'v2' Name.Variable
+')' Punctuation
+'\n ' Text
+';; halloced vec3 needs freeing' Comment.Single
+'\n ' Text
+'(' Punctuation
+'free' Name.Function
+' ' Text
+'v2' Name.Variable
+')' Punctuation
+'\n ' Text
+'void' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'data-constructor-test' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; aref-ptr and tref-ptr' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n\n' Text
+
+';; aref-ptr and tref-ptr return a pointer to an element' Comment.Single
+'\n' Text
+
+';; just as aref and tref return elements aref-ptr and' Comment.Single
+'\n' Text
+
+';; tref-ptr return a pointer to those elements.' Comment.Single
+'\n\n' Text
+
+';; This allows you to do things like create an array' Comment.Single
+'\n' Text
+
+';; with an offset' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'aref-ptr-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'arr' Name.Variable
+':|32,i64|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'arroff' Name.Variable
+' ' Text
+'(' Punctuation
+'aref-ptr' Name.Function
+' ' Text
+'arr' Name.Variable
+' ' Text
+'16' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'k' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+';; load arr' Comment.Single
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'32' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'arr' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'k' Name.Variable
+' ' Text
+'16' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"index: %lld\\tarr: %lld\\tarroff: %lld\\n"' Literal.String
+'\n ' Text
+'k' Name.Variable
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'arr' Name.Variable
+' ' Text
+'k' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'pref' Name.Function
+' ' Text
+'arroff' Name.Variable
+' ' Text
+'k' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'aref-ptr-test' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; arrays' Comment.Single
+'\n' Text
+
+';; Extempore lang supports arrays as for first class' Comment.Single
+'\n' Text
+
+';; aggregate types (in other words as distinct from' Comment.Single
+'\n' Text
+
+';; a pointer).' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; an array is made up of a size and a type' Comment.Single
+'\n' Text
+
+';; |32,i64| is an array of 32 elements of type i64' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-type' Keyword
+' ' Text
+'tuple-with-array' Name.Function
+' ' Text
+'<double,|32,|4,i32||,float>' Keyword.Type
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'array-test5' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'tup' Name.Variable
+':tuple-with-array*' Keyword.Type
+' ' Text
+'(' Punctuation
+'stack-alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'t2' Name.Variable
+':|32,i64|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'stack-alloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'t2' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'9' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tset!' Name.Function
+' ' Text
+'tup' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+' ' Text
+'5.5' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'(' Punctuation
+'aref-ptr' Name.Function
+' ' Text
+'(' Punctuation
+'tref-ptr' Name.Function
+' ' Text
+'tup' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'(' Punctuation
+'aref-ptr' Name.Function
+' ' Text
+'(' Punctuation
+'tref-ptr' Name.Function
+' ' Text
+'tup' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'(' Punctuation
+'aref-ptr' Name.Function
+' ' Text
+'(' Punctuation
+'tref-ptr' Name.Function
+' ' Text
+'tup' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'2' Literal.Number.Integer
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"val: %lld %lld %f\\n"' Literal.String
+'\n ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'(' Punctuation
+'aref-ptr' Name.Function
+' ' Text
+'(' Punctuation
+'tref-ptr' Name.Function
+' ' Text
+'tup' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'t2' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'tup' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'(' Punctuation
+'aref-ptr' Name.Function
+' ' Text
+'(' Punctuation
+'tref-ptr' Name.Function
+' ' Text
+'tup' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'array-test5' Name.Variable
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+';; val: 1 9 5.5' Comment.Single
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; Global Variables' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; You can allocate global variables using bind-val' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_var_a' Name.Function
+' ' Text
+'i32' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; increment g_var_a by inc' Comment.Single
+'\n' Text
+
+';; and return new value of g_var_a' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'global_var_test1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'incr' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'set!' Keyword
+' ' Text
+'g_var_a' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'g_var_a' Name.Variable
+' ' Text
+'incr' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'g_var_a' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'global_var_test1' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'8' Literal.Number.Integer
+')' Punctuation
+' ' Text
+';; 8' Comment.Single
+'\n\n' Text
+
+';; you can bind any primitive type' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_var_b' Name.Function
+' ' Text
+'double' Name.Variable
+' ' Text
+'5.5' Literal.Number.Float
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_var_c' Name.Function
+' ' Text
+'i1' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'global_var_test1b' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'g_var_b' Name.Variable
+' ' Text
+'(' Punctuation
+'if' Keyword
+' ' Text
+'g_var_c' Name.Variable
+' ' Text
+'1.0' Literal.Number.Float
+' ' Text
+'4.0' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'global_var_test1b' Name.Variable
+')' Punctuation
+' ' Text
+'22.0' Literal.Number.Float
+')' Punctuation
+'\n\n' Text
+
+';; global strings' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_cstring' Name.Function
+' ' Text
+'i8*' Keyword.Type
+' ' Text
+'"Jiblet."' Literal.String
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_g_cstring' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'7' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"g_cstring[%lld] = %c\\n"' Literal.String
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'pref' Name.Function
+' ' Text
+'g_cstring' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"\\nSpells... %s\\n"' Literal.String
+' ' Text
+'g_cstring' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_g_cstring' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_g_cstring1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'test_cstring' Name.Variable
+' ' Text
+'"Niblot."' Literal.String
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'total' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'7' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'c1' Name.Variable
+' ' Text
+'(' Punctuation
+'pref' Name.Function
+' ' Text
+'g_cstring' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'c2' Name.Variable
+' ' Text
+'(' Punctuation
+'pref' Name.Function
+' ' Text
+'test_cstring' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"checking %c against %c\\n"' Literal.String
+' ' Text
+'c1' Name.Variable
+' ' Text
+'c2' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'if' Keyword
+' ' Text
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'c1' Name.Variable
+' ' Text
+'c2' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'set!' Keyword
+' ' Text
+'total' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'total' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'total' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_g_cstring1' Name.Variable
+')' Punctuation
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+'\n\n\n\n\n\n' Text
+
+';; for tuples, arrays and vectors, bind-val only takes *two*' Comment.Single
+'\n' Text
+
+';; arguments. The tuple/array/vector will be initialised to zero.' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_tuple1' Name.Function
+' ' Text
+'<i64,i64>' Keyword.Type
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_tuple2' Name.Function
+' ' Text
+'<double,double>' Keyword.Type
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_g_tuple' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tfill!' Name.Function
+' ' Text
+'g_tuple1' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tfill!' Name.Function
+' ' Text
+'g_tuple2' Name.Variable
+' ' Text
+'4.0' Literal.Number.Float
+' ' Text
+'1.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'and' Keyword
+' ' Text
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'g_tuple1' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'dtoi64' Name.Variable
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'g_tuple2' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'(' Punctuation
+'dtoi64' Name.Variable
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'g_tuple2' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'g_tuple1' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_g_tuple' Name.Variable
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; same thing with arrays' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_array1' Name.Function
+' ' Text
+'|10,double|' Keyword.Type
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_array2' Name.Function
+' ' Text
+'|10,i64|' Keyword.Type
+')' Punctuation
+'\n\n' Text
+
+';; if we just loop over and print the values in each array' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_g_array11' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'10' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"garray_1[%lld] = %f garray_2[%lld] = %lld\\n"' Literal.String
+'\n ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'g_array1' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'g_array2' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_g_array11' Name.Variable
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+';; but if we loop over and set some values into the arrays' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_g_array2' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'10' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'g_array1' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'i64tod' Name.Function
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'g_array2' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"garray_1[%lld] = %f garray_2[%lld] = %lld\\n"' Literal.String
+'\n ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'g_array1' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'g_array2' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'(' Punctuation
+'dtoi64' Name.Variable
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'g_array1' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'g_array2' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_g_array2' Name.Variable
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+";; just to test, let's try a large array" Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_array3' Name.Function
+' ' Text
+'|100000000,i64|' Keyword.Type
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_g_array3' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'100000000' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'g_array3' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'=' Name.Function
+' ' Text
+'(' Punctuation
+'pref' Name.Function
+' ' Text
+'g_array3' Name.Variable
+' ' Text
+'87654321' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'87654321' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_g_array3' Name.Variable
+')' Punctuation
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+";; if you want to bind a global pointer, then the third 'value'" Comment.Single
+'\n' Text
+
+';; argument is the size of the memory to allocate (in elements, not in bytes)' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_ptr0' Name.Function
+' ' Text
+'double*' Keyword.Type
+' ' Text
+'10' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_g_ptr0' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'total' Name.Variable
+' ' Text
+'0.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'10' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'pset!' Name.Function
+' ' Text
+'g_ptr0' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'i64tod' Name.Function
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'set!' Keyword
+' ' Text
+'total' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'total' Name.Variable
+' ' Text
+'(' Punctuation
+'pref' Name.Function
+' ' Text
+'g_ptr0' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'total' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_g_ptr0' Name.Variable
+')' Punctuation
+' ' Text
+'45.0' Literal.Number.Float
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_ptr1' Name.Function
+' ' Text
+'|4,i32|*' Keyword.Type
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'g_ptr2' Name.Function
+' ' Text
+'<i64,double>*' Keyword.Type
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'test_g_ptr1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'afill!' Name.Function
+' ' Text
+'g_ptr1' Name.Variable
+' ' Text
+'11' Literal.Number.Integer
+' ' Text
+'66' Literal.Number.Integer
+' ' Text
+'35' Literal.Number.Integer
+' ' Text
+'81' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'tset!' Name.Function
+' ' Text
+'g_ptr2' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+' ' Text
+'35.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"%f :: %d\\n"' Literal.String
+' ' Text
+'(' Punctuation
+'tref' Name.Function
+' ' Text
+'g_ptr2' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'g_ptr1' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'g_ptr1' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'test_g_ptr1' Name.Variable
+')' Punctuation
+' ' Text
+'81' Literal.Number.Integer
+')' Punctuation
+' ' Text
+';; should also print 35.000000 :: 35' Comment.Single
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; Callbacks' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'callback-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'time' Name.Variable
+':i64' Keyword.Type
+' ' Text
+'count' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"time: %lld:%lld\\n"' Literal.String
+' ' Text
+'time' Name.Variable
+' ' Text
+'count' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'callback' Name.Function
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'time' Name.Variable
+' ' Text
+'1000' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'callback-test' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'time' Name.Variable
+' ' Text
+'22050' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'count' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'callback' Name.Function
+'-test' Name.Variable
+' ' Text
+'(' Punctuation
+'now' Name.Function
+')' Punctuation
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; compiling this will stop the callbacks' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; of course we need to keep the type' Comment.Single
+'\n' Text
+
+';; signature the same [void,i64,i64]*' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'callback-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'time' Name.Variable
+':i64' Keyword.Type
+' ' Text
+'count' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+'\n ' Text
+'#t' Name.Constant
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'callback' Name.Function
+'-test' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; some memzone tests' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'memzone-test1' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'b' Name.Variable
+':|5,double|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'zalloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+'\n ' Text
+'(' Punctuation
+'memzone' Keyword
+' ' Text
+'1024' Literal.Number.Integer
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'a' Name.Variable
+':|10,double|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'zalloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'3.5' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'c' Name.Variable
+':|9,i32|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'zalloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'c' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'99' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'memzone-test1' Name.Variable
+')' Punctuation
+' ' Text
+'3.5' Literal.Number.Float
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'memzone-test2' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'memzone' Keyword
+' ' Text
+'1024' Literal.Number.Integer
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'k' Name.Variable
+':|15,double|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'zalloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'fa' Name.Variable
+':|15,double|*' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'memzone' Keyword
+' ' Text
+'1024' Literal.Number.Integer
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'a' Name.Variable
+':|10,double|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'zalloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'10' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'fa' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'random' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'a' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f' Name.Variable
+' ' Text
+'k' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'memzone-test2' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'memzone-test3' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'v' Name.Variable
+' ' Text
+'(' Punctuation
+'memzone' Keyword
+'-test2' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'10' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"%lld:%f\\n"' Literal.String
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'v' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'memzone-test3' Name.Variable
+')' Punctuation
+')' Punctuation
+' ' Text
+";; should print all 0.0's" Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'memzone-test4' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'memzone' Keyword
+' ' Text
+'1024' Literal.Number.Integer
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'44100' Literal.Number.Integer
+' ' Text
+'10' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'a' Name.Variable
+':|5,double|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'5.5' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'memzone-test4' Name.Variable
+')' Punctuation
+' ' Text
+'5.50000' Literal.Number.Float
+')' Punctuation
+'\n\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; Large allocation of memory on BUILD (i.e. when the closure is created)' Comment.Single
+'\n' Text
+
+';; requires an optional argument (i.e. an amount of memory to allocate' Comment.Single
+'\n' Text
+
+';; specifically for closure creation)' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+";; This memory is automatically free'd whenever you recompile the closure" Comment.Single
+'\n' Text
+
+';; (it will be destroyed and replaced by a new allocation of the' Comment.Single
+'\n' Text
+
+';; same amount or whatever new amount you have allocated for closure' Comment.Single
+'\n' Text
+
+';; compilation)' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'closure-zalloc-test' Name.Function
+' ' Text
+'1000000' Literal.Number.Integer
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'k' Name.Variable
+':|100000,double|*' Keyword.Type
+' ' Text
+'(' Punctuation
+'zalloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aset!' Name.Function
+' ' Text
+'k' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+' ' Text
+'1.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'aref' Name.Function
+' ' Text
+'k' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'closure-zalloc-test' Name.Variable
+' ' Text
+'1000000' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; Ad-Hoc Polymorphism' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n\n' Text
+
+';; extempore supports ad-hoc polymorphism' Comment.Single
+'\n' Text
+
+';; at some stage in the future this will' Comment.Single
+'\n' Text
+
+';; be implicit - but for the moment' Comment.Single
+'\n' Text
+
+';; it is explicitly defined using bind-poly' Comment.Single
+'\n\n' Text
+
+';; ad-hoc polymorphism allows you to provide' Comment.Single
+'\n' Text
+
+';; different specialisations depending on' Comment.Single
+'\n' Text
+
+";; type. In other words, a single 'name'" Comment.Single
+'\n' Text
+
+';; can be bound to multiple function' Comment.Single
+'\n' Text
+
+';; implementations each with a uniqute' Comment.Single
+'\n' Text
+
+';; type.' Comment.Single
+'\n\n\n' Text
+
+';; poly variables can be for functions of' Comment.Single
+'\n' Text
+
+';; mixed argument lengths' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; so for example:' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'poly-test4' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+':i8*' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"%s\\n"' Literal.String
+' ' Text
+'a' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'poly-test5' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+':i8*' Keyword.Type
+' ' Text
+'b' Name.Variable
+':i8*' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"%s %s\\n"' Literal.String
+' ' Text
+'a' Name.Variable
+' ' Text
+'b' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'poly-test6' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+':i8*' Keyword.Type
+' ' Text
+'b' Name.Variable
+':i8*' Keyword.Type
+' ' Text
+'c' Name.Variable
+':i8*' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"%s %s %s\\n"' Literal.String
+' ' Text
+'a' Name.Variable
+' ' Text
+'b' Name.Variable
+' ' Text
+'c' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+";; bind these three functions to poly 'print'" Comment.Single
+'\n' Text
+
+'(' Punctuation
+'bind-poly' Keyword
+' ' Text
+'testprint' Name.Function
+' ' Text
+'poly-test4' Name.Variable
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-poly' Keyword
+' ' Text
+'testprint' Name.Function
+' ' Text
+'poly-test5' Name.Variable
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-poly' Keyword
+' ' Text
+'testprint' Name.Function
+' ' Text
+'poly-test6' Name.Variable
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'poly-test7' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'testprint' Name.Variable
+' ' Text
+'"extempore\'s"' Literal.String
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'testprint' Name.Variable
+' ' Text
+'"extempore\'s"' Literal.String
+' ' Text
+'"polymorphism"' Literal.String
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'testprint' Name.Variable
+' ' Text
+'"extempore\'s"' Literal.String
+' ' Text
+'"polymorphism"' Literal.String
+' ' Text
+'"rocks"' Literal.String
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'poly-test7' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; polys can Also specialize' Comment.Single
+'\n' Text
+
+';; on the return type' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'poly-test8' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+':double' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'a' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'poly-test9' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+':double' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dtoi64' Name.Variable
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'a' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-poly' Keyword
+' ' Text
+'sqrd' Name.Function
+' ' Text
+'poly-test8' Name.Variable
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-poly' Keyword
+' ' Text
+'sqrd' Name.Function
+' ' Text
+'poly-test9' Name.Variable
+')' Punctuation
+'\n\n' Text
+
+';; specialize on [i64,double]*' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'poly-test10' Name.Function
+':[i64,double]*' Keyword.Type
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'1' Literal.Number.Integer
+' ' Text
+'(' Punctuation
+'sqrd' Name.Variable
+' ' Text
+'a' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'poly-test10' Name.Variable
+' ' Text
+'5.0' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; specialize on [double,doube]*' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'poly-test11' Name.Function
+':[double,double]*' Keyword.Type
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'1.0' Literal.Number.Float
+' ' Text
+'(' Punctuation
+'sqrd' Name.Variable
+' ' Text
+'a' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'poly-test11' Name.Variable
+' ' Text
+'5.0' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+'\n\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; a little test for zone cleanup' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'MyLittleCleanupTest' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'tmp2' Name.Variable
+':i8*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+' ' Text
+'8' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'cleanup' Name.Variable
+' ' Text
+'(' Punctuation
+'println' Name.Function
+' ' Text
+'"Clean up before leaving zone!"' Literal.String
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'tmp2' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'cleanup-test' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'letz' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'tmp' Name.Variable
+':i8*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+' ' Text
+'8' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'t2' Name.Variable
+' ' Text
+'(' Punctuation
+'MyLittleCleanupTest' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'begin' Keyword
+'\n ' Text
+'(' Punctuation
+'println' Name.Function
+' ' Text
+'"In Zone ..."' Literal.String
+')' Punctuation
+'\n ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'println' Name.Function
+' ' Text
+'"Out of zone ..."' Literal.String
+')' Punctuation
+'\n ' Text
+'void' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'cleanup-test' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';; vector types' Comment.Single
+'\n\n' Text
+
+';; (bind-func vector-test1' Comment.Single
+'\n' Text
+
+';; (lambda ()' Comment.Single
+'\n' Text
+
+';; (let ((v1:/4,float/* (alloc))' Comment.Single
+'\n' Text
+
+';; \t (v2:/4,float/* (alloc))' Comment.Single
+'\n' Text
+
+';; \t (v3:/4,float/* (alloc)))' Comment.Single
+'\n' Text
+
+';; (vfill! v1 4.0 3.0 2.0 1.0)' Comment.Single
+'\n' Text
+
+';; (vfill! v2 1.0 2.0 3.0 4.0)' Comment.Single
+'\n' Text
+
+';; (vfill! v3 5.0 5.0 5.0 5.0)' Comment.Single
+'\n' Text
+
+';; (let ((v4 (* v1 v2))' Comment.Single
+'\n' Text
+
+";; \t (v5 (> v3 v4))) ;; unforunately vector conditionals don't work!" Comment.Single
+'\n' Text
+
+';; \t(printf "mul:%f:%f:%f:%f\\n" (ftod (vref v4 0)) (ftod (vref v4 1)) (ftod (vref v4 2)) (ftod (vref v4 3)))' Comment.Single
+'\n' Text
+
+';; \t(printf "cmp:%d:%d:%d:%d\\n" (i1toi32 (vref v5 0)) (i1toi32 (vref v5 1)) (i1toi32 (vref v5 2)) (i1toi32 (vref v5 3)))' Comment.Single
+'\n' Text
+
+';; \tvoid))))' Comment.Single
+'\n\n' Text
+
+';; (test-xtfunc (vector-test1))' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'vector-test2' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'v1' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n\t ' Text
+'(' Punctuation
+'v2' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'vfill!' Name.Function
+' ' Text
+'v1' Name.Variable
+' ' Text
+'1.0' Literal.Number.Float
+' ' Text
+'2.0' Literal.Number.Float
+' ' Text
+'4.0' Literal.Number.Float
+' ' Text
+'8.0' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'vfill!' Name.Function
+' ' Text
+'v2' Name.Variable
+' ' Text
+'2.0' Literal.Number.Float
+' ' Text
+'2.5' Literal.Number.Float
+' ' Text
+'2.25' Literal.Number.Float
+' ' Text
+'2.125' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'v1' Name.Variable
+' ' Text
+'v2' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'vector-test3' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'a' Name.Variable
+' ' Text
+'(' Punctuation
+'vector-test2' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"%f:%f:%f:%f\\n"' Literal.String
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'void' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'vector' Name.Function
+'-test3' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; vectorised sine func' Comment.Single
+'\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'vsinf4' Name.Function
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'p' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'b' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'c' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f1' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'f2' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'i' Name.Variable
+':i32' Keyword.Type
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'p_' Name.Variable
+' ' Text
+'0.225' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'b_' Name.Variable
+' ' Text
+'(' Punctuation
+'dtof' Name.Function
+' ' Text
+'(' Punctuation
+'/' Name.Function
+' ' Text
+'4.0' Literal.Number.Float
+' ' Text
+'3.1415' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'c_' Name.Variable
+' ' Text
+'(' Punctuation
+'dtof' Name.Function
+' ' Text
+'(' Punctuation
+'/' Name.Function
+' ' Text
+'-4.0' Literal.Number.Float
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'3.1415' Literal.Number.Float
+' ' Text
+'3.1415' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'p' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'p_' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'b_' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'c' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'c_' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+':/4,float/' Keyword.Type
+')' Punctuation
+'\n ' Text
+';; no SIMD for abs yet!' Comment.Single
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'f1' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'fabs' Name.Variable
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'y' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'x' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'c' Name.Variable
+' ' Text
+'x' Name.Variable
+' ' Text
+'f1' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+';; no SIMD for abs yet!' Comment.Single
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'f2' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'fabs' Name.Variable
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'y' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'p' Name.Variable
+' ' Text
+'(' Punctuation
+'-' Name.Function
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'y' Name.Variable
+' ' Text
+'f2' Name.Variable
+')' Punctuation
+' ' Text
+'y' Name.Variable
+')' Punctuation
+')' Punctuation
+' ' Text
+'y' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'vcosf4' Name.Function
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'p' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'b' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'c' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'d' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'f1' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'f2' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'i' Name.Variable
+':i32' Keyword.Type
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'p_' Name.Variable
+' ' Text
+'0.225' Literal.Number.Float
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'d_' Name.Variable
+' ' Text
+'(' Punctuation
+'dtof' Name.Function
+' ' Text
+'(' Punctuation
+'/' Name.Function
+' ' Text
+'3.1415' Literal.Number.Float
+' ' Text
+'2.0' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'b_' Name.Variable
+' ' Text
+'(' Punctuation
+'dtof' Name.Function
+' ' Text
+'(' Punctuation
+'/' Name.Function
+' ' Text
+'4.0' Literal.Number.Float
+' ' Text
+'3.1415' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'c_' Name.Variable
+' ' Text
+'(' Punctuation
+'dtof' Name.Function
+' ' Text
+'(' Punctuation
+'/' Name.Function
+' ' Text
+'-4.0' Literal.Number.Float
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'3.1415' Literal.Number.Float
+' ' Text
+'3.1415' Literal.Number.Float
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'p' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'p_' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'b_' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'c' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'c_' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'d' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'d_' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+':/4,float/' Keyword.Type
+')' Punctuation
+'\n ' Text
+';; offset x for cos' Comment.Single
+'\n ' Text
+'(' Punctuation
+'set!' Keyword
+' ' Text
+'x' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'d' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n ' Text
+';; no SIMD for abs yet!' Comment.Single
+'\n ' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'f1' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'fabs' Name.Variable
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'y' Name.Variable
+' ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'x' Name.Variable
+')' Punctuation
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'c' Name.Variable
+' ' Text
+'x' Name.Variable
+' ' Text
+'f1' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+';; no SIMD for abs yet!' Comment.Single
+'\n\t' Text
+'(' Punctuation
+'dotimes' Keyword
+' ' Text
+'(' Punctuation
+'i' Name.Variable
+' ' Text
+'4' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'vset!' Name.Function
+' ' Text
+'f2' Name.Variable
+' ' Text
+'i' Name.Variable
+' ' Text
+'(' Punctuation
+'fabs' Name.Variable
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'y' Name.Variable
+' ' Text
+'i' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\t' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'p' Name.Variable
+' ' Text
+'(' Punctuation
+'-' Name.Function
+' ' Text
+'(' Punctuation
+'*' Name.Function
+' ' Text
+'y' Name.Variable
+' ' Text
+'f2' Name.Variable
+')' Punctuation
+' ' Text
+'y' Name.Variable
+')' Punctuation
+')' Punctuation
+' ' Text
+'y' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'vector-test4' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'a' Name.Variable
+':/4,float/*' Keyword.Type
+' ' Text
+'(' Punctuation
+'alloc' Name.Function
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'vfill!' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0.1' Literal.Number.Float
+' ' Text
+'0.2' Literal.Number.Float
+' ' Text
+'0.3' Literal.Number.Float
+' ' Text
+'0.4' Literal.Number.Float
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'b' Name.Variable
+' ' Text
+'(' Punctuation
+'vsinf4' Name.Variable
+' ' Text
+'(' Punctuation
+'pref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'c' Name.Variable
+' ' Text
+'(' Punctuation
+'vcosf4' Name.Variable
+' ' Text
+'(' Punctuation
+'pref' Name.Function
+' ' Text
+'a' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"precision inaccuracy is expected:\\n"' Literal.String
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'" sinf:\\t%f,%f,%f,%f\\n"' Literal.String
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'sin' Name.Function
+' ' Text
+'0.1' Literal.Number.Float
+':f' Keyword.Type
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'sin' Name.Function
+' ' Text
+'0.2' Literal.Number.Float
+':f' Keyword.Type
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'sin' Name.Function
+' ' Text
+'0.3' Literal.Number.Float
+':f' Keyword.Type
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'sin' Name.Function
+' ' Text
+'0.4' Literal.Number.Float
+':f' Keyword.Type
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"vsinf:\\t%f,%f,%f,%f\\n"' Literal.String
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'b' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'" cosf:\\t%f,%f,%f,%f\\n"' Literal.String
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'cos' Name.Function
+' ' Text
+'0.1' Literal.Number.Float
+':f' Keyword.Type
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'cos' Name.Function
+' ' Text
+'0.2' Literal.Number.Float
+':f' Keyword.Type
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'cos' Name.Function
+' ' Text
+'0.3' Literal.Number.Float
+':f' Keyword.Type
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'cos' Name.Function
+' ' Text
+'0.4' Literal.Number.Float
+':f' Keyword.Type
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"vcosf:\\t%f,%f,%f,%f\\n"' Literal.String
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'c' Name.Variable
+' ' Text
+'0' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'c' Name.Variable
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'c' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ftod' Name.Function
+' ' Text
+'(' Punctuation
+'vref' Name.Function
+' ' Text
+'c' Name.Variable
+' ' Text
+'3' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'void' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n ' Text
+'(' Punctuation
+'vector' Name.Function
+'-test4' Name.Variable
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; test the call-as-xtlang macro' Comment.Single
+'\n\n' Text
+
+";; make sure it'll handle multiple body forms" Comment.Single
+'\n' Text
+
+'(' Punctuation
+'xtmtest-result' Name.Variable
+' ' Text
+'(' Punctuation
+'call-as-xtlang' Name.Variable
+' ' Text
+'(' Punctuation
+'println' Name.Function
+' ' Text
+'1' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'(' Punctuation
+'println' Name.Function
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+'\n ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+'\n\n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';; test globalvar as closure' Comment.Single
+'\n' Text
+
+';;' Comment.Single
+'\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'testinc' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'incr' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'x' Name.Variable
+':i64' Keyword.Type
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'+' Name.Function
+' ' Text
+'x' Name.Variable
+' ' Text
+'incr' Name.Variable
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'GlobalInc' Name.Function
+' ' Text
+'[i64,i64]*' Keyword.Type
+' ' Text
+'(' Punctuation
+'testinc' Name.Variable
+' ' Text
+'2' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'xtmtest' Name.Variable
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'ginc' Name.Function
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'GlobalInc' Name.Variable
+' ' Text
+'5' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'ginc' Name.Variable
+')' Punctuation
+' ' Text
+'7' Literal.Number.Integer
+')' Punctuation
+'\n \n\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+';; syntax highlighting tests ;;' Comment.Single
+'\n' Text
+
+';;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;' Comment.Single
+'\n' Text
+
+";; these don't return any values, they're visual tests---do they look" Comment.Single
+'\n' Text
+
+';; right?' Comment.Single
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'hl_test1a' Name.Function
+':[i32,double,|4,i32|**]*' Keyword.Type
+' ' Text
+'4000' Literal.Number.Integer
+'\n ' Text
+'"docstring"' Literal.String
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+'a' Name.Variable
+' ' Text
+'b' Name.Variable
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"done\\n"' Literal.String
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-func' Keyword
+' ' Text
+'hl_test1b' Name.Function
+':[i32]*' Keyword.Type
+'\n ' Text
+'(' Punctuation
+'lambda' Keyword
+' ' Text
+'(' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'let' Keyword
+' ' Text
+'(' Punctuation
+'(' Punctuation
+'i' Name.Variable
+':i32' Keyword.Type
+' ' Text
+'6' Literal.Number.Integer
+')' Punctuation
+')' Punctuation
+'\n ' Text
+'(' Punctuation
+'printf' Name.Function
+' ' Text
+'"done\\n"' Literal.String
+')' Punctuation
+')' Punctuation
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'hl_test2' Name.Function
+' ' Text
+'<i32,i32>' Keyword.Type
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'hl_test3' Name.Function
+' ' Text
+'|4,i8|' Keyword.Type
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'hl_test4' Name.Function
+' ' Text
+'double*' Keyword.Type
+' ' Text
+'10' Literal.Number.Integer
+')' Punctuation
+'\n' Text
+
+'(' Punctuation
+'bind-val' Keyword
+' ' Text
+'hl_test5' Name.Function
+' ' Text
+'i8*' Keyword.Type
+' ' Text
+'"teststr"' Literal.String
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'bind-type' Keyword
+' ' Text
+'hl_test_type' Name.Function
+' ' Text
+'<i64>' Keyword.Type
+')' Punctuation
+'\n\n' Text
+
+'(' Punctuation
+'println' Name.Function
+' ' Text
+"'" Operator
+'(' Punctuation
+'bind-lib' Keyword
+' ' Text
+'testlib' Name.Function
+' ' Text
+'testfn' Name.Variable
+' ' Text
+'[i32,i32]*' Keyword.Type
+')' Punctuation
+')' Punctuation
+'\n\n' Text
+
+';; (and 4 5)' Comment.Single
+'\n' Text
+
+';; (bind-val hl_test4 double* 10)' Comment.Single
+'\n' Text
+
+';; (bind-type hl_test_type <i64> "docstring")' Comment.Single
+'\n' Text
+
+';; (bind-lib testlib testfn [i32,i32]*)' Comment.Single
+'\n' Text