digego / extempore

A cyber-physical programming environment
1.41k stars 127 forks source link

mcjit windows bug?? #298

Open digego opened 7 years ago

digego commented 7 years ago

(bind-type Shape <i64,<double,double,double,double>*>)

(bind-func success_rect (lambda (w:double x:double y:double z:double) (println "success:" w x y z) w))

(bind-func fail_rect (lambda () (println "fail!") 0.0))

(bind-func test_rect:[double,Shape,[double,double,double,double,double],[double]] (lambda (obj success fail) (if (= (tref obj 0) 2) (let ((cir (tref obj 1))) (success (tref cir 0) (tref cir 1) (tref cir 2) (tref cir 3))) (fail))))

(bind-func test (lambda () (let ((s (Shape 2 (tuple_ref 1.0 2.0 3.0 4.0)))) (test_rect s success_rect fail_rect) void)))

(test)