(guard (e (#t #f))
  (def-var! "jolt.ir" "const" (letrec ((const (lambda (v) (let fnrec3502 ((v v)) (let* ((_o$3503 (keyword #f "op")) (_o$3504 (keyword #f "const")) (_o$3505 (keyword #f "val")) (_o$3506 v)) (jolt-hash-map _o$3503 _o$3504 _o$3505 _o$3506)))))) const)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "local" (letrec ((local (lambda (name) (let fnrec3507 ((name name)) (let* ((_o$3508 (keyword #f "op")) (_o$3509 (keyword #f "local")) (_o$3510 (keyword #f "name")) (_o$3511 name)) (jolt-hash-map _o$3508 _o$3509 _o$3510 _o$3511)))))) local)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "var-ref" (letrec ((var-ref (lambda (ns name) (let fnrec3512 ((ns ns) (name name)) (let* ((_o$3513 (keyword #f "op")) (_o$3514 (keyword #f "var")) (_o$3515 (keyword #f "ns")) (_o$3516 ns) (_o$3517 (keyword #f "name")) (_o$3518 name)) (jolt-hash-map _o$3513 _o$3514 _o$3515 _o$3516 _o$3517 _o$3518)))))) var-ref)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "the-var" (letrec ((the-var (lambda (ns name) (let fnrec3519 ((ns ns) (name name)) (let* ((_o$3520 (keyword #f "op")) (_o$3521 (keyword #f "the-var")) (_o$3522 (keyword #f "ns")) (_o$3523 ns) (_o$3524 (keyword #f "name")) (_o$3525 name)) (jolt-hash-map _o$3520 _o$3521 _o$3522 _o$3523 _o$3524 _o$3525)))))) the-var)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "rt" (letrec ((rt (lambda (name) (let fnrec3526 ((name name)) (let* ((_o$3527 (keyword #f "op")) (_o$3528 (keyword #f "rt")) (_o$3529 (keyword #f "name")) (_o$3530 name)) (jolt-hash-map _o$3527 _o$3528 _o$3529 _o$3530)))))) rt)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "host-ref" (letrec ((host-ref (lambda (name) (let fnrec3531 ((name name)) (let* ((_o$3532 (keyword #f "op")) (_o$3533 (keyword #f "host")) (_o$3534 (keyword #f "name")) (_o$3535 name)) (jolt-hash-map _o$3532 _o$3533 _o$3534 _o$3535)))))) host-ref)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "host-static" (letrec ((host-static (lambda (class member) (let fnrec3536 ((class class) (member member)) (let* ((_o$3537 (keyword #f "op")) (_o$3538 (keyword #f "host-static")) (_o$3539 (keyword #f "class")) (_o$3540 class) (_o$3541 (keyword #f "member")) (_o$3542 member)) (jolt-hash-map _o$3537 _o$3538 _o$3539 _o$3540 _o$3541 _o$3542)))))) host-static)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "host-new" (letrec ((host-new (lambda (class args) (let fnrec3543 ((class class) (args args)) (let* ((_o$3544 (keyword #f "op")) (_o$3545 (keyword #f "host-new")) (_o$3546 (keyword #f "class")) (_o$3547 class) (_o$3548 (keyword #f "args")) (_o$3549 args)) (jolt-hash-map _o$3544 _o$3545 _o$3546 _o$3547 _o$3548 _o$3549)))))) host-new)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "if-node" (letrec ((if-node (lambda (test then _else) (let fnrec3550 ((test test) (then then) (_else _else)) (let* ((_o$3551 (keyword #f "op")) (_o$3552 (keyword #f "if")) (_o$3553 (keyword #f "test")) (_o$3554 test) (_o$3555 (keyword #f "then")) (_o$3556 then) (_o$3557 (keyword #f "else")) (_o$3558 _else)) (jolt-hash-map _o$3551 _o$3552 _o$3553 _o$3554 _o$3555 _o$3556 _o$3557 _o$3558)))))) if-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "do-node" (letrec ((do-node (lambda (statements ret) (let fnrec3559 ((statements statements) (ret ret)) (let* ((_o$3560 (keyword #f "op")) (_o$3561 (keyword #f "do")) (_o$3562 (keyword #f "statements")) (_o$3563 statements) (_o$3564 (keyword #f "ret")) (_o$3565 ret)) (jolt-hash-map _o$3560 _o$3561 _o$3562 _o$3563 _o$3564 _o$3565)))))) do-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "invoke" (letrec ((invoke (lambda (f args) (let fnrec3566 ((f f) (args args)) (let* ((_o$3567 (keyword #f "op")) (_o$3568 (keyword #f "invoke")) (_o$3569 (keyword #f "fn")) (_o$3570 f) (_o$3571 (keyword #f "args")) (_o$3572 args)) (jolt-hash-map _o$3567 _o$3568 _o$3569 _o$3570 _o$3571 _o$3572)))))) invoke)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "def-node" (letrec ((def-node (case-lambda ((ns name init) (let fnrec3573 ((ns ns) (name name) (init init)) (let* ((_o$3574 (keyword #f "op")) (_o$3575 (keyword #f "def")) (_o$3576 (keyword #f "ns")) (_o$3577 ns) (_o$3578 (keyword #f "name")) (_o$3579 name) (_o$3580 (keyword #f "init")) (_o$3581 init)) (jolt-hash-map _o$3574 _o$3575 _o$3576 _o$3577 _o$3578 _o$3579 _o$3580 _o$3581)))) ((ns name init meta) (let fnrec3582 ((ns ns) (name name) (init init) (meta meta)) (if (jolt-truthy? meta) (let* ((_o$3583 (keyword #f "op")) (_o$3584 (keyword #f "def")) (_o$3585 (keyword #f "ns")) (_o$3586 ns) (_o$3587 (keyword #f "name")) (_o$3588 name) (_o$3589 (keyword #f "init")) (_o$3590 init) (_o$3591 (keyword #f "meta")) (_o$3592 meta)) (jolt-hash-map _o$3583 _o$3584 _o$3585 _o$3586 _o$3587 _o$3588 _o$3589 _o$3590 _o$3591 _o$3592)) (let* ((_o$3593 (keyword #f "op")) (_o$3594 (keyword #f "def")) (_o$3595 (keyword #f "ns")) (_o$3596 ns) (_o$3597 (keyword #f "name")) (_o$3598 name) (_o$3599 (keyword #f "init")) (_o$3600 init)) (jolt-hash-map _o$3593 _o$3594 _o$3595 _o$3596 _o$3597 _o$3598 _o$3599 _o$3600)))))))) def-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "let-node" (letrec ((let-node (lambda (bindings body) (let fnrec3601 ((bindings bindings) (body body)) (let* ((_o$3602 (keyword #f "op")) (_o$3603 (keyword #f "let")) (_o$3604 (keyword #f "bindings")) (_o$3605 bindings) (_o$3606 (keyword #f "body")) (_o$3607 body)) (jolt-hash-map _o$3602 _o$3603 _o$3604 _o$3605 _o$3606 _o$3607)))))) let-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "fn-node" (letrec ((fn-node (lambda (name arities) (let fnrec3608 ((name name) (arities arities)) (if (jolt-truthy? name) (let* ((_o$3609 (keyword #f "op")) (_o$3610 (keyword #f "fn")) (_o$3611 (keyword #f "name")) (_o$3612 name) (_o$3613 (keyword #f "arities")) (_o$3614 arities)) (jolt-hash-map _o$3609 _o$3610 _o$3611 _o$3612 _o$3613 _o$3614)) (let* ((_o$3615 (keyword #f "op")) (_o$3616 (keyword #f "fn")) (_o$3617 (keyword #f "arities")) (_o$3618 arities)) (jolt-hash-map _o$3615 _o$3616 _o$3617 _o$3618))))))) fn-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "vector-node" (letrec ((vector-node (lambda (items) (let fnrec3619 ((items items)) (let* ((_o$3620 (keyword #f "op")) (_o$3621 (keyword #f "vector")) (_o$3622 (keyword #f "items")) (_o$3623 items)) (jolt-hash-map _o$3620 _o$3621 _o$3622 _o$3623)))))) vector-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "map-node" (letrec ((map-node (lambda (pairs) (let fnrec3624 ((pairs pairs)) (let* ((_o$3625 (keyword #f "op")) (_o$3626 (keyword #f "map")) (_o$3627 (keyword #f "pairs")) (_o$3628 pairs)) (jolt-hash-map _o$3625 _o$3626 _o$3627 _o$3628)))))) map-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "set-node" (letrec ((set-node (lambda (items) (let fnrec3629 ((items items)) (let* ((_o$3630 (keyword #f "op")) (_o$3631 (keyword #f "set")) (_o$3632 (keyword #f "items")) (_o$3633 items)) (jolt-hash-map _o$3630 _o$3631 _o$3632 _o$3633)))))) set-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "quote-node" (letrec ((quote-node (lambda (form) (let fnrec3634 ((form form)) (let* ((_o$3635 (keyword #f "op")) (_o$3636 (keyword #f "quote")) (_o$3637 (keyword #f "form")) (_o$3638 form)) (jolt-hash-map _o$3635 _o$3636 _o$3637 _o$3638)))))) quote-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "throw-node" (letrec ((throw-node (lambda (expr) (let fnrec3639 ((expr expr)) (let* ((_o$3640 (keyword #f "op")) (_o$3641 (keyword #f "throw")) (_o$3642 (keyword #f "expr")) (_o$3643 expr)) (jolt-hash-map _o$3640 _o$3641 _o$3642 _o$3643)))))) throw-node)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "op" (letrec ((op (lambda (node) (let fnrec3644 ((node node)) (jolt-get node (keyword #f "op")))))) op)))
(guard (e (#t #f))
  (def-var! "jolt.ir" "map-ir-children" (letrec ((map-ir-children (lambda (f node) (let fnrec3645 ((f f) (node node)) (let* ((op (jolt-get node (keyword #f "op")))) (if (jolt= op (keyword #f "if")) (let* ((_a$3646 node) (_a$3647 (keyword #f "test")) (_a$3648 (jolt-invoke f (jolt-get node (keyword #f "test")))) (_a$3649 (keyword #f "then")) (_a$3650 (jolt-invoke f (jolt-get node (keyword #f "then")))) (_a$3651 (keyword #f "else")) (_a$3652 (jolt-invoke f (jolt-get node (keyword #f "else"))))) (jolt-assoc _a$3646 _a$3647 _a$3648 _a$3649 _a$3650 _a$3651 _a$3652)) (if (jolt= op (keyword #f "do")) (let* ((_a$3653 node) (_a$3654 (keyword #f "statements")) (_a$3655 (jolt-invoke (var-deref "clojure.core" "mapv") f (jolt-get node (keyword #f "statements")))) (_a$3656 (keyword #f "ret")) (_a$3657 (jolt-invoke f (jolt-get node (keyword #f "ret"))))) (jolt-assoc _a$3653 _a$3654 _a$3655 _a$3656 _a$3657)) (if (jolt= op (keyword #f "throw")) (jolt-assoc node (keyword #f "expr") (jolt-invoke f (jolt-get node (keyword #f "expr")))) (if (jolt= op (keyword #f "set-var")) (jolt-assoc node (keyword #f "val") (jolt-invoke f (jolt-get node (keyword #f "val")))) (if (jolt= op (keyword #f "set-field")) (let* ((_a$3658 node) (_a$3659 (keyword #f "obj")) (_a$3660 (jolt-invoke f (jolt-get node (keyword #f "obj")))) (_a$3661 (keyword #f "val")) (_a$3662 (jolt-invoke f (jolt-get node (keyword #f "val"))))) (jolt-assoc _a$3658 _a$3659 _a$3660 _a$3661 _a$3662)) (if (jolt= op (keyword #f "defmacro")) (jolt-assoc node (keyword #f "fn") (jolt-invoke f (jolt-get node (keyword #f "fn")))) (if (jolt= op (keyword #f "invoke")) (let* ((_a$3663 node) (_a$3664 (keyword #f "fn")) (_a$3665 (jolt-invoke f (jolt-get node (keyword #f "fn")))) (_a$3666 (keyword #f "args")) (_a$3667 (jolt-invoke (var-deref "clojure.core" "mapv") f (jolt-get node (keyword #f "args"))))) (jolt-assoc _a$3663 _a$3664 _a$3665 _a$3666 _a$3667)) (if (jolt= op (keyword #f "vector")) (jolt-assoc node (keyword #f "items") (jolt-invoke (var-deref "clojure.core" "mapv") f (jolt-get node (keyword #f "items")))) (if (jolt= op (keyword #f "set")) (jolt-assoc node (keyword #f "items") (jolt-invoke (var-deref "clojure.core" "mapv") f (jolt-get node (keyword #f "items")))) (if (jolt= op (keyword #f "map")) (jolt-assoc node (keyword #f "pairs") (let* ((_a$3671 (var-deref "clojure.core" "mapv")) (_a$3672 (lambda (pr) (let fnrec3668 ((pr pr)) (let* ((_o$3669 (jolt-invoke f (jolt-nth pr 0))) (_o$3670 (jolt-invoke f (jolt-nth pr 1)))) (jolt-vector _o$3669 _o$3670))))) (_a$3673 (jolt-get node (keyword #f "pairs")))) (jolt-invoke _a$3671 _a$3672 _a$3673))) (if (jolt= op (keyword #f "let")) (let* ((_a$3680 node) (_a$3681 (keyword #f "bindings")) (_a$3682 (let* ((_a$3677 (var-deref "clojure.core" "mapv")) (_a$3678 (lambda (b) (let fnrec3674 ((b b)) (let* ((_o$3675 (jolt-nth b 0)) (_o$3676 (jolt-invoke f (jolt-nth b 1)))) (jolt-vector _o$3675 _o$3676))))) (_a$3679 (jolt-get node (keyword #f "bindings")))) (jolt-invoke _a$3677 _a$3678 _a$3679))) (_a$3683 (keyword #f "body")) (_a$3684 (jolt-invoke f (jolt-get node (keyword #f "body"))))) (jolt-assoc _a$3680 _a$3681 _a$3682 _a$3683 _a$3684)) (if (jolt= op (keyword #f "loop")) (let* ((_a$3691 node) (_a$3692 (keyword #f "bindings")) (_a$3693 (let* ((_a$3688 (var-deref "clojure.core" "mapv")) (_a$3689 (lambda (b) (let fnrec3685 ((b b)) (let* ((_o$3686 (jolt-nth b 0)) (_o$3687 (jolt-invoke f (jolt-nth b 1)))) (jolt-vector _o$3686 _o$3687))))) (_a$3690 (jolt-get node (keyword #f "bindings")))) (jolt-invoke _a$3688 _a$3689 _a$3690))) (_a$3694 (keyword #f "body")) (_a$3695 (jolt-invoke f (jolt-get node (keyword #f "body"))))) (jolt-assoc _a$3691 _a$3692 _a$3693 _a$3694 _a$3695)) (if (jolt= op (keyword #f "recur")) (jolt-assoc node (keyword #f "args") (jolt-invoke (var-deref "clojure.core" "mapv") f (jolt-get node (keyword #f "args")))) (if (jolt= op (keyword #f "fn")) (jolt-assoc node (keyword #f "arities") (let* ((_a$3697 (var-deref "clojure.core" "mapv")) (_a$3698 (lambda (a) (let fnrec3696 ((a a)) (jolt-assoc a (keyword #f "body") (jolt-invoke f (jolt-get a (keyword #f "body"))))))) (_a$3699 (jolt-get node (keyword #f "arities")))) (jolt-invoke _a$3697 _a$3698 _a$3699))) (if (jolt= op (keyword #f "def")) (jolt-assoc node (keyword #f "init") (jolt-invoke f (jolt-get node (keyword #f "init")))) (if (jolt= op (keyword #f "host-call")) (let* ((_a$3700 node) (_a$3701 (keyword #f "target")) (_a$3702 (jolt-invoke f (jolt-get node (keyword #f "target")))) (_a$3703 (keyword #f "args")) (_a$3704 (jolt-invoke (var-deref "clojure.core" "mapv") f (jolt-get node (keyword #f "args"))))) (jolt-assoc _a$3700 _a$3701 _a$3702 _a$3703 _a$3704)) (if (jolt= op (keyword #f "host-new")) (jolt-assoc node (keyword #f "args") (jolt-invoke (var-deref "clojure.core" "mapv") f (jolt-get node (keyword #f "args")))) (if (jolt= op (keyword #f "try")) (let* ((n (jolt-assoc node (keyword #f "body") (jolt-invoke f (jolt-get node (keyword #f "body"))))) (n (if (jolt-truthy? (jolt-get node (keyword #f "catch-body"))) (jolt-assoc n (keyword #f "catch-body") (jolt-invoke f (jolt-get node (keyword #f "catch-body")))) n)) (n (if (jolt-truthy? (jolt-get node (keyword #f "finally"))) (jolt-assoc n (keyword #f "finally") (jolt-invoke f (jolt-get node (keyword #f "finally")))) n))) n) (if (jolt-truthy? (keyword #f "else")) node jolt-nil)))))))))))))))))))))))) map-ir-children)))
(guard (e (#t #f))
  (declare-var! "jolt.analyzer" "analyze"))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.analyzer" "handled" (let* ((_o$3705 "quote") (_o$3706 "if") (_o$3707 "do") (_o$3708 "def") (_o$3709 "fn*") (_o$3710 "let*") (_o$3711 "loop*") (_o$3712 "recur") (_o$3713 "throw") (_o$3714 "try") (_o$3715 "syntax-quote") (_o$3716 "var") (_o$3717 "letfn") (_o$3718 "set!") (_o$3719 "defmacro")) (jolt-hash-set _o$3705 _o$3706 _o$3707 _o$3708 _o$3709 _o$3710 _o$3711 _o$3712 _o$3713 _o$3714 _o$3715 _o$3716 _o$3717 _o$3718 _o$3719)) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "uncompilable" (letrec ((uncompilable (lambda (why) (let fnrec3720 ((why why)) (jolt-throw (jolt-invoke (var-deref "clojure.core" "str") "jolt/uncompilable: " why)))))) uncompilable)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.analyzer" "gensym-counter" (jolt-invoke (var-deref "clojure.core" "atom") 0) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "gen-name" (letrec ((gen-name (lambda (prefix) (let fnrec3721 ((prefix prefix)) (let* ((n (jolt-invoke (var-deref "clojure.core" "deref") (var-deref "jolt.analyzer" "gensym-counter")))) (begin (jolt-invoke (var-deref "clojure.core" "swap!") (var-deref "jolt.analyzer" "gensym-counter") jolt-inc) (jolt-invoke (var-deref "clojure.core" "str") "_r$" prefix n))))))) gen-name)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "empty-env" (letrec ((empty-env (lambda () (let fnrec3722 () (let* ((_o$3723 (keyword #f "locals")) (_o$3724 (jolt-hash-set)) (_o$3725 (keyword #f "hints")) (_o$3726 (jolt-hash-map))) (jolt-hash-map _o$3723 _o$3724 _o$3725 _o$3726)))))) empty-env)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "local?" (letrec ((local? (lambda (env nm) (let fnrec3727 ((env env) (nm nm)) (jolt-contains? (jolt-get env (keyword #f "locals")) nm))))) local?)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "add-locals" (letrec ((add-locals (lambda (env names) (let fnrec3728 ((env env) (names names)) (jolt-invoke (var-deref "clojure.core" "update") env (keyword #f "locals") (lambda (p__47_) (let fnrec3729 ((p__47_ p__47_)) (jolt-reduce jolt-conj p__47_ names)))))))) add-locals)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "with-recur" (letrec ((with-recur (lambda (env name) (let fnrec3730 ((env env) (name name)) (jolt-assoc env (keyword #f "recur") name))))) with-recur)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "hint-of" (letrec ((hint-of (lambda (ctx sym) (let fnrec3731 ((ctx ctx) (sym sym)) (let* ((m (jolt-invoke (var-deref "jolt.host" "form-sym-meta") sym))) (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "nil?") m)) jolt-nil (if (jolt-truthy? (jolt-get m (keyword #f "struct"))) (keyword #f "struct") (if (jolt-truthy? (keyword #f "else")) (let* ((t (jolt-get m (keyword #f "tag")))) (if (jolt-truthy? (let* ((and__13__auto t)) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.host" "record-type?") ctx t) and__13__auto))) (keyword #f "struct") jolt-nil)) jolt-nil)))))))) hint-of)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "add-hint" (letrec ((add-hint (lambda (env nm h) (let fnrec3732 ((env env) (nm nm) (h h)) (if (jolt-truthy? h) (jolt-assoc env (keyword #f "hints") (jolt-assoc (jolt-get env (keyword #f "hints")) nm h)) env))))) add-hint)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "phint-of" (letrec ((phint-of (lambda (ctx sym) (let fnrec3733 ((ctx ctx) (sym sym)) (let* ((m (jolt-invoke (var-deref "jolt.host" "form-sym-meta") sym))) (if (jolt-truthy? m) (let* ((t (jolt-get m (keyword #f "tag")))) (if (jolt-truthy? t) (jolt-invoke (var-deref "jolt.host" "record-ctor-key") ctx t) jolt-nil)) jolt-nil)))))) phint-of)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-seq" (letrec ((analyze-seq (lambda (ctx forms env) (let fnrec3734 ((ctx ctx) (forms forms) (env env)) (let* ((v (jolt-invoke (var-deref "clojure.core" "mapv") (lambda (p__48_) (let fnrec3735 ((p__48_ p__48_)) (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx p__48_ env))) forms)) (n (jolt-count v))) (if (jolt-zero? n) (jolt-invoke (var-deref "jolt.ir" "const") jolt-nil) (if (jolt= 1 n) (jolt-first v) (if (jolt-truthy? (keyword #f "else")) (let* ((_a$3736 (var-deref "jolt.ir" "do-node")) (_a$3737 (jolt-invoke (var-deref "clojure.core" "subvec") v 0 (jolt-dec n))) (_a$3738 (jolt-peek v))) (jolt-invoke _a$3736 _a$3737 _a$3738)) jolt-nil)))))))) analyze-seq)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-bindings" (letrec ((analyze-bindings (lambda (ctx bvec env) (let fnrec3739 ((ctx ctx) (bvec bvec) (env env)) (let* ((i 0) (env env) (pairs (jolt-vector))) (let loop3740 ((i i) (env env) (pairs pairs)) (if (< i (jolt-count bvec)) (let* ((bsym (jolt-nth bvec i))) (begin (if (jolt-not (jolt-invoke (var-deref "jolt.host" "form-sym?") bsym)) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "destructuring binding") jolt-nil) (let* ((nm (jolt-invoke (var-deref "jolt.host" "form-sym-name") bsym)) (init (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth bvec (jolt-inc i)) env))) (let* ((_a$3747 (+ i 2)) (_a$3748 (let* ((_a$3741 (var-deref "jolt.analyzer" "add-hint")) (_a$3742 (jolt-invoke (var-deref "jolt.analyzer" "add-locals") env (jolt-vector nm))) (_a$3743 nm) (_a$3744 (jolt-invoke (var-deref "jolt.analyzer" "hint-of") ctx bsym))) (jolt-invoke _a$3741 _a$3742 _a$3743 _a$3744))) (_a$3749 (jolt-conj pairs (let* ((_o$3745 nm) (_o$3746 init)) (jolt-vector _o$3745 _o$3746))))) (loop3740 _a$3747 _a$3748 _a$3749))))) (let* ((_o$3750 pairs) (_o$3751 env)) (jolt-vector _o$3750 _o$3751))))))))) analyze-bindings)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "parse-params" (letrec ((parse-params (lambda (ctx pvec) (let fnrec3752 ((ctx ctx) (pvec pvec)) (let* ((i 0) (fixed (jolt-vector)) (rest-name jolt-nil) (hints (jolt-vector)) (phints (jolt-vector))) (let loop3753 ((i i) (fixed fixed) (rest-name rest-name) (hints hints) (phints phints)) (if (< i (jolt-count pvec)) (let* ((p (jolt-nth pvec i))) (begin (if (jolt-not (jolt-invoke (var-deref "jolt.host" "form-sym?") p)) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "destructuring fn param") jolt-nil) (if (jolt= "&" (jolt-invoke (var-deref "jolt.host" "form-sym-name") p)) (let* ((r (jolt-nth pvec (jolt-inc i)))) (begin (if (jolt-not (jolt-invoke (var-deref "jolt.host" "form-sym?") r)) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "destructuring fn rest") jolt-nil) (let* ((_a$3754 (+ i 2)) (_a$3755 fixed) (_a$3756 (jolt-invoke (var-deref "jolt.host" "form-sym-name") r)) (_a$3757 hints) (_a$3758 phints)) (loop3753 _a$3754 _a$3755 _a$3756 _a$3757 _a$3758)))) (let* ((nm (jolt-invoke (var-deref "jolt.host" "form-sym-name") p)) (h (jolt-invoke (var-deref "jolt.analyzer" "hint-of") ctx p)) (ph (jolt-invoke (var-deref "jolt.analyzer" "phint-of") ctx p))) (let* ((_a$3763 (jolt-inc i)) (_a$3764 (jolt-conj fixed nm)) (_a$3765 rest-name) (_a$3766 (if (jolt-truthy? h) (jolt-conj hints (let* ((_o$3759 nm) (_o$3760 h)) (jolt-vector _o$3759 _o$3760))) hints)) (_a$3767 (if (jolt-truthy? ph) (jolt-conj phints (let* ((_o$3761 nm) (_o$3762 ph)) (jolt-vector _o$3761 _o$3762))) phints))) (loop3753 _a$3763 _a$3764 _a$3765 _a$3766 _a$3767)))))) (let* ((_o$3768 (keyword #f "fixed")) (_o$3769 fixed) (_o$3770 (keyword #f "rest")) (_o$3771 rest-name) (_o$3772 (keyword #f "hints")) (_o$3773 hints) (_o$3774 (keyword #f "phints")) (_o$3775 phints)) (jolt-hash-map _o$3768 _o$3769 _o$3770 _o$3771 _o$3772 _o$3773 _o$3774 _o$3775))))))))) parse-params)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "uniquify-params" (letrec ((uniquify-params (lambda (names) (let fnrec3776 ((names names)) (let* ((n (jolt-count names))) (let* ((i 0) (out (jolt-vector))) (let loop3777 ((i i) (out out)) (if (< i n) (let* ((nm (jolt-nth names i)) (dup? (let* ((j (jolt-inc i))) (let loop3778 ((j j)) (if (>= j n) #f (if (jolt= nm (jolt-nth names j)) #t (if (jolt-truthy? (keyword #f "else")) (loop3778 (jolt-inc j)) jolt-nil))))))) (let* ((_a$3779 (jolt-inc i)) (_a$3780 (jolt-conj out (if (jolt-truthy? dup?) (jolt-invoke (var-deref "jolt.analyzer" "gen-name") (jolt-invoke (var-deref "clojure.core" "str") nm "_")) nm)))) (loop3777 _a$3779 _a$3780))) out)))))))) uniquify-params)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-arity" (letrec ((analyze-arity (lambda (ctx pvec body env fn-name) (let fnrec3781 ((ctx ctx) (pvec pvec) (body body) (env env) (fn-name fn-name)) (let* ((pp (jolt-invoke (var-deref "jolt.analyzer" "parse-params") ctx (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-vec-items") pvec)))) (fixed (jolt-invoke (var-deref "jolt.analyzer" "uniquify-params") (jolt-get pp (keyword #f "fixed")))) (rst (jolt-get pp (keyword #f "rest"))) (rname (jolt-invoke (var-deref "jolt.analyzer" "gen-name") (let* ((_a$3782 (var-deref "clojure.core" "str")) (_a$3783 (jolt-invoke (var-deref "jolt.host" "compile-ns") ctx)) (_a$3784 "/") (_a$3785 (let* ((or__14__auto fn-name)) (if (jolt-truthy? or__14__auto) or__14__auto "fn"))) (_a$3786 "--")) (jolt-invoke _a$3782 _a$3783 _a$3784 _a$3785 _a$3786)))) (names (let* ((G__40 (jolt-invoke (var-deref "clojure.core" "vec") fixed))) (let* ((G__41 (if (jolt-truthy? rst) (jolt-conj G__40 rst) G__40))) (let* ((G__42 (if (jolt-truthy? fn-name) (jolt-conj G__41 fn-name) G__41))) G__42)))) (env0 (jolt-invoke (var-deref "jolt.analyzer" "with-recur") (jolt-invoke (var-deref "jolt.analyzer" "add-locals") env names) rname)) (env* (let* ((_a$3792 (lambda (e pr) (let fnrec3787 ((e e) (pr pr)) (let* ((_a$3788 (var-deref "jolt.analyzer" "add-hint")) (_a$3789 e) (_a$3790 (jolt-nth pr 0)) (_a$3791 (jolt-nth pr 1))) (jolt-invoke _a$3788 _a$3789 _a$3790 _a$3791))))) (_a$3793 env0) (_a$3794 (jolt-get pp (keyword #f "hints")))) (jolt-reduce _a$3792 _a$3793 _a$3794))) (arity (let* ((_o$3795 (keyword #f "params")) (_o$3796 fixed) (_o$3797 (keyword #f "recur-name")) (_o$3798 rname) (_o$3799 (keyword #f "body")) (_o$3800 (jolt-invoke (var-deref "jolt.analyzer" "analyze-seq") ctx body env*))) (jolt-hash-map _o$3795 _o$3796 _o$3797 _o$3798 _o$3799 _o$3800))) (arity (if (jolt-truthy? (jolt-seq (jolt-get pp (keyword #f "phints")))) (jolt-assoc arity (keyword #f "phints") (jolt-get pp (keyword #f "phints"))) arity))) (if (jolt-truthy? rst) (jolt-assoc arity (keyword #f "rest") rst) arity)))))) analyze-arity)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "strip-arglist-meta" (letrec ((strip-arglist-meta (lambda (form) (let fnrec3801 ((form form)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-list?") form)) (let* ((es (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-elements") form)))) (if (jolt-truthy? (let* ((and__13__auto (jolt= 3 (jolt-count es)))) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-invoke (var-deref "jolt.host" "form-sym?") (jolt-first es)))) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt= "with-meta" (jolt-invoke (var-deref "jolt.host" "form-sym-name") (jolt-first es))))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.host" "form-vec?") (jolt-nth es 1)) and__13__auto)) and__13__auto)) and__13__auto))) (jolt-nth es 1) form)) form))))) strip-arglist-meta)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-fn" (letrec ((analyze-fn (lambda (ctx items env) (let fnrec3802 ((ctx ctx) (items items) (env env)) (let* ((named (jolt-invoke (var-deref "jolt.host" "form-sym?") (jolt-nth items 1))) (fn-name (if (jolt-truthy? named) (jolt-invoke (var-deref "jolt.host" "form-sym-name") (jolt-nth items 1)) jolt-nil)) (rest-items (if (jolt-truthy? named) (jolt-drop 2 items) (jolt-drop 1 items))) (first* (jolt-invoke (var-deref "jolt.analyzer" "strip-arglist-meta") (jolt-first rest-items)))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-vec?") first*)) (jolt-invoke (var-deref "jolt.ir" "fn-node") fn-name (jolt-vector (jolt-invoke (var-deref "jolt.analyzer" "analyze-arity") ctx first* (jolt-rest rest-items) env fn-name))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-list?") first*)) (jolt-invoke (var-deref "jolt.ir" "fn-node") fn-name (jolt-invoke (var-deref "clojure.core" "mapv") (lambda (clause) (let fnrec3803 ((clause clause)) (let* ((cl (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-elements") clause)))) (let* ((_a$3804 (var-deref "jolt.analyzer" "analyze-arity")) (_a$3805 ctx) (_a$3806 (jolt-invoke (var-deref "jolt.analyzer" "strip-arglist-meta") (jolt-first cl))) (_a$3807 (jolt-rest cl)) (_a$3808 env) (_a$3809 fn-name)) (jolt-invoke _a$3804 _a$3805 _a$3806 _a$3807 _a$3808 _a$3809))))) rest-items)) (if (jolt-truthy? (keyword #f "else")) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "fn: bad params") jolt-nil)))))))) analyze-fn)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-try" (letrec ((analyze-try (lambda (ctx items env) (let fnrec3810 ((ctx ctx) (items items) (env env)) (let* ((clauses (jolt-rest items)) (body (jolt-invoke (var-deref "clojure.core" "atom") (jolt-vector))) (catch-sym (jolt-invoke (var-deref "clojure.core" "atom") jolt-nil)) (catch-body (jolt-invoke (var-deref "clojure.core" "atom") jolt-nil)) (finally-body (jolt-invoke (var-deref "clojure.core" "atom") jolt-nil))) (begin (begin (jolt-count (jolt-map (lambda (c) (let fnrec3811 ((c c)) (begin (let* ((head (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-list?") c)) (jolt-first (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-elements") c))) jolt-nil)) (hname (if (jolt-truthy? (let* ((and__13__auto head)) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.host" "form-sym?") head) and__13__auto))) (jolt-invoke (var-deref "jolt.host" "form-sym-name") head) jolt-nil))) (if (jolt= hname "catch") (let* ((cl (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-elements") c)))) (begin (if (jolt-truthy? (let* ((or__14__auto (< (jolt-count cl) 3))) (if (jolt-truthy? or__14__auto) or__14__auto (jolt-not (jolt-invoke (var-deref "jolt.host" "form-sym?") (jolt-nth cl 2)))))) (jolt-throw "Unable to parse catch clause; expected (catch class binding body*)") jolt-nil) (jolt-invoke (var-deref "clojure.core" "reset!") catch-sym (jolt-invoke (var-deref "jolt.host" "form-sym-name") (jolt-nth cl 2))) (jolt-invoke (var-deref "clojure.core" "reset!") catch-body (jolt-drop 3 cl)))) (if (jolt= hname "finally") (jolt-invoke (var-deref "clojure.core" "reset!") finally-body (jolt-rest (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-elements") c)))) (if (jolt-truthy? (keyword #f "else")) (jolt-invoke (var-deref "clojure.core" "swap!") body jolt-conj c) jolt-nil)))) jolt-nil))) clauses)) jolt-nil) (let* ((n (let* ((_o$3812 (keyword #f "op")) (_o$3813 (keyword #f "try")) (_o$3814 (keyword #f "body")) (_o$3815 (jolt-invoke (var-deref "jolt.analyzer" "analyze-seq") ctx (jolt-invoke (var-deref "clojure.core" "deref") body) env))) (jolt-hash-map _o$3812 _o$3813 _o$3814 _o$3815))) (n (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "deref") catch-body)) (let* ((_a$3820 n) (_a$3821 (keyword #f "catch-sym")) (_a$3822 (jolt-invoke (var-deref "clojure.core" "deref") catch-sym)) (_a$3823 (keyword #f "catch-body")) (_a$3824 (let* ((_a$3816 (var-deref "jolt.analyzer" "analyze-seq")) (_a$3817 ctx) (_a$3818 (jolt-invoke (var-deref "clojure.core" "deref") catch-body)) (_a$3819 (jolt-invoke (var-deref "jolt.analyzer" "add-locals") env (jolt-vector (jolt-invoke (var-deref "clojure.core" "deref") catch-sym))))) (jolt-invoke _a$3816 _a$3817 _a$3818 _a$3819)))) (jolt-assoc _a$3820 _a$3821 _a$3822 _a$3823 _a$3824)) n)) (n (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "deref") finally-body)) (jolt-assoc n (keyword #f "finally") (jolt-invoke (var-deref "jolt.analyzer" "analyze-seq") ctx (jolt-invoke (var-deref "clojure.core" "deref") finally-body) env)) n))) n))))))) analyze-try)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-letfn" (letrec ((analyze-letfn (lambda (ctx items env) (let fnrec3825 ((ctx ctx) (items items) (env env)) (let* ((specs (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-vec-items") (jolt-nth items 1)))) (names (jolt-invoke (var-deref "clojure.core" "mapv") (lambda (p__49_) (let fnrec3826 ((p__49_ p__49_)) (jolt-invoke (var-deref "jolt.host" "form-sym-name") (jolt-first (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-elements") p__49_)))))) specs)) (env* (jolt-invoke (var-deref "jolt.analyzer" "add-locals") env names)) (binds (jolt-invoke (var-deref "clojure.core" "mapv") (lambda (spec) (let fnrec3827 ((spec spec)) (let* ((cl (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-elements") spec)))) (let* ((_o$3828 (jolt-invoke (var-deref "jolt.host" "form-sym-name") (jolt-first cl))) (_o$3829 (jolt-invoke (var-deref "jolt.analyzer" "analyze-fn") ctx (jolt-invoke (var-deref "clojure.core" "vec") (jolt-cons (jolt-first cl) cl)) env*))) (jolt-vector _o$3828 _o$3829))))) specs))) (let* ((_o$3830 (keyword #f "op")) (_o$3831 (keyword #f "let")) (_o$3832 (keyword #f "letrec")) (_o$3833 #t) (_o$3834 (keyword #f "bindings")) (_o$3835 binds) (_o$3836 (keyword #f "body")) (_o$3837 (jolt-invoke (var-deref "jolt.analyzer" "analyze-seq") ctx (jolt-drop 2 items) env*))) (jolt-hash-map _o$3830 _o$3831 _o$3832 _o$3833 _o$3834 _o$3835 _o$3836 _o$3837))))))) analyze-letfn)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-special" (letrec ((analyze-special (lambda (ctx op items env) (let fnrec3838 ((ctx ctx) (op op) (items items) (env env)) (let* ((G__43 op)) (if (jolt= G__43 "quote") (jolt-invoke (var-deref "jolt.ir" "quote-node") (jolt-invoke (var-deref "clojure.core" "second") items)) (if (jolt= G__43 "if") (begin (if (jolt-truthy? (let* ((or__14__auto (< (jolt-count items) 3))) (if (jolt-truthy? or__14__auto) or__14__auto (> (jolt-count items) 4)))) (jolt-throw (jolt-invoke (var-deref "clojure.core" "str") "Wrong number of args (" (jolt-dec (jolt-count items)) ") passed to: if")) jolt-nil) (let* ((_a$3839 (var-deref "jolt.ir" "if-node")) (_a$3840 (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth items 1) env)) (_a$3841 (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth items 2) env)) (_a$3842 (if (> (jolt-count items) 3) (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth items 3) env) (jolt-invoke (var-deref "jolt.ir" "const") jolt-nil)))) (jolt-invoke _a$3839 _a$3840 _a$3841 _a$3842))) (if (jolt= G__43 "do") (jolt-invoke (var-deref "jolt.analyzer" "analyze-seq") ctx (jolt-rest items) env) (if (jolt= G__43 "throw") (jolt-invoke (var-deref "jolt.ir" "throw-node") (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth items 1) env)) (if (jolt= G__43 "def") (let* ((name-sym (jolt-nth items 1))) (begin (if (jolt-not (jolt-invoke (var-deref "jolt.host" "form-sym?") name-sym)) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "def name with map metadata") jolt-nil) (if (< (jolt-count items) 3) (let* ((nm (jolt-invoke (var-deref "jolt.host" "form-sym-name") name-sym)) (cur (jolt-invoke (var-deref "jolt.host" "compile-ns") ctx))) (begin (jolt-invoke (var-deref "jolt.host" "host-intern!") ctx cur nm) (let* ((_o$3843 (keyword #f "op")) (_o$3844 (keyword #f "def")) (_o$3845 (keyword #f "ns")) (_o$3846 cur) (_o$3847 (keyword #f "name")) (_o$3848 nm) (_o$3849 (keyword #f "no-init")) (_o$3850 #t)) (jolt-hash-map _o$3843 _o$3844 _o$3845 _o$3846 _o$3847 _o$3848 _o$3849 _o$3850)))) (let* ((nm (jolt-invoke (var-deref "jolt.host" "form-sym-name") name-sym)) (cur (jolt-invoke (var-deref "jolt.host" "compile-ns") ctx)) (has-doc (let* ((and__13__auto (> (jolt-count items) 3))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "clojure.core" "string?") (jolt-nth items 2)) and__13__auto))) (val-form (jolt-nth items (if (jolt-truthy? has-doc) 3 2))) (base0 (let* ((or__14__auto (jolt-invoke (var-deref "jolt.host" "form-sym-meta") name-sym))) (if (jolt-truthy? or__14__auto) or__14__auto (jolt-hash-map)))) (tag (jolt-get base0 (keyword #f "tag"))) (tag-name (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-sym?") tag)) (jolt-invoke (var-deref "jolt.host" "form-sym-name") tag) (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "string?") tag)) tag (if (jolt-truthy? (keyword #f "else")) jolt-nil jolt-nil)))) (base-meta (if (jolt-truthy? tag-name) (let* ((c (jolt-invoke (var-deref "jolt.host" "resolve-class-hint") tag-name))) (if (jolt-truthy? c) (jolt-assoc base0 (keyword #f "tag") c) base0)) base0)) (node-meta (if (jolt-truthy? has-doc) (jolt-assoc base-meta (keyword #f "doc") (jolt-nth items 2)) base-meta))) (begin (jolt-invoke (var-deref "jolt.host" "host-intern!") ctx cur nm) (jolt-invoke (var-deref "jolt.ir" "def-node") cur nm (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx val-form env) node-meta)))))) (if (jolt= G__43 "let*") (let* ((bvec (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-vec-items") (jolt-nth items 1)))) (r (jolt-invoke (var-deref "jolt.analyzer" "analyze-bindings") ctx bvec env))) (let* ((_a$3855 (var-deref "jolt.ir" "let-node")) (_a$3856 (jolt-first r)) (_a$3857 (let* ((_a$3851 (var-deref "jolt.analyzer" "analyze-seq")) (_a$3852 ctx) (_a$3853 (jolt-drop 2 items)) (_a$3854 (jolt-invoke (var-deref "clojure.core" "second") r))) (jolt-invoke _a$3851 _a$3852 _a$3853 _a$3854)))) (jolt-invoke _a$3855 _a$3856 _a$3857))) (if (jolt= G__43 "loop*") (let* ((bvec (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-vec-items") (jolt-nth items 1)))) (rname (jolt-invoke (var-deref "jolt.analyzer" "gen-name") "loop")) (r (jolt-invoke (var-deref "jolt.analyzer" "analyze-bindings") ctx bvec env)) (env** (jolt-invoke (var-deref "jolt.analyzer" "with-recur") (jolt-invoke (var-deref "clojure.core" "second") r) rname))) (let* ((_o$3858 (keyword #f "op")) (_o$3859 (keyword #f "loop")) (_o$3860 (keyword #f "recur-name")) (_o$3861 rname) (_o$3862 (keyword #f "bindings")) (_o$3863 (jolt-first r)) (_o$3864 (keyword #f "body")) (_o$3865 (jolt-invoke (var-deref "jolt.analyzer" "analyze-seq") ctx (jolt-drop 2 items) env**))) (jolt-hash-map _o$3858 _o$3859 _o$3860 _o$3861 _o$3862 _o$3863 _o$3864 _o$3865))) (if (jolt= G__43 "recur") (let* ((rt (jolt-get env (keyword #f "recur")))) (begin (if (jolt-not rt) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "recur outside loop/fn") jolt-nil) (let* ((_o$3870 (keyword #f "op")) (_o$3871 (keyword #f "recur")) (_o$3872 (keyword #f "recur-name")) (_o$3873 rt) (_o$3874 (keyword #f "args")) (_o$3875 (let* ((_a$3867 (var-deref "clojure.core" "mapv")) (_a$3868 (lambda (p__50_) (let fnrec3866 ((p__50_ p__50_)) (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx p__50_ env)))) (_a$3869 (jolt-rest items))) (jolt-invoke _a$3867 _a$3868 _a$3869)))) (jolt-hash-map _o$3870 _o$3871 _o$3872 _o$3873 _o$3874 _o$3875)))) (if (jolt= G__43 "try") (jolt-invoke (var-deref "jolt.analyzer" "analyze-try") ctx items env) (if (jolt= G__43 "letfn") (jolt-invoke (var-deref "jolt.analyzer" "analyze-letfn") ctx items env) (if (jolt= G__43 "fn*") (jolt-invoke (var-deref "jolt.analyzer" "analyze-fn") ctx items env) (if (jolt= G__43 "syntax-quote") (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-invoke (var-deref "jolt.host" "form-syntax-quote-lower") ctx (jolt-invoke (var-deref "clojure.core" "second") items)) env) (if (jolt= G__43 "var") (let* ((sym (jolt-invoke (var-deref "clojure.core" "second") items)) (r (jolt-invoke (var-deref "jolt.host" "resolve-global") ctx sym))) (if (jolt= (keyword #f "var") (jolt-get r (keyword #f "kind"))) (let* ((_a$3876 (var-deref "jolt.ir" "the-var")) (_a$3877 (jolt-get r (keyword #f "ns"))) (_a$3878 (jolt-get r (keyword #f "name")))) (jolt-invoke _a$3876 _a$3877 _a$3878)) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") (jolt-invoke (var-deref "clojure.core" "str") "var of non-var " (jolt-invoke (var-deref "jolt.host" "form-sym-name") sym))))) (if (jolt= G__43 "defmacro") (let* ((name-sym (jolt-nth items 1)) (nm (jolt-invoke (var-deref "jolt.host" "form-sym-name") name-sym)) (cur (jolt-invoke (var-deref "jolt.host" "compile-ns") ctx)) (after (jolt-drop 2 items)) (after (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "string?") (jolt-first after))) (jolt-rest after) after)) (after (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-map?") (jolt-first after))) (jolt-rest after) after)) (fn-form (jolt-cons (jolt-invoke (var-deref "clojure.core" "symbol") "fn") after))) (begin (jolt-invoke (var-deref "jolt.host" "host-intern!") ctx cur nm) (let* ((_o$3879 (keyword #f "op")) (_o$3880 (keyword #f "defmacro")) (_o$3881 (keyword #f "ns")) (_o$3882 cur) (_o$3883 (keyword #f "name")) (_o$3884 nm) (_o$3885 (keyword #f "fn")) (_o$3886 (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx fn-form env))) (jolt-hash-map _o$3879 _o$3880 _o$3881 _o$3882 _o$3883 _o$3884 _o$3885 _o$3886)))) (if (jolt= G__43 "set!") (let* ((target (jolt-nth items 1)) (val-node (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth items 2) env)) (ti (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-list?") target)) (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-elements") target)) jolt-nil)) (thead (if (jolt-truthy? (let* ((and__13__auto ti)) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-pos? (jolt-count ti)))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.host" "form-sym?") (jolt-first ti)) and__13__auto)) and__13__auto))) (jolt-invoke (var-deref "jolt.host" "form-sym-name") (jolt-first ti)) jolt-nil))) (if (jolt-truthy? (let* ((and__13__auto thead)) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.analyzer" "field-head?") thead) and__13__auto))) (let* ((_o$3887 (keyword #f "op")) (_o$3888 (keyword #f "set-field")) (_o$3889 (keyword #f "obj")) (_o$3890 (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth ti 1) env)) (_o$3891 (keyword #f "field")) (_o$3892 (jolt-invoke (var-deref "clojure.core" "subs") thead 2)) (_o$3893 (keyword #f "val")) (_o$3894 val-node)) (jolt-hash-map _o$3887 _o$3888 _o$3889 _o$3890 _o$3891 _o$3892 _o$3893 _o$3894)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-sym?") target)) (begin (if (jolt-truthy? (jolt-invoke (var-deref "jolt.analyzer" "local?") env (jolt-invoke (var-deref "jolt.host" "form-sym-name") target))) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "set! of a local") jolt-nil) (let* ((r (jolt-invoke (var-deref "jolt.host" "resolve-global") ctx target))) (begin (if (jolt-not (jolt= (keyword #f "var") (jolt-get r (keyword #f "kind")))) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "set! of a non-var") jolt-nil) (let* ((_o$3898 (keyword #f "op")) (_o$3899 (keyword #f "set-var")) (_o$3900 (keyword #f "the-var")) (_o$3901 (let* ((_a$3895 (var-deref "jolt.ir" "the-var")) (_a$3896 (jolt-get r (keyword #f "ns"))) (_a$3897 (jolt-get r (keyword #f "name")))) (jolt-invoke _a$3895 _a$3896 _a$3897))) (_o$3902 (keyword #f "val")) (_o$3903 val-node)) (jolt-hash-map _o$3898 _o$3899 _o$3900 _o$3901 _o$3902 _o$3903))))) (if (jolt-truthy? (keyword #f "else")) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "set! of an unsupported target") jolt-nil)))) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") (jolt-invoke (var-deref "clojure.core" "str") "special form " op)))))))))))))))))))))) analyze-special)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "method-head?" (letrec ((method-head? (lambda (nm) (let fnrec3904 ((nm nm)) (let* ((and__13__auto (> (jolt-count nm) 1))) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt= "." (jolt-invoke (var-deref "clojure.core" "subs") nm 0 1)))) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-not (jolt= "-" (jolt-invoke (var-deref "clojure.core" "subs") nm 1 2))))) (if (jolt-truthy? and__13__auto) (jolt-not (jolt= "." (jolt-invoke (var-deref "clojure.core" "subs") nm 1 2))) and__13__auto)) and__13__auto)) and__13__auto)))))) method-head?)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-host-call" (letrec ((analyze-host-call (lambda (ctx hname items env) (let fnrec3905 ((ctx ctx) (hname hname) (items items) (env env)) (begin (if (< (jolt-count items) 2) (jolt-throw (jolt-invoke (var-deref "clojure.core" "str") "Malformed member expression, expecting (.method target ...): " hname)) jolt-nil) (let* ((_o$3910 (keyword #f "op")) (_o$3911 (keyword #f "host-call")) (_o$3912 (keyword #f "method")) (_o$3913 (jolt-invoke (var-deref "clojure.core" "subs") hname 1)) (_o$3914 (keyword #f "target")) (_o$3915 (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth items 1) env)) (_o$3916 (keyword #f "args")) (_o$3917 (let* ((_a$3907 (var-deref "clojure.core" "mapv")) (_a$3908 (lambda (p__51_) (let fnrec3906 ((p__51_ p__51_)) (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx p__51_ env)))) (_a$3909 (jolt-drop 2 items))) (jolt-invoke _a$3907 _a$3908 _a$3909)))) (jolt-hash-map _o$3910 _o$3911 _o$3912 _o$3913 _o$3914 _o$3915 _o$3916 _o$3917))))))) analyze-host-call)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "ctor-head?" (letrec ((ctor-head? (lambda (nm) (let fnrec3918 ((nm nm)) (let* ((and__13__auto (> (jolt-count nm) 1))) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt= "." (let* ((_a$3919 (var-deref "clojure.core" "subs")) (_a$3920 nm) (_a$3921 (jolt-dec (jolt-count nm))) (_a$3922 (jolt-count nm))) (jolt-invoke _a$3919 _a$3920 _a$3921 _a$3922))))) (if (jolt-truthy? and__13__auto) (jolt-not (jolt= "." (jolt-invoke (var-deref "clojure.core" "subs") nm 0 1))) and__13__auto)) and__13__auto)))))) ctor-head?)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-ctor" (letrec ((analyze-ctor (lambda (ctx class args env) (let fnrec3923 ((ctx ctx) (class class) (args args) (env env)) (jolt-invoke (var-deref "jolt.ir" "host-new") class (jolt-invoke (var-deref "clojure.core" "mapv") (lambda (p__52_) (let fnrec3924 ((p__52_ p__52_)) (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx p__52_ env))) args)))))) analyze-ctor)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-ffi-fn" (letrec ((analyze-ffi-fn (lambda (ctx items env) (let fnrec3925 ((ctx ctx) (items items) (env env)) (begin (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "not=") 4 (jolt-count items))) (jolt-throw (jolt-invoke (var-deref "clojure.core" "str") "jolt.ffi/foreign-fn expects (foreign-fn \"sym\" [argtypes] rettype)")) jolt-nil) (let* ((_o$3926 (keyword #f "op")) (_o$3927 (keyword #f "ffi-fn")) (_o$3928 (keyword #f "csym")) (_o$3929 (jolt-nth items 1)) (_o$3930 (keyword #f "argtypes")) (_o$3931 (jolt-invoke (var-deref "clojure.core" "mapv") (var-deref "clojure.core" "name") (jolt-invoke (var-deref "jolt.host" "form-vec-items") (jolt-nth items 2)))) (_o$3932 (keyword #f "rettype")) (_o$3933 (jolt-invoke (var-deref "clojure.core" "name") (jolt-nth items 3)))) (jolt-hash-map _o$3926 _o$3927 _o$3928 _o$3929 _o$3930 _o$3931 _o$3932 _o$3933))))))) analyze-ffi-fn)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-dot" (letrec ((analyze-dot (lambda (ctx items env) (let fnrec3934 ((ctx ctx) (items items) (env env)) (begin (if (< (jolt-count items) 3) (jolt-throw (jolt-invoke (var-deref "clojure.core" "str") "Malformed (. target member ...) form")) jolt-nil) (let* ((member (jolt-nth items 2))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-sym?") member)) (let* ((_o$3939 (keyword #f "op")) (_o$3940 (keyword #f "host-call")) (_o$3941 (keyword #f "method")) (_o$3942 (jolt-invoke (var-deref "jolt.host" "form-sym-name") member)) (_o$3943 (keyword #f "target")) (_o$3944 (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth items 1) env)) (_o$3945 (keyword #f "args")) (_o$3946 (let* ((_a$3936 (var-deref "clojure.core" "mapv")) (_a$3937 (lambda (p__53_) (let fnrec3935 ((p__53_ p__53_)) (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx p__53_ env)))) (_a$3938 (jolt-drop 3 items))) (jolt-invoke _a$3936 _a$3937 _a$3938)))) (jolt-hash-map _o$3939 _o$3940 _o$3941 _o$3942 _o$3943 _o$3944 _o$3945 _o$3946)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-keyword?") member)) (let* ((_a$3947 (var-deref "jolt.ir" "invoke")) (_a$3948 (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx member env)) (_a$3949 (jolt-vector (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth items 1) env)))) (jolt-invoke _a$3947 _a$3948 _a$3949)) (if (jolt-truthy? (keyword #f "else")) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "special form . (non-symbol member)") jolt-nil))))))))) analyze-dot)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "field-head?" (letrec ((field-head? (lambda (nm) (let fnrec3950 ((nm nm)) (let* ((and__13__auto (> (jolt-count nm) 2))) (if (jolt-truthy? and__13__auto) (jolt= ".-" (jolt-invoke (var-deref "clojure.core" "subs") nm 0 2)) and__13__auto)))))) field-head?)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-field" (letrec ((analyze-field (lambda (ctx hname items env) (let fnrec3951 ((ctx ctx) (hname hname) (items items) (env env)) (begin (if (< (jolt-count items) 2) (jolt-throw (jolt-invoke (var-deref "clojure.core" "str") "Malformed (.-field target) form")) jolt-nil) (let* ((_o$3952 (keyword #f "op")) (_o$3953 (keyword #f "host-call")) (_o$3954 (keyword #f "method")) (_o$3955 (jolt-invoke (var-deref "clojure.core" "subs") hname 1)) (_o$3956 (keyword #f "target")) (_o$3957 (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-nth items 1) env)) (_o$3958 (keyword #f "args")) (_o$3959 (jolt-vector))) (jolt-hash-map _o$3952 _o$3953 _o$3954 _o$3955 _o$3956 _o$3957 _o$3958 _o$3959))))))) analyze-field)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-symbol" (letrec ((analyze-symbol (lambda (ctx form env) (let fnrec3960 ((ctx ctx) (form form) (env env)) (let* ((nm (jolt-invoke (var-deref "jolt.host" "form-sym-name") form)) (ns (jolt-invoke (var-deref "jolt.host" "form-sym-ns") form))) (if (jolt-truthy? (let* ((and__13__auto (jolt-invoke (var-deref "clojure.core" "nil?") ns))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.analyzer" "local?") env nm) and__13__auto))) (let* ((h (jolt-get (jolt-get env (keyword #f "hints")) nm))) (if (jolt-truthy? h) (jolt-assoc (jolt-invoke (var-deref "jolt.ir" "local") nm) (keyword #f "hint") h) (jolt-invoke (var-deref "jolt.ir" "local") nm))) (if (jolt-truthy? ns) (let* ((r (jolt-invoke (var-deref "jolt.host" "resolve-global") ctx form))) (if (jolt= (keyword #f "var") (jolt-get r (keyword #f "kind"))) (let* ((_a$3961 (var-deref "jolt.ir" "var-ref")) (_a$3962 (jolt-get r (keyword #f "ns"))) (_a$3963 (jolt-get r (keyword #f "name")))) (jolt-invoke _a$3961 _a$3962 _a$3963)) (jolt-invoke (var-deref "jolt.ir" "host-static") ns nm))) (if (jolt-truthy? (keyword #f "else")) (let* ((r (jolt-invoke (var-deref "jolt.host" "resolve-global") ctx form))) (let* ((G__44 (jolt-get r (keyword #f "kind")))) (if (jolt= G__44 (keyword #f "var")) (let* ((_a$3964 (var-deref "jolt.ir" "var-ref")) (_a$3965 (jolt-get r (keyword #f "ns"))) (_a$3966 (jolt-get r (keyword #f "name")))) (jolt-invoke _a$3964 _a$3965 _a$3966)) (if (jolt= G__44 (keyword #f "host")) (jolt-invoke (var-deref "jolt.ir" "host-ref") (jolt-get r (keyword #f "name"))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "late-bind?") ctx)) (jolt-invoke (var-deref "jolt.ir" "var-ref") (jolt-invoke (var-deref "jolt.host" "compile-ns") ctx) nm) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") (jolt-invoke (var-deref "clojure.core" "str") "Unable to resolve symbol: " nm " in this context"))))))) jolt-nil)))))))) analyze-symbol)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze-list" (letrec ((analyze-list (lambda (ctx form env) (let fnrec3967 ((ctx ctx) (form form) (env env)) (let* ((items (jolt-invoke (var-deref "clojure.core" "vec") (jolt-invoke (var-deref "jolt.host" "form-elements") form)))) (if (jolt-zero? (jolt-count items)) (jolt-invoke (var-deref "jolt.ir" "quote-node") form) (let* ((head (jolt-first items)) (hname (if (jolt-truthy? (let* ((and__13__auto (jolt-invoke (var-deref "jolt.host" "form-sym?") head))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "clojure.core" "nil?") (jolt-invoke (var-deref "jolt.host" "form-sym-ns") head)) and__13__auto))) (jolt-invoke (var-deref "jolt.host" "form-sym-name") head) jolt-nil)) (shadowed (let* ((and__13__auto hname)) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.analyzer" "local?") env hname) and__13__auto)))) (if (jolt-truthy? (let* ((and__13__auto (jolt-invoke (var-deref "jolt.host" "form-sym?") head))) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-not shadowed))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.host" "form-macro?") ctx head) and__13__auto)) and__13__auto))) (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx (jolt-invoke (var-deref "jolt.host" "form-expand-1") ctx form) env) (if (jolt-truthy? (let* ((and__13__auto (jolt-invoke (var-deref "jolt.host" "form-sym?") head))) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt= "jolt.ffi" (jolt-invoke (var-deref "jolt.host" "form-sym-ns") head)))) (if (jolt-truthy? and__13__auto) (jolt= "__cfn" (jolt-invoke (var-deref "jolt.host" "form-sym-name") head)) and__13__auto)) and__13__auto))) (jolt-invoke (var-deref "jolt.analyzer" "analyze-ffi-fn") ctx items env) (if (jolt-truthy? (let* ((and__13__auto hname)) (if (jolt-truthy? and__13__auto) (jolt-contains? (var-deref "jolt.analyzer" "handled") hname) and__13__auto))) (jolt-invoke (var-deref "jolt.analyzer" "analyze-special") ctx hname items env) (if (jolt-truthy? (let* ((and__13__auto hname)) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-not shadowed))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.analyzer" "method-head?") hname) and__13__auto)) and__13__auto))) (jolt-invoke (var-deref "jolt.analyzer" "analyze-host-call") ctx hname items env) (if (jolt-truthy? (let* ((and__13__auto hname)) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-not shadowed))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.analyzer" "ctor-head?") hname) and__13__auto)) and__13__auto))) (let* ((_a$3968 (var-deref "jolt.analyzer" "analyze-ctor")) (_a$3969 ctx) (_a$3970 (jolt-invoke (var-deref "clojure.core" "subs") hname 0 (jolt-dec (jolt-count hname)))) (_a$3971 (jolt-rest items)) (_a$3972 env)) (jolt-invoke _a$3968 _a$3969 _a$3970 _a$3971 _a$3972)) (if (jolt-truthy? (let* ((and__13__auto (jolt= hname "new"))) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-not shadowed))) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (>= (jolt-count items) 2))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.host" "form-sym?") (jolt-nth items 1)) and__13__auto)) and__13__auto)) and__13__auto))) (let* ((_a$3973 (var-deref "jolt.analyzer" "analyze-ctor")) (_a$3974 ctx) (_a$3975 (jolt-invoke (var-deref "jolt.host" "form-sym-name") (jolt-nth items 1))) (_a$3976 (jolt-drop 2 items)) (_a$3977 env)) (jolt-invoke _a$3973 _a$3974 _a$3975 _a$3976 _a$3977)) (if (jolt-truthy? (let* ((and__13__auto (jolt= hname "."))) (if (jolt-truthy? and__13__auto) (jolt-not shadowed) and__13__auto))) (jolt-invoke (var-deref "jolt.analyzer" "analyze-dot") ctx items env) (if (jolt-truthy? (let* ((and__13__auto hname)) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-not shadowed))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.analyzer" "field-head?") hname) and__13__auto)) and__13__auto))) (jolt-invoke (var-deref "jolt.analyzer" "analyze-field") ctx hname items env) (if (jolt-truthy? (let* ((and__13__auto hname)) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-not shadowed))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.host" "form-special?") hname) and__13__auto)) and__13__auto))) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") (jolt-invoke (var-deref "clojure.core" "str") "special form " hname)) (if (jolt-truthy? (keyword #f "else")) (let* ((n (let* ((_a$3982 (var-deref "jolt.ir" "invoke")) (_a$3983 (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx head env)) (_a$3984 (let* ((_a$3979 (var-deref "clojure.core" "mapv")) (_a$3980 (lambda (p__54_) (let fnrec3978 ((p__54_ p__54_)) (jolt-invoke (var-deref "jolt.analyzer" "analyze") ctx p__54_ env)))) (_a$3981 (jolt-rest items))) (jolt-invoke _a$3979 _a$3980 _a$3981)))) (jolt-invoke _a$3982 _a$3983 _a$3984))) (p (jolt-invoke (var-deref "jolt.host" "form-position") form))) (if (jolt-truthy? p) (jolt-assoc n (keyword #f "pos") p) n)) jolt-nil))))))))))))))))) analyze-list)))
(guard (e (#t #f))
  (def-var! "jolt.analyzer" "analyze" (letrec ((analyze (case-lambda ((ctx form) (let fnrec3985 ((ctx ctx) (form form)) (jolt-invoke analyze ctx form (jolt-invoke (var-deref "jolt.analyzer" "empty-env"))))) ((ctx form env) (let fnrec3986 ((ctx ctx) (form form) (env env)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-literal?") form)) (jolt-invoke (var-deref "jolt.ir" "const") form) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-sym?") form)) (jolt-invoke (var-deref "jolt.analyzer" "analyze-symbol") ctx form env) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-vec?") form)) (jolt-invoke (var-deref "jolt.ir" "vector-node") (let* ((_a$3988 (var-deref "clojure.core" "mapv")) (_a$3989 (lambda (p__55_) (let fnrec3987 ((p__55_ p__55_)) (jolt-invoke analyze ctx p__55_ env)))) (_a$3990 (jolt-invoke (var-deref "jolt.host" "form-vec-items") form))) (jolt-invoke _a$3988 _a$3989 _a$3990))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-map?") form)) (jolt-invoke (var-deref "jolt.ir" "map-node") (let* ((_a$3994 (var-deref "clojure.core" "mapv")) (_a$3995 (lambda (p) (let fnrec3991 ((p p)) (let* ((_o$3992 (jolt-invoke analyze ctx (jolt-first p) env)) (_o$3993 (jolt-invoke analyze ctx (jolt-invoke (var-deref "clojure.core" "second") p) env))) (jolt-vector _o$3992 _o$3993))))) (_a$3996 (jolt-invoke (var-deref "jolt.host" "form-map-pairs") form))) (jolt-invoke _a$3994 _a$3995 _a$3996))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-set?") form)) (jolt-invoke (var-deref "jolt.ir" "set-node") (let* ((_a$3998 (var-deref "clojure.core" "mapv")) (_a$3999 (lambda (p__56_) (let fnrec3997 ((p__56_ p__56_)) (jolt-invoke analyze ctx p__56_ env)))) (_a$4000 (jolt-invoke (var-deref "jolt.host" "form-set-items") form))) (jolt-invoke _a$3998 _a$3999 _a$4000))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-list?") form)) (jolt-invoke (var-deref "jolt.analyzer" "analyze-list") ctx form env) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-regex?") form)) (let* ((_o$4001 (keyword #f "op")) (_o$4002 (keyword #f "regex")) (_o$4003 (keyword #f "source")) (_o$4004 (jolt-invoke (var-deref "jolt.host" "form-regex-source") form))) (jolt-hash-map _o$4001 _o$4002 _o$4003 _o$4004)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-inst?") form)) (let* ((_o$4005 (keyword #f "op")) (_o$4006 (keyword #f "inst")) (_o$4007 (keyword #f "source")) (_o$4008 (jolt-invoke (var-deref "jolt.host" "form-inst-source") form))) (jolt-hash-map _o$4005 _o$4006 _o$4007 _o$4008)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-uuid?") form)) (let* ((_o$4009 (keyword #f "op")) (_o$4010 (keyword #f "uuid")) (_o$4011 (keyword #f "source")) (_o$4012 (jolt-invoke (var-deref "jolt.host" "form-uuid-source") form))) (jolt-hash-map _o$4009 _o$4010 _o$4011 _o$4012)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-bigdec?") form)) (let* ((_o$4013 (keyword #f "op")) (_o$4014 (keyword #f "bigdec")) (_o$4015 (keyword #f "source")) (_o$4016 (jolt-invoke (var-deref "jolt.host" "form-bigdec-source") form))) (jolt-hash-map _o$4013 _o$4014 _o$4015 _o$4016)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-ns-value?") form)) (let* ((_o$4017 (keyword #f "op")) (_o$4018 (keyword #f "the-ns")) (_o$4019 (keyword #f "name")) (_o$4020 (jolt-invoke (var-deref "jolt.host" "form-ns-value-name") form))) (jolt-hash-map _o$4017 _o$4018 _o$4019 _o$4020)) (if (jolt-truthy? (keyword #f "else")) (jolt-invoke (var-deref "jolt.analyzer" "uncompilable") "unsupported form") jolt-nil))))))))))))))))) analyze)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "native-ops" (let* ((_o$2876 "+") (_o$2877 "+") (_o$2878 "-") (_o$2879 "-") (_o$2880 "*") (_o$2881 "*") (_o$2882 "/") (_o$2883 "/") (_o$2884 "<") (_o$2885 "<") (_o$2886 ">") (_o$2887 ">") (_o$2888 "<=") (_o$2889 "<=") (_o$2890 ">=") (_o$2891 ">=") (_o$2892 "=") (_o$2893 "jolt=") (_o$2894 "inc") (_o$2895 "jolt-inc") (_o$2896 "dec") (_o$2897 "jolt-dec") (_o$2898 "not") (_o$2899 "jolt-not") (_o$2900 "min") (_o$2901 "min") (_o$2902 "max") (_o$2903 "max") (_o$2904 "mod") (_o$2905 "modulo") (_o$2906 "rem") (_o$2907 "remainder") (_o$2908 "quot") (_o$2909 "quotient") (_o$2910 "vector") (_o$2911 "jolt-vector") (_o$2912 "hash-map") (_o$2913 "jolt-hash-map") (_o$2914 "hash-set") (_o$2915 "jolt-hash-set") (_o$2916 "conj") (_o$2917 "jolt-conj") (_o$2918 "get") (_o$2919 "jolt-get") (_o$2920 "nth") (_o$2921 "jolt-nth") (_o$2922 "count") (_o$2923 "jolt-count") (_o$2924 "assoc") (_o$2925 "jolt-assoc") (_o$2926 "dissoc") (_o$2927 "jolt-dissoc") (_o$2928 "contains?") (_o$2929 "jolt-contains?") (_o$2930 "empty?") (_o$2931 "jolt-empty?") (_o$2932 "peek") (_o$2933 "jolt-peek") (_o$2934 "pop") (_o$2935 "jolt-pop") (_o$2936 "first") (_o$2937 "jolt-first") (_o$2938 "rest") (_o$2939 "jolt-rest") (_o$2940 "next") (_o$2941 "jolt-next") (_o$2942 "seq") (_o$2943 "jolt-seq") (_o$2944 "cons") (_o$2945 "jolt-cons") (_o$2946 "list") (_o$2947 "jolt-list") (_o$2948 "reverse") (_o$2949 "jolt-reverse") (_o$2950 "last") (_o$2951 "jolt-last") (_o$2952 "map") (_o$2953 "jolt-map") (_o$2954 "filter") (_o$2955 "jolt-filter") (_o$2956 "remove") (_o$2957 "jolt-remove") (_o$2958 "reduce") (_o$2959 "jolt-reduce") (_o$2960 "into") (_o$2961 "jolt-into") (_o$2962 "concat") (_o$2963 "jolt-concat") (_o$2964 "apply") (_o$2965 "jolt-apply") (_o$2966 "range") (_o$2967 "jolt-range") (_o$2968 "take") (_o$2969 "jolt-take") (_o$2970 "drop") (_o$2971 "jolt-drop") (_o$2972 "keys") (_o$2973 "jolt-keys") (_o$2974 "vals") (_o$2975 "jolt-vals") (_o$2976 "even?") (_o$2977 "jolt-even?") (_o$2978 "odd?") (_o$2979 "jolt-odd?") (_o$2980 "pos?") (_o$2981 "jolt-pos?") (_o$2982 "neg?") (_o$2983 "jolt-neg?") (_o$2984 "zero?") (_o$2985 "jolt-zero?") (_o$2986 "identity") (_o$2987 "jolt-identity") (_o$2988 "ex-info") (_o$2989 "jolt-ex-info")) (jolt-hash-map _o$2876 _o$2877 _o$2878 _o$2879 _o$2880 _o$2881 _o$2882 _o$2883 _o$2884 _o$2885 _o$2886 _o$2887 _o$2888 _o$2889 _o$2890 _o$2891 _o$2892 _o$2893 _o$2894 _o$2895 _o$2896 _o$2897 _o$2898 _o$2899 _o$2900 _o$2901 _o$2902 _o$2903 _o$2904 _o$2905 _o$2906 _o$2907 _o$2908 _o$2909 _o$2910 _o$2911 _o$2912 _o$2913 _o$2914 _o$2915 _o$2916 _o$2917 _o$2918 _o$2919 _o$2920 _o$2921 _o$2922 _o$2923 _o$2924 _o$2925 _o$2926 _o$2927 _o$2928 _o$2929 _o$2930 _o$2931 _o$2932 _o$2933 _o$2934 _o$2935 _o$2936 _o$2937 _o$2938 _o$2939 _o$2940 _o$2941 _o$2942 _o$2943 _o$2944 _o$2945 _o$2946 _o$2947 _o$2948 _o$2949 _o$2950 _o$2951 _o$2952 _o$2953 _o$2954 _o$2955 _o$2956 _o$2957 _o$2958 _o$2959 _o$2960 _o$2961 _o$2962 _o$2963 _o$2964 _o$2965 _o$2966 _o$2967 _o$2968 _o$2969 _o$2970 _o$2971 _o$2972 _o$2973 _o$2974 _o$2975 _o$2976 _o$2977 _o$2978 _o$2979 _o$2980 _o$2981 _o$2982 _o$2983 _o$2984 _o$2985 _o$2986 _o$2987 _o$2988 _o$2989)) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "core-value-procs" (jolt-invoke (var-deref "clojure.core" "merge") (var-deref "jolt.backend-scheme" "native-ops") (let* ((_o$2990 "+") (_o$2991 "jolt-add") (_o$2992 "-") (_o$2993 "jolt-sub") (_o$2994 "*") (_o$2995 "jolt-mul") (_o$2996 "/") (_o$2997 "jolt-div")) (jolt-hash-map _o$2990 _o$2991 _o$2992 _o$2993 _o$2994 _o$2995 _o$2996 _o$2997))) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "op-arity" (let* ((_o$3039 "inc") (_o$3040 (lambda (p__4_) (let fnrec2998 ((p__4_ p__4_)) (jolt= p__4_ 1)))) (_o$3041 "dec") (_o$3042 (lambda (p__5_) (let fnrec2999 ((p__5_ p__5_)) (jolt= p__5_ 1)))) (_o$3043 "not") (_o$3044 (lambda (p__6_) (let fnrec3000 ((p__6_ p__6_)) (jolt= p__6_ 1)))) (_o$3045 "count") (_o$3046 (lambda (p__7_) (let fnrec3001 ((p__7_ p__7_)) (jolt= p__7_ 1)))) (_o$3047 "empty?") (_o$3048 (lambda (p__8_) (let fnrec3002 ((p__8_ p__8_)) (jolt= p__8_ 1)))) (_o$3049 "peek") (_o$3050 (lambda (p__9_) (let fnrec3003 ((p__9_ p__9_)) (jolt= p__9_ 1)))) (_o$3051 "pop") (_o$3052 (lambda (p__10_) (let fnrec3004 ((p__10_ p__10_)) (jolt= p__10_ 1)))) (_o$3053 "mod") (_o$3054 (lambda (p__11_) (let fnrec3005 ((p__11_ p__11_)) (jolt= p__11_ 2)))) (_o$3055 "rem") (_o$3056 (lambda (p__12_) (let fnrec3006 ((p__12_ p__12_)) (jolt= p__12_ 2)))) (_o$3057 "quot") (_o$3058 (lambda (p__13_) (let fnrec3007 ((p__13_ p__13_)) (jolt= p__13_ 2)))) (_o$3059 "contains?") (_o$3060 (lambda (p__14_) (let fnrec3008 ((p__14_ p__14_)) (jolt= p__14_ 2)))) (_o$3061 "get") (_o$3062 (lambda (p__15_) (let fnrec3009 ((p__15_ p__15_)) (let* ((or__14__auto (jolt= p__15_ 2))) (if (jolt-truthy? or__14__auto) or__14__auto (jolt= p__15_ 3)))))) (_o$3063 "nth") (_o$3064 (lambda (p__16_) (let fnrec3010 ((p__16_ p__16_)) (let* ((or__14__auto (jolt= p__16_ 2))) (if (jolt-truthy? or__14__auto) or__14__auto (jolt= p__16_ 3)))))) (_o$3065 "assoc") (_o$3066 (lambda (p__17_) (let fnrec3011 ((p__17_ p__17_)) (let* ((and__13__auto (>= p__17_ 3))) (if (jolt-truthy? and__13__auto) (jolt-odd? p__17_) and__13__auto))))) (_o$3067 "dissoc") (_o$3068 (lambda (p__18_) (let fnrec3012 ((p__18_ p__18_)) (>= p__18_ 1)))) (_o$3069 "conj") (_o$3070 (lambda (p__19_) (let fnrec3013 ((p__19_ p__19_)) (>= p__19_ 1)))) (_o$3071 "first") (_o$3072 (lambda (p__20_) (let fnrec3014 ((p__20_ p__20_)) (jolt= p__20_ 1)))) (_o$3073 "rest") (_o$3074 (lambda (p__21_) (let fnrec3015 ((p__21_ p__21_)) (jolt= p__21_ 1)))) (_o$3075 "next") (_o$3076 (lambda (p__22_) (let fnrec3016 ((p__22_ p__22_)) (jolt= p__22_ 1)))) (_o$3077 "seq") (_o$3078 (lambda (p__23_) (let fnrec3017 ((p__23_ p__23_)) (jolt= p__23_ 1)))) (_o$3079 "reverse") (_o$3080 (lambda (p__24_) (let fnrec3018 ((p__24_ p__24_)) (jolt= p__24_ 1)))) (_o$3081 "last") (_o$3082 (lambda (p__25_) (let fnrec3019 ((p__25_ p__25_)) (jolt= p__25_ 1)))) (_o$3083 "keys") (_o$3084 (lambda (p__26_) (let fnrec3020 ((p__26_ p__26_)) (jolt= p__26_ 1)))) (_o$3085 "vals") (_o$3086 (lambda (p__27_) (let fnrec3021 ((p__27_ p__27_)) (jolt= p__27_ 1)))) (_o$3087 "even?") (_o$3088 (lambda (p__28_) (let fnrec3022 ((p__28_ p__28_)) (jolt= p__28_ 1)))) (_o$3089 "odd?") (_o$3090 (lambda (p__29_) (let fnrec3023 ((p__29_ p__29_)) (jolt= p__29_ 1)))) (_o$3091 "pos?") (_o$3092 (lambda (p__30_) (let fnrec3024 ((p__30_ p__30_)) (jolt= p__30_ 1)))) (_o$3093 "neg?") (_o$3094 (lambda (p__31_) (let fnrec3025 ((p__31_ p__31_)) (jolt= p__31_ 1)))) (_o$3095 "zero?") (_o$3096 (lambda (p__32_) (let fnrec3026 ((p__32_ p__32_)) (jolt= p__32_ 1)))) (_o$3097 "identity") (_o$3098 (lambda (p__33_) (let fnrec3027 ((p__33_ p__33_)) (jolt= p__33_ 1)))) (_o$3099 "cons") (_o$3100 (lambda (p__34_) (let fnrec3028 ((p__34_ p__34_)) (jolt= p__34_ 2)))) (_o$3101 "filter") (_o$3102 (lambda (p__35_) (let fnrec3029 ((p__35_ p__35_)) (jolt= p__35_ 2)))) (_o$3103 "remove") (_o$3104 (lambda (p__36_) (let fnrec3030 ((p__36_ p__36_)) (jolt= p__36_ 2)))) (_o$3105 "into") (_o$3106 (lambda (p__37_) (let fnrec3031 ((p__37_ p__37_)) (jolt= p__37_ 2)))) (_o$3107 "take") (_o$3108 (lambda (p__38_) (let fnrec3032 ((p__38_ p__38_)) (jolt= p__38_ 2)))) (_o$3109 "drop") (_o$3110 (lambda (p__39_) (let fnrec3033 ((p__39_ p__39_)) (jolt= p__39_ 2)))) (_o$3111 "map") (_o$3112 (lambda (p__40_) (let fnrec3034 ((p__40_ p__40_)) (>= p__40_ 2)))) (_o$3113 "apply") (_o$3114 (lambda (p__41_) (let fnrec3035 ((p__41_ p__41_)) (>= p__41_ 2)))) (_o$3115 "reduce") (_o$3116 (lambda (p__42_) (let fnrec3036 ((p__42_ p__42_)) (let* ((or__14__auto (jolt= p__42_ 2))) (if (jolt-truthy? or__14__auto) or__14__auto (jolt= p__42_ 3)))))) (_o$3117 "range") (_o$3118 (lambda (p__43_) (let fnrec3037 ((p__43_ p__43_)) (let* ((and__13__auto (>= p__43_ 0))) (if (jolt-truthy? and__13__auto) (<= p__43_ 3) and__13__auto))))) (_o$3119 "ex-info") (_o$3120 (lambda (p__44_) (let fnrec3038 ((p__44_ p__44_)) (let* ((or__14__auto (jolt= p__44_ 2))) (if (jolt-truthy? or__14__auto) or__14__auto (jolt= p__44_ 3))))))) (jolt-hash-map _o$3039 _o$3040 _o$3041 _o$3042 _o$3043 _o$3044 _o$3045 _o$3046 _o$3047 _o$3048 _o$3049 _o$3050 _o$3051 _o$3052 _o$3053 _o$3054 _o$3055 _o$3056 _o$3057 _o$3058 _o$3059 _o$3060 _o$3061 _o$3062 _o$3063 _o$3064 _o$3065 _o$3066 _o$3067 _o$3068 _o$3069 _o$3070 _o$3071 _o$3072 _o$3073 _o$3074 _o$3075 _o$3076 _o$3077 _o$3078 _o$3079 _o$3080 _o$3081 _o$3082 _o$3083 _o$3084 _o$3085 _o$3086 _o$3087 _o$3088 _o$3089 _o$3090 _o$3091 _o$3092 _o$3093 _o$3094 _o$3095 _o$3096 _o$3097 _o$3098 _o$3099 _o$3100 _o$3101 _o$3102 _o$3103 _o$3104 _o$3105 _o$3106 _o$3107 _o$3108 _o$3109 _o$3110 _o$3111 _o$3112 _o$3113 _o$3114 _o$3115 _o$3116 _o$3117 _o$3118 _o$3119 _o$3120)) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "cmp1-ops" (let* ((_o$3121 "<") (_o$3122 ">") (_o$3123 "<=") (_o$3124 ">=")) (jolt-hash-set _o$3121 _o$3122 _o$3123 _o$3124)) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "supported-host-methods" (let* ((_o$3125 "isDirectory") (_o$3126 "listFiles")) (jolt-hash-set _o$3125 _o$3126)) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "bool-returning-ops" (let* ((_o$3127 "<") (_o$3128 "<=") (_o$3129 ">") (_o$3130 ">=") (_o$3131 "jolt=") (_o$3132 "jolt-not") (_o$3133 "jolt-even?") (_o$3134 "jolt-odd?") (_o$3135 "jolt-pos?") (_o$3136 "jolt-neg?") (_o$3137 "jolt-zero?") (_o$3138 "jolt-empty?") (_o$3139 "jolt-contains?")) (jolt-hash-set _o$3127 _o$3128 _o$3129 _o$3130 _o$3131 _o$3132 _o$3133 _o$3134 _o$3135 _o$3136 _o$3137 _o$3138 _o$3139)) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "prelude-mode?" (jolt-invoke (var-deref "clojure.core" "atom") #f)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "set-prelude-mode!" (letrec ((set-prelude-mode! (lambda (on) (let fnrec3140 ((on on)) (jolt-invoke (var-deref "clojure.core" "reset!") (var-deref "jolt.backend-scheme" "prelude-mode?") on))))) set-prelude-mode!)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "*recur-target*" jolt-nil (jolt-hash-map (keyword #f "dynamic") #t)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "*known-procs*" (jolt-hash-set) (jolt-hash-map (keyword #f "dynamic") #t)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "gensym-counter" (jolt-invoke (var-deref "clojure.core" "atom") 0) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "fresh-label" (letrec ((fresh-label (lambda (prefix) (let fnrec3141 ((prefix prefix)) (jolt-invoke (var-deref "clojure.core" "str") prefix (jolt-invoke (var-deref "clojure.core" "swap!") (var-deref "jolt.backend-scheme" "gensym-counter") jolt-inc)))))) fresh-label)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "scheme-reserved" (let* ((_o$3142 "if") (_o$3143 "begin") (_o$3144 "lambda") (_o$3145 "let") (_o$3146 "let*") (_o$3147 "letrec") (_o$3148 "letrec*") (_o$3149 "quote") (_o$3150 "quasiquote") (_o$3151 "unquote") (_o$3152 "set!") (_o$3153 "define") (_o$3154 "define-syntax") (_o$3155 "cond") (_o$3156 "case") (_o$3157 "when") (_o$3158 "unless") (_o$3159 "and") (_o$3160 "or") (_o$3161 "do") (_o$3162 "else") (_o$3163 "guard") (_o$3164 "parameterize") (_o$3165 "delay") (_o$3166 "values")) (jolt-hash-set _o$3142 _o$3143 _o$3144 _o$3145 _o$3146 _o$3147 _o$3148 _o$3149 _o$3150 _o$3151 _o$3152 _o$3153 _o$3154 _o$3155 _o$3156 _o$3157 _o$3158 _o$3159 _o$3160 _o$3161 _o$3162 _o$3163 _o$3164 _o$3165 _o$3166)) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "munge-name" (letrec ((munge-name (lambda (s) (let fnrec3167 ((s s)) (let* ((s (jolt-invoke (var-deref "clojure.string" "replace") (jolt-invoke (var-deref "clojure.string" "replace") s "#" "_") "'" "_PRIME_"))) (if (jolt-contains? (var-deref "jolt.backend-scheme" "scheme-reserved") s) (jolt-invoke (var-deref "clojure.core" "str") "_" s) s)))))) munge-name)))
(guard (e (#t #f))
  (declare-var! "jolt.backend-scheme" "emit"))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "char-escape" (letrec ((char-escape (lambda (cp) (let fnrec3168 ((cp cp)) (if (jolt= cp 34) "\\\"" (if (jolt= cp 92) "\\\\" (if (jolt= cp 10) "\\n" (if (jolt= cp 9) "\\t" (if (jolt= cp 13) "\\r" (if (jolt-truthy? (let* ((and__13__auto (>= cp 32))) (if (jolt-truthy? and__13__auto) (< cp 127) and__13__auto))) (jolt-invoke (var-deref "clojure.core" "str") (jolt-invoke (var-deref "clojure.core" "char") cp)) (if (jolt-truthy? (keyword #f "else")) (jolt-invoke (var-deref "clojure.core" "str") "\\x" (jolt-invoke (var-deref "clojure.core" "format") "%x" cp) ";") jolt-nil))))))))))) char-escape)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "chez-str-lit" (letrec ((chez-str-lit (lambda (s) (let fnrec3169 ((s s)) (jolt-invoke (var-deref "clojure.core" "str") "\"" (jolt-apply (var-deref "clojure.core" "str") (jolt-map (lambda (c) (let fnrec3170 ((c c)) (jolt-invoke (var-deref "jolt.backend-scheme" "char-escape") (jolt-invoke (var-deref "clojure.core" "int") c)))) s)) "\""))))) chez-str-lit)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-const" (letrec ((emit-const (lambda (v) (let fnrec3171 ((v v)) (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "nil?") v)) "jolt-nil" (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "boolean?") v)) (if (jolt-truthy? v) "#t" "#f") (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "number?") v)) (if (jolt= v +inf.0) "+inf.0" (if (jolt= v -inf.0) "-inf.0" (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "not=") v v)) "+nan.0" (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "float?") v)) (let* ((s (jolt-invoke (var-deref "clojure.core" "str") v))) (if (jolt-truthy? (let* ((or__14__auto (jolt-invoke (var-deref "clojure.string" "includes?") s "."))) (if (jolt-truthy? or__14__auto) or__14__auto (jolt-invoke (var-deref "clojure.string" "includes?") s "e")))) s (jolt-invoke (var-deref "clojure.core" "str") s ".0"))) (if (jolt-truthy? (keyword #f "else")) (jolt-invoke (var-deref "clojure.core" "str") v) jolt-nil))))) (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "string?") v)) (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") v) (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "keyword?") v)) (let* ((temp__4__auto (jolt-invoke (var-deref "clojure.core" "namespace") v))) (if (jolt-truthy? temp__4__auto) (let* ((kns temp__4__auto)) (let* ((_a$3172 (var-deref "clojure.core" "str")) (_a$3173 "(keyword ") (_a$3174 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") kns)) (_a$3175 " ") (_a$3176 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-invoke (var-deref "clojure.core" "name") v))) (_a$3177 ")")) (jolt-invoke _a$3172 _a$3173 _a$3174 _a$3175 _a$3176 _a$3177))) (jolt-invoke (var-deref "clojure.core" "str") "(keyword #f " (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-invoke (var-deref "clojure.core" "name") v)) ")"))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-char?") v)) (jolt-invoke (var-deref "clojure.core" "str") "(integer->char " (jolt-invoke (var-deref "jolt.host" "form-char-code") v) ")") (if (jolt-truthy? (keyword #f "else")) (jolt-throw (let* ((_a$3178 (jolt-invoke (var-deref "clojure.core" "str") "emit-const: unsupported literal " (jolt-invoke (var-deref "clojure.core" "pr-str") v))) (_a$3179 (jolt-hash-map))) (jolt-ex-info _a$3178 _a$3179))) jolt-nil))))))))))) emit-const)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-ordered" (letrec ((emit-ordered (lambda (ctor arg-strs) (let fnrec3180 ((ctor ctor) (arg-strs arg-strs)) (if (< (jolt-count arg-strs) 2) (jolt-invoke (var-deref "clojure.core" "str") "(" ctor (if (jolt-empty? arg-strs) "" (jolt-invoke (var-deref "clojure.core" "str") " " (jolt-invoke (var-deref "clojure.string" "join") " " arg-strs))) ")") (let* ((tmps (jolt-map (lambda (_) (let fnrec3181 ((_ _)) (jolt-invoke (var-deref "jolt.backend-scheme" "fresh-label") "_o$"))) arg-strs)) (binds (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map (lambda (t a) (let fnrec3182 ((t t) (a a)) (jolt-invoke (var-deref "clojure.core" "str") "(" t " " a ")"))) tmps arg-strs)))) (jolt-invoke (var-deref "clojure.core" "str") "(let* (" binds ") (" ctor " " (jolt-invoke (var-deref "clojure.string" "join") " " tmps) "))"))))))) emit-ordered)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "side-effect-free?" (letrec ((side-effect-free? (lambda (n) (let fnrec3183 ((n n)) (let* ((_a$3189 (let* ((_o$3184 (keyword #f "const")) (_o$3185 (keyword #f "local")) (_o$3186 (keyword #f "var")) (_o$3187 (keyword #f "the-var")) (_o$3188 (keyword #f "quote"))) (jolt-hash-set _o$3184 _o$3185 _o$3186 _o$3187 _o$3188))) (_a$3190 (jolt-get n (keyword #f "op")))) (jolt-contains? _a$3189 _a$3190)))))) side-effect-free?)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "needs-order?" (letrec ((needs-order? (lambda (nodes) (let fnrec3191 ((nodes nodes)) (> (jolt-count (jolt-remove (var-deref "jolt.backend-scheme" "side-effect-free?") nodes)) 1))))) needs-order?)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "ordered-call" (letrec ((ordered-call (lambda (nodes strs build) (let fnrec3192 ((nodes nodes) (strs strs) (build build)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.backend-scheme" "needs-order?") nodes)) (let* ((tmps (jolt-invoke (var-deref "clojure.core" "mapv") (lambda (_) (let fnrec3193 ((_ _)) (jolt-invoke (var-deref "jolt.backend-scheme" "fresh-label") "_a$"))) strs)) (binds (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map (lambda (t a) (let fnrec3194 ((t t) (a a)) (jolt-invoke (var-deref "clojure.core" "str") "(" t " " a ")"))) tmps strs)))) (jolt-invoke (var-deref "clojure.core" "str") "(let* (" binds ") " (jolt-invoke build tmps) ")")) (jolt-invoke build strs)))))) ordered-call)))
(guard (e (#t #f))
  (declare-var! "jolt.backend-scheme" "emit-quoted"))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-quoted-map" (letrec ((emit-quoted-map (lambda (pairs) (let fnrec3195 ((pairs pairs)) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-hash-map " (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-invoke (var-deref "clojure.core" "mapcat") (lambda (p) (let fnrec3196 ((p p)) (let* ((_o$3197 (jolt-invoke (var-deref "jolt.backend-scheme" "emit-quoted") (jolt-nth p 0))) (_o$3198 (jolt-invoke (var-deref "jolt.backend-scheme" "emit-quoted") (jolt-nth p 1)))) (jolt-vector _o$3197 _o$3198)))) pairs)) ")"))))) emit-quoted-map)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-quoted-map-value" (letrec ((emit-quoted-map-value (lambda (m) (let fnrec3199 ((m m)) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-hash-map " (jolt-invoke (var-deref "clojure.string" "join") " " (let* ((_a$3203 (var-deref "clojure.core" "mapcat")) (_a$3204 (lambda (k) (let fnrec3200 ((k k)) (let* ((_o$3201 (jolt-invoke (var-deref "jolt.backend-scheme" "emit-quoted") k)) (_o$3202 (jolt-invoke (var-deref "jolt.backend-scheme" "emit-quoted") (jolt-get m k)))) (jolt-vector _o$3201 _o$3202))))) (_a$3205 (jolt-keys m))) (jolt-invoke _a$3203 _a$3204 _a$3205))) ")"))))) emit-quoted-map-value)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-quoted" (letrec ((emit-quoted (lambda (form) (let fnrec3206 ((form form)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-char?") form)) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-const") form) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-literal?") form)) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-const") form) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-sym?") form)) (let* ((m (jolt-invoke (var-deref "jolt.host" "form-sym-meta") form)) (sns (jolt-invoke (var-deref "jolt.host" "form-sym-ns") form)) (nm (jolt-invoke (var-deref "jolt.host" "form-sym-name") form))) (if (jolt-truthy? (let* ((and__13__auto m)) (if (jolt-truthy? and__13__auto) (jolt-pos? (jolt-count m)) and__13__auto))) (let* ((_a$3207 (var-deref "clojure.core" "str")) (_a$3208 "(jolt-symbol/meta ") (_a$3209 (if (jolt-truthy? sns) (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") sns) "#f")) (_a$3210 " ") (_a$3211 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") nm)) (_a$3212 " ") (_a$3213 (jolt-invoke emit-quoted m)) (_a$3214 ")")) (jolt-invoke _a$3207 _a$3208 _a$3209 _a$3210 _a$3211 _a$3212 _a$3213 _a$3214)) (let* ((_a$3215 (var-deref "clojure.core" "str")) (_a$3216 "(jolt-symbol ") (_a$3217 (if (jolt-truthy? sns) (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") sns) "#f")) (_a$3218 " ") (_a$3219 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") nm)) (_a$3220 ")")) (jolt-invoke _a$3215 _a$3216 _a$3217 _a$3218 _a$3219 _a$3220)))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-set?") form)) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-hash-set " (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map emit-quoted (jolt-invoke (var-deref "jolt.host" "form-set-items") form))) ")") (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-list?") form)) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-list " (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map emit-quoted (jolt-invoke (var-deref "jolt.host" "form-elements") form))) ")") (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-vec?") form)) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-vector " (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map emit-quoted (jolt-invoke (var-deref "jolt.host" "form-vec-items") form))) ")") (if (jolt-truthy? (jolt-invoke (var-deref "jolt.host" "form-map?") form)) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-quoted-map") (jolt-invoke (var-deref "jolt.host" "form-map-pairs") form)) (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "map?") form)) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-quoted-map-value") form) (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "vector?") form)) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-vector " (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map emit-quoted form)) ")") (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "set?") form)) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-hash-set " (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map emit-quoted form)) ")") (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "seq?") form)) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-list " (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map emit-quoted form)) ")") (if (jolt-truthy? (keyword #f "else")) (jolt-throw (let* ((_a$3221 (jolt-invoke (var-deref "clojure.core" "str") "emit-quoted: unsupported quoted form " (jolt-invoke (var-deref "clojure.core" "pr-str") form))) (_a$3222 (jolt-hash-map))) (jolt-ex-info _a$3221 _a$3222))) jolt-nil)))))))))))))))) emit-quoted)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "jmeta-nonempty?" (letrec ((jmeta-nonempty? (lambda (m) (let fnrec3223 ((m m)) (let* ((and__13__auto (jolt-invoke (var-deref "clojure.core" "map?") m))) (if (jolt-truthy? and__13__auto) (jolt-pos? (jolt-count m)) and__13__auto)))))) jmeta-nonempty?)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-binding" (letrec ((emit-binding (lambda (b) (let fnrec3224 ((b b)) (let* ((_a$3225 (var-deref "clojure.core" "str")) (_a$3226 "(") (_a$3227 (jolt-invoke (var-deref "jolt.backend-scheme" "munge-name") (jolt-nth b 0))) (_a$3228 " ") (_a$3229 (jolt-invoke (var-deref "jolt.backend-scheme" "emit") (jolt-nth b 1))) (_a$3230 ")")) (jolt-invoke _a$3225 _a$3226 _a$3227 _a$3228 _a$3229 _a$3230)))))) emit-binding)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-let" (letrec ((emit-let (lambda (node) (let fnrec3231 ((node node)) (let* ((kw (if (jolt-truthy? (jolt-get node (keyword #f "letrec"))) "letrec*" "let*"))) (let* ((_a$3232 (var-deref "clojure.core" "str")) (_a$3233 "(") (_a$3234 kw) (_a$3235 " (") (_a$3236 (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map (var-deref "jolt.backend-scheme" "emit-binding") (jolt-get node (keyword #f "bindings"))))) (_a$3237 ") ") (_a$3238 (jolt-invoke (var-deref "jolt.backend-scheme" "emit") (jolt-get node (keyword #f "body")))) (_a$3239 ")")) (jolt-invoke _a$3232 _a$3233 _a$3234 _a$3235 _a$3236 _a$3237 _a$3238 _a$3239))))))) emit-let)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-loop" (letrec ((emit-loop (lambda (node) (let fnrec3240 ((node node)) (let* ((label (jolt-invoke (var-deref "jolt.backend-scheme" "fresh-label") "loop")) (pairs (jolt-get node (keyword #f "bindings"))) (names (jolt-map (lambda (p__45_) (let fnrec3241 ((p__45_ p__45_)) (jolt-invoke (var-deref "jolt.backend-scheme" "munge-name") (jolt-nth p__45_ 0)))) pairs)) (inits (jolt-map (lambda (p__46_) (let fnrec3242 ((p__46_ p__46_)) (jolt-invoke (var-deref "jolt.backend-scheme" "emit") (jolt-nth p__46_ 1)))) pairs)) (seq-bs (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map (lambda (n i) (let fnrec3243 ((n n) (i i)) (jolt-invoke (var-deref "clojure.core" "str") "(" n " " i ")"))) names inits))) (rebinds (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map (lambda (n) (let fnrec3244 ((n n)) (jolt-invoke (var-deref "clojure.core" "str") "(" n " " n ")"))) names))) (body (let* ((frame__8__auto (jolt-invoke (var-deref "clojure.core" "array-map") (jolt-var "jolt.backend-scheme" "*recur-target*") label))) (begin (jolt-invoke (var-deref "clojure.core" "push-thread-bindings") frame__8__auto) (dynamic-wind (lambda () #f) (lambda () (jolt-invoke (var-deref "jolt.backend-scheme" "emit") (jolt-get node (keyword #f "body")))) (lambda () (jolt-invoke (var-deref "clojure.core" "pop-thread-bindings")))))))) (jolt-invoke (var-deref "clojure.core" "str") "(let* (" seq-bs ") (let " label " (" rebinds ") " body "))")))))) emit-loop)))
(guard (e (#t #f))
  (def-var-with-meta! "jolt.backend-scheme" "ffi-types" (let* ((_o$3245 "int") (_o$3246 "int") (_o$3247 "uint") (_o$3248 "unsigned-int") (_o$3249 "long") (_o$3250 "long") (_o$3251 "ulong") (_o$3252 "unsigned-long") (_o$3253 "int64") (_o$3254 "integer-64") (_o$3255 "uint64") (_o$3256 "unsigned-64") (_o$3257 "size_t") (_o$3258 "size_t") (_o$3259 "ssize_t") (_o$3260 "ssize_t") (_o$3261 "iptr") (_o$3262 "iptr") (_o$3263 "uptr") (_o$3264 "uptr") (_o$3265 "double") (_o$3266 "double") (_o$3267 "float") (_o$3268 "float") (_o$3269 "pointer") (_o$3270 "void*") (_o$3271 "void*") (_o$3272 "void*") (_o$3273 "string") (_o$3274 "string") (_o$3275 "void") (_o$3276 "void") (_o$3277 "uint8") (_o$3278 "unsigned-8") (_o$3279 "u8") (_o$3280 "unsigned-8") (_o$3281 "byte") (_o$3282 "unsigned-8") (_o$3283 "char") (_o$3284 "char")) (jolt-hash-map _o$3245 _o$3246 _o$3247 _o$3248 _o$3249 _o$3250 _o$3251 _o$3252 _o$3253 _o$3254 _o$3255 _o$3256 _o$3257 _o$3258 _o$3259 _o$3260 _o$3261 _o$3262 _o$3263 _o$3264 _o$3265 _o$3266 _o$3267 _o$3268 _o$3269 _o$3270 _o$3271 _o$3272 _o$3273 _o$3274 _o$3275 _o$3276 _o$3277 _o$3278 _o$3279 _o$3280 _o$3281 _o$3282 _o$3283 _o$3284)) (jolt-hash-map (keyword #f "private") #t)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "ffi-type->chez" (letrec ((ffi-type->chez (lambda (t) (let fnrec3285 ((t t)) (let* ((or__14__auto (jolt-invoke (var-deref "jolt.backend-scheme" "ffi-types") t))) (if (jolt-truthy? or__14__auto) or__14__auto (jolt-throw (let* ((_a$3286 (jolt-invoke (var-deref "clojure.core" "str") "jolt.ffi: unknown foreign type :" t)) (_a$3287 (jolt-hash-map))) (jolt-ex-info _a$3286 _a$3287))))))))) ffi-type->chez)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-ffi-fn" (letrec ((emit-ffi-fn (lambda (node) (let fnrec3288 ((node node)) (let* ((_a$3289 (var-deref "clojure.core" "str")) (_a$3290 "(foreign-procedure ") (_a$3291 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "csym")))) (_a$3292 " (") (_a$3293 (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map (var-deref "jolt.backend-scheme" "ffi-type->chez") (jolt-get node (keyword #f "argtypes"))))) (_a$3294 ") ") (_a$3295 (jolt-invoke (var-deref "jolt.backend-scheme" "ffi-type->chez") (jolt-get node (keyword #f "rettype")))) (_a$3296 ")")) (jolt-invoke _a$3289 _a$3290 _a$3291 _a$3292 _a$3293 _a$3294 _a$3295 _a$3296)))))) emit-ffi-fn)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-recur" (letrec ((emit-recur (lambda (node) (let fnrec3297 ((node node)) (begin (if (jolt-not (var-deref "jolt.backend-scheme" "*recur-target*")) (jolt-throw (jolt-ex-info "emit: recur outside a loop/fn target" (jolt-hash-map))) jolt-nil) (let* ((arg-nodes (jolt-get node (keyword #f "args")))) (let* ((_a$3299 (var-deref "jolt.backend-scheme" "ordered-call")) (_a$3300 arg-nodes) (_a$3301 (jolt-invoke (var-deref "clojure.core" "mapv") (var-deref "jolt.backend-scheme" "emit") arg-nodes)) (_a$3302 (lambda (as) (let fnrec3298 ((as as)) (jolt-invoke (var-deref "clojure.core" "str") "(" (var-deref "jolt.backend-scheme" "*recur-target*") " " (jolt-invoke (var-deref "clojure.string" "join") " " as) ")"))))) (jolt-invoke _a$3299 _a$3300 _a$3301 _a$3302)))))))) emit-recur)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-arity-clause" (letrec ((emit-arity-clause (lambda (a) (let fnrec3303 ((a a)) (let* ((params (jolt-map (var-deref "jolt.backend-scheme" "munge-name") (jolt-get a (keyword #f "params")))) (restp (let* ((temp__15__auto (jolt-get a (keyword #f "rest")))) (if (jolt-truthy? temp__15__auto) (let* ((r temp__15__auto)) (jolt-invoke (var-deref "jolt.backend-scheme" "munge-name") r)) jolt-nil))) (label (jolt-invoke (var-deref "jolt.backend-scheme" "fresh-label") "fnrec")) (body (let* ((frame__8__auto (jolt-invoke (var-deref "clojure.core" "array-map") (jolt-var "jolt.backend-scheme" "*recur-target*") label))) (begin (jolt-invoke (var-deref "clojure.core" "push-thread-bindings") frame__8__auto) (dynamic-wind (lambda () #f) (lambda () (jolt-invoke (var-deref "jolt.backend-scheme" "emit") (jolt-get a (keyword #f "body")))) (lambda () (jolt-invoke (var-deref "clojure.core" "pop-thread-bindings"))))))) (paramlist (if (jolt-truthy? (let* ((and__13__auto restp)) (if (jolt-truthy? and__13__auto) (jolt-empty? params) and__13__auto))) restp (if (jolt-truthy? restp) (jolt-invoke (var-deref "clojure.core" "str") "(" (jolt-invoke (var-deref "clojure.string" "join") " " params) " . " restp ")") (if (jolt-truthy? (keyword #f "else")) (jolt-invoke (var-deref "clojure.core" "str") "(" (jolt-invoke (var-deref "clojure.string" "join") " " params) ")") jolt-nil)))) (binds (if (jolt-truthy? restp) (let* ((_a$3305 (jolt-map (lambda (p) (let fnrec3304 ((p p)) (jolt-invoke (var-deref "clojure.core" "str") "(" p " " p ")"))) params)) (_a$3306 (jolt-vector (jolt-invoke (var-deref "clojure.core" "str") "(" restp " (list->cseq " restp "))")))) (jolt-concat _a$3305 _a$3306)) (jolt-map (lambda (p) (let fnrec3307 ((p p)) (jolt-invoke (var-deref "clojure.core" "str") "(" p " " p ")"))) params)))) (let* ((_o$3308 paramlist) (_o$3309 (jolt-invoke (var-deref "clojure.core" "str") "(let " label " (" (jolt-invoke (var-deref "clojure.string" "join") " " binds) ") " body ")"))) (jolt-vector _o$3308 _o$3309))))))) emit-arity-clause)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-fn" (letrec ((emit-fn (lambda (node) (let fnrec3310 ((node node)) (let* ((arities (jolt-get node (keyword #f "arities"))) (self (let* ((temp__15__auto (jolt-get node (keyword #f "name")))) (if (jolt-truthy? temp__15__auto) (let* ((nm temp__15__auto)) (jolt-invoke (var-deref "jolt.backend-scheme" "munge-name") nm)) jolt-nil))) (clauses (let* ((frame__8__auto (jolt-invoke (var-deref "clojure.core" "array-map") (jolt-var "jolt.backend-scheme" "*known-procs*") (if (jolt-truthy? self) (jolt-conj (var-deref "jolt.backend-scheme" "*known-procs*") self) (var-deref "jolt.backend-scheme" "*known-procs*"))))) (begin (jolt-invoke (var-deref "clojure.core" "push-thread-bindings") frame__8__auto) (dynamic-wind (lambda () #f) (lambda () (jolt-invoke (var-deref "clojure.core" "mapv") (var-deref "jolt.backend-scheme" "emit-arity-clause") arities)) (lambda () (jolt-invoke (var-deref "clojure.core" "pop-thread-bindings"))))))) (_lambda (if (jolt= 1 (jolt-count clauses)) (let* ((c (jolt-first clauses))) (let* ((_a$3311 (var-deref "clojure.core" "str")) (_a$3312 "(lambda ") (_a$3313 (jolt-nth c 0)) (_a$3314 " ") (_a$3315 (jolt-nth c 1)) (_a$3316 ")")) (jolt-invoke _a$3311 _a$3312 _a$3313 _a$3314 _a$3315 _a$3316))) (jolt-invoke (var-deref "clojure.core" "str") "(case-lambda " (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map (lambda (c) (let fnrec3317 ((c c)) (let* ((_a$3318 (var-deref "clojure.core" "str")) (_a$3319 "(") (_a$3320 (jolt-nth c 0)) (_a$3321 " ") (_a$3322 (jolt-nth c 1)) (_a$3323 ")")) (jolt-invoke _a$3318 _a$3319 _a$3320 _a$3321 _a$3322 _a$3323)))) clauses)) ")")))) (let* ((temp__4__auto (jolt-get node (keyword #f "name")))) (if (jolt-truthy? temp__4__auto) (let* ((nm temp__4__auto)) (let* ((m (jolt-invoke (var-deref "jolt.backend-scheme" "munge-name") nm))) (jolt-invoke (var-deref "clojure.core" "str") "(letrec ((" m " " _lambda ")) " m ")"))) _lambda))))))) emit-fn)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "native-op" (letrec ((native-op (lambda (fnode nargs) (let fnrec3324 ((fnode fnode) (nargs nargs)) (let* ((nm (let* ((G__33 (jolt-get fnode (keyword #f "op")))) (if (jolt= G__33 (keyword #f "var")) (if (jolt= "clojure.core" (jolt-get fnode (keyword #f "ns"))) (jolt-get fnode (keyword #f "name")) jolt-nil) (if (jolt= G__33 (keyword #f "host")) (jolt-get fnode (keyword #f "name")) jolt-nil)))) (op (if (jolt-truthy? nm) (jolt-invoke (var-deref "jolt.backend-scheme" "native-ops") nm) jolt-nil)) (arity-ok (if (jolt-truthy? nm) (jolt-invoke (var-deref "jolt.backend-scheme" "op-arity") nm) jolt-nil))) (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "nil?") op)) jolt-nil (if (jolt-truthy? (let* ((and__13__auto arity-ok)) (if (jolt-truthy? and__13__auto) (jolt-not (jolt-invoke arity-ok nargs)) and__13__auto))) jolt-nil (if (jolt-truthy? (keyword #f "else")) op jolt-nil)))))))) native-op)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "ifn-kind" (letrec ((ifn-kind (lambda (fnode) (let fnrec3325 ((fnode fnode)) (let* ((G__34 (jolt-get fnode (keyword #f "op")))) (if (jolt= G__34 (keyword #f "const")) (if (jolt-truthy? (jolt-invoke (var-deref "clojure.core" "keyword?") (jolt-get fnode (keyword #f "val")))) (keyword #f "keyword") jolt-nil) (if (jolt-truthy? (let* ((or__14__auto (jolt= G__34 (keyword #f "map")))) (if (jolt-truthy? or__14__auto) or__14__auto (let* ((or__14__auto (jolt= G__34 (keyword #f "set")))) (if (jolt-truthy? or__14__auto) or__14__auto (jolt= G__34 (keyword #f "vector"))))))) (keyword #f "coll") jolt-nil))))))) ifn-kind)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "stdlib-var?" (letrec ((stdlib-var? (lambda (n) (let fnrec3326 ((n n)) (let* ((and__13__auto (jolt= (keyword #f "var") (jolt-get n (keyword #f "op"))))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "clojure.string" "starts-with?") (let* ((or__14__auto (jolt-get n (keyword #f "ns")))) (if (jolt-truthy? or__14__auto) or__14__auto "")) "clojure.") and__13__auto)))))) stdlib-var?)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-invoke" (letrec ((emit-invoke (lambda (node) (let fnrec3327 ((node node)) (let* ((fnode (jolt-get node (keyword #f "fn"))) (arg-nodes (jolt-get node (keyword #f "args"))) (args (jolt-invoke (var-deref "clojure.core" "mapv") (var-deref "jolt.backend-scheme" "emit") arg-nodes)) (nop (jolt-invoke (var-deref "jolt.backend-scheme" "native-op") fnode (jolt-count args))) (kind (jolt-invoke (var-deref "jolt.backend-scheme" "ifn-kind") fnode)) (order-args (lambda (build) (let fnrec3328 ((build build)) (jolt-invoke (var-deref "jolt.backend-scheme" "ordered-call") arg-nodes args build)))) (defstr (lambda (as) (let fnrec3329 ((as as)) (if (> (jolt-count as) 1) (jolt-invoke (var-deref "clojure.core" "str") " " (jolt-nth as 1)) "")))) (invoke (lambda () (let fnrec3330 () (let* ((_a$3332 (var-deref "jolt.backend-scheme" "ordered-call")) (_a$3333 (jolt-cons fnode arg-nodes)) (_a$3334 (jolt-cons (jolt-invoke (var-deref "jolt.backend-scheme" "emit") fnode) args)) (_a$3335 (lambda (G__35) (let fnrec3331 ((G__35 G__35)) (let* ((G__36 G__35) (f (jolt-nth G__36 0 jolt-nil)) (as (jolt-invoke (var-deref "clojure.core" "nthnext") G__36 1))) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-invoke " f (if (jolt-truthy? (jolt-seq as)) (jolt-invoke (var-deref "clojure.core" "str") " " (jolt-invoke (var-deref "clojure.string" "join") " " as)) "") ")")))))) (jolt-invoke _a$3332 _a$3333 _a$3334 _a$3335)))))) (if (jolt-truthy? (let* ((and__13__auto nop)) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-empty? args))) (if (jolt-truthy? and__13__auto) (jolt= nop "+") and__13__auto)) and__13__auto))) "0" (if (jolt-truthy? (let* ((and__13__auto nop)) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt-empty? args))) (if (jolt-truthy? and__13__auto) (jolt= nop "*") and__13__auto)) and__13__auto))) "1" (if (jolt-truthy? (let* ((and__13__auto nop)) (if (jolt-truthy? and__13__auto) (let* ((and__13__auto (jolt= 1 (jolt-count args)))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.backend-scheme" "cmp1-ops") nop) and__13__auto)) and__13__auto))) (jolt-invoke (var-deref "clojure.core" "str") "(begin " (jolt-first args) " #t)") (if (jolt-truthy? nop) (jolt-invoke order-args (lambda (as) (let fnrec3336 ((as as)) (jolt-invoke (var-deref "clojure.core" "str") "(" nop " " (jolt-invoke (var-deref "clojure.string" "join") " " as) ")")))) (if (jolt= kind (keyword #f "keyword")) (jolt-invoke order-args (lambda (as) (let fnrec3337 ((as as)) (let* ((_a$3338 (var-deref "clojure.core" "str")) (_a$3339 "(jolt-get ") (_a$3340 (jolt-first as)) (_a$3341 " ") (_a$3342 (jolt-invoke (var-deref "jolt.backend-scheme" "emit") fnode)) (_a$3343 (jolt-invoke defstr as)) (_a$3344 ")")) (jolt-invoke _a$3338 _a$3339 _a$3340 _a$3341 _a$3342 _a$3343 _a$3344))))) (if (jolt= kind (keyword #f "coll")) (let* ((_a$3346 (var-deref "jolt.backend-scheme" "ordered-call")) (_a$3347 (jolt-cons fnode arg-nodes)) (_a$3348 (jolt-cons (jolt-invoke (var-deref "jolt.backend-scheme" "emit") fnode) args)) (_a$3349 (lambda (G__37) (let fnrec3345 ((G__37 G__37)) (let* ((G__38 G__37) (c (jolt-nth G__38 0 jolt-nil)) (as (jolt-invoke (var-deref "clojure.core" "nthnext") G__38 1))) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-get " c " " (jolt-invoke (var-deref "clojure.string" "join") " " as) ")")))))) (jolt-invoke _a$3346 _a$3347 _a$3348 _a$3349)) (if (jolt-truthy? (let* ((and__13__auto (jolt-invoke (var-deref "jolt.backend-scheme" "stdlib-var?") fnode))) (if (jolt-truthy? and__13__auto) (jolt-not (jolt-invoke (var-deref "clojure.core" "deref") (var-deref "jolt.backend-scheme" "prelude-mode?"))) and__13__auto))) (jolt-throw (let* ((_a$3356 (let* ((_a$3350 (var-deref "clojure.core" "str")) (_a$3351 "emit: unsupported stdlib fn `") (_a$3352 (jolt-get fnode (keyword #f "ns"))) (_a$3353 "/") (_a$3354 (jolt-get fnode (keyword #f "name"))) (_a$3355 "` (no core on Chez yet)")) (jolt-invoke _a$3350 _a$3351 _a$3352 _a$3353 _a$3354 _a$3355))) (_a$3357 (jolt-hash-map))) (jolt-ex-info _a$3356 _a$3357))) (if (jolt= (keyword #f "host-static") (jolt-get fnode (keyword #f "op"))) (jolt-invoke order-args (lambda (as) (let fnrec3358 ((as as)) (let* ((_a$3359 (var-deref "clojure.core" "str")) (_a$3360 "(host-static-call ") (_a$3361 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get fnode (keyword #f "class")))) (_a$3362 " ") (_a$3363 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get fnode (keyword #f "member")))) (_a$3364 (if (jolt-empty? as) "" (jolt-invoke (var-deref "clojure.core" "str") " " (jolt-invoke (var-deref "clojure.string" "join") " " as)))) (_a$3365 ")")) (jolt-invoke _a$3359 _a$3360 _a$3361 _a$3362 _a$3363 _a$3364 _a$3365))))) (if (jolt= (keyword #f "host") (jolt-get fnode (keyword #f "op"))) (jolt-throw (let* ((_a$3366 (jolt-invoke (var-deref "clojure.core" "str") "emit: unsupported host call `" (jolt-get fnode (keyword #f "name")) "`")) (_a$3367 (jolt-hash-map))) (jolt-ex-info _a$3366 _a$3367))) (if (jolt-truthy? (let* ((and__13__auto (jolt= (keyword #f "local") (jolt-get fnode (keyword #f "op"))))) (if (jolt-truthy? and__13__auto) (jolt-not (jolt-invoke (var-deref "jolt.backend-scheme" "*known-procs*") (jolt-invoke (var-deref "jolt.backend-scheme" "munge-name") (jolt-get fnode (keyword #f "name"))))) and__13__auto))) (jolt-invoke invoke) (if (jolt= (keyword #f "var") (jolt-get fnode (keyword #f "op"))) (jolt-invoke invoke) (if (jolt-truthy? (keyword #f "else")) (jolt-invoke invoke) jolt-nil))))))))))))))))) emit-invoke)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit-try" (letrec ((emit-try (lambda (node) (let fnrec3368 ((node node)) (let* ((core (let* ((temp__4__auto (jolt-get node (keyword #f "catch-sym")))) (if (jolt-truthy? temp__4__auto) (let* ((cs temp__4__auto)) (let* ((_a$3369 (var-deref "clojure.core" "str")) (_a$3370 "(guard (") (_a$3371 (jolt-invoke (var-deref "jolt.backend-scheme" "munge-name") cs)) (_a$3372 " (else ") (_a$3373 (jolt-invoke (var-deref "jolt.backend-scheme" "emit") (jolt-get node (keyword #f "catch-body")))) (_a$3374 ")) ") (_a$3375 (jolt-invoke (var-deref "jolt.backend-scheme" "emit") (jolt-get node (keyword #f "body")))) (_a$3376 ")")) (jolt-invoke _a$3369 _a$3370 _a$3371 _a$3372 _a$3373 _a$3374 _a$3375 _a$3376))) (jolt-invoke (var-deref "jolt.backend-scheme" "emit") (jolt-get node (keyword #f "body"))))))) (let* ((temp__4__auto (jolt-get node (keyword #f "finally")))) (if (jolt-truthy? temp__4__auto) (let* ((fin temp__4__auto)) (jolt-invoke (var-deref "clojure.core" "str") "(dynamic-wind (lambda () #f) (lambda () " core ") (lambda () " (jolt-invoke (var-deref "jolt.backend-scheme" "emit") fin) "))")) core))))))) emit-try)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "returns-scheme-bool?" (letrec ((returns-scheme-bool? (lambda (node) (let fnrec3377 ((node node)) (if (jolt-truthy? (let* ((and__13__auto (jolt= (keyword #f "const") (jolt-get node (keyword #f "op"))))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "clojure.core" "boolean?") (jolt-get node (keyword #f "val"))) and__13__auto))) #t (if (jolt= (keyword #f "invoke") (jolt-get node (keyword #f "op"))) (let* ((nop (let* ((_a$3378 (var-deref "jolt.backend-scheme" "native-op")) (_a$3379 (jolt-get node (keyword #f "fn"))) (_a$3380 (jolt-count (jolt-get node (keyword #f "args"))))) (jolt-invoke _a$3378 _a$3379 _a$3380)))) (if (jolt-truthy? (let* ((and__13__auto nop)) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.backend-scheme" "bool-returning-ops") nop) and__13__auto))) #t #f)) (if (jolt-truthy? (keyword #f "else")) #f jolt-nil))))))) returns-scheme-bool?)))
(guard (e (#t #f))
  (def-var! "jolt.backend-scheme" "emit" (letrec ((emit (lambda (node) (let fnrec3381 ((node node)) (let* ((G__39 (jolt-get node (keyword #f "op")))) (if (jolt= G__39 (keyword #f "const")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-const") (jolt-get node (keyword #f "val"))) (if (jolt= G__39 (keyword #f "local")) (jolt-invoke (var-deref "jolt.backend-scheme" "munge-name") (jolt-get node (keyword #f "name"))) (if (jolt= G__39 (keyword #f "var")) (let* ((core-proc (let* ((and__13__auto (jolt= "clojure.core" (jolt-get node (keyword #f "ns"))))) (if (jolt-truthy? and__13__auto) (jolt-invoke (var-deref "jolt.backend-scheme" "core-value-procs") (jolt-get node (keyword #f "name"))) and__13__auto)))) (if (jolt-truthy? core-proc) core-proc (if (jolt-truthy? (let* ((and__13__auto (jolt-invoke (var-deref "jolt.backend-scheme" "stdlib-var?") node))) (if (jolt-truthy? and__13__auto) (jolt-not (jolt-invoke (var-deref "clojure.core" "deref") (var-deref "jolt.backend-scheme" "prelude-mode?"))) and__13__auto))) (jolt-throw (let* ((_a$3388 (let* ((_a$3382 (var-deref "clojure.core" "str")) (_a$3383 "emit: unsupported stdlib ref `") (_a$3384 (jolt-get node (keyword #f "ns"))) (_a$3385 "/") (_a$3386 (jolt-get node (keyword #f "name"))) (_a$3387 "` (no core on Chez yet)")) (jolt-invoke _a$3382 _a$3383 _a$3384 _a$3385 _a$3386 _a$3387))) (_a$3389 (jolt-hash-map))) (jolt-ex-info _a$3388 _a$3389))) (if (jolt-truthy? (keyword #f "else")) (let* ((_a$3390 (var-deref "clojure.core" "str")) (_a$3391 "(var-deref ") (_a$3392 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "ns")))) (_a$3393 " ") (_a$3394 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "name")))) (_a$3395 ")")) (jolt-invoke _a$3390 _a$3391 _a$3392 _a$3393 _a$3394 _a$3395)) jolt-nil)))) (if (jolt= G__39 (keyword #f "the-var")) (let* ((_a$3396 (var-deref "clojure.core" "str")) (_a$3397 "(jolt-var ") (_a$3398 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "ns")))) (_a$3399 " ") (_a$3400 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "name")))) (_a$3401 ")")) (jolt-invoke _a$3396 _a$3397 _a$3398 _a$3399 _a$3400 _a$3401)) (if (jolt= G__39 (keyword #f "set-var")) (let* ((_a$3402 (var-deref "clojure.core" "str")) (_a$3403 "(jolt-var-set ") (_a$3404 (jolt-invoke emit (jolt-get node (keyword #f "the-var")))) (_a$3405 " ") (_a$3406 (jolt-invoke emit (jolt-get node (keyword #f "val")))) (_a$3407 ")")) (jolt-invoke _a$3402 _a$3403 _a$3404 _a$3405 _a$3406 _a$3407)) (if (jolt= G__39 (keyword #f "set-field")) (let* ((_a$3408 (var-deref "clojure.core" "str")) (_a$3409 "(jolt-set-field! ") (_a$3410 (jolt-invoke emit (jolt-get node (keyword #f "obj")))) (_a$3411 " (keyword #f ") (_a$3412 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "field")))) (_a$3413 ") ") (_a$3414 (jolt-invoke emit (jolt-get node (keyword #f "val")))) (_a$3415 ")")) (jolt-invoke _a$3408 _a$3409 _a$3410 _a$3411 _a$3412 _a$3413 _a$3414 _a$3415)) (if (jolt= G__39 (keyword #f "defmacro")) (let* ((_a$3416 (var-deref "clojure.core" "str")) (_a$3417 "(begin (def-var! ") (_a$3418 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "ns")))) (_a$3419 " ") (_a$3420 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "name")))) (_a$3421 " ") (_a$3422 (jolt-invoke emit (jolt-get node (keyword #f "fn")))) (_a$3423 ") (mark-macro! ") (_a$3424 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "ns")))) (_a$3425 " ") (_a$3426 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "name")))) (_a$3427 ") jolt-nil)")) (jolt-invoke _a$3416 _a$3417 _a$3418 _a$3419 _a$3420 _a$3421 _a$3422 _a$3423 _a$3424 _a$3425 _a$3426 _a$3427)) (if (jolt= G__39 (keyword #f "host")) (jolt-throw (let* ((_a$3428 (jolt-invoke (var-deref "clojure.core" "str") "emit: unsupported host ref `" (jolt-get node (keyword #f "name")) "`")) (_a$3429 (jolt-hash-map))) (jolt-ex-info _a$3428 _a$3429))) (if (jolt= G__39 (keyword #f "host-static")) (let* ((_a$3430 (var-deref "clojure.core" "str")) (_a$3431 "(host-static-ref ") (_a$3432 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "class")))) (_a$3433 " ") (_a$3434 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "member")))) (_a$3435 ")")) (jolt-invoke _a$3430 _a$3431 _a$3432 _a$3433 _a$3434 _a$3435)) (if (jolt= G__39 (keyword #f "host-new")) (let* ((_a$3436 (var-deref "clojure.core" "str")) (_a$3437 "(host-new ") (_a$3438 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "class")))) (_a$3439 (let* ((args (jolt-map emit (jolt-get node (keyword #f "args"))))) (if (jolt-empty? args) "" (jolt-invoke (var-deref "clojure.core" "str") " " (jolt-invoke (var-deref "clojure.string" "join") " " args))))) (_a$3440 ")")) (jolt-invoke _a$3436 _a$3437 _a$3438 _a$3439 _a$3440)) (if (jolt= G__39 (keyword #f "if")) (let* ((test (jolt-get node (keyword #f "test"))) (t (if (jolt-truthy? (jolt-invoke (var-deref "jolt.backend-scheme" "returns-scheme-bool?") test)) (jolt-invoke emit test) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-truthy? " (jolt-invoke emit test) ")")))) (let* ((_a$3441 (var-deref "clojure.core" "str")) (_a$3442 "(if ") (_a$3443 t) (_a$3444 " ") (_a$3445 (jolt-invoke emit (jolt-get node (keyword #f "then")))) (_a$3446 " ") (_a$3447 (jolt-invoke emit (jolt-get node (keyword #f "else")))) (_a$3448 ")")) (jolt-invoke _a$3441 _a$3442 _a$3443 _a$3444 _a$3445 _a$3446 _a$3447 _a$3448))) (if (jolt= G__39 (keyword #f "do")) (let* ((_a$3449 (var-deref "clojure.core" "str")) (_a$3450 "(begin ") (_a$3451 (jolt-invoke (var-deref "clojure.string" "join") " " (jolt-map emit (jolt-get node (keyword #f "statements"))))) (_a$3452 (if (jolt-empty? (jolt-get node (keyword #f "statements"))) "" " ")) (_a$3453 (jolt-invoke emit (jolt-get node (keyword #f "ret")))) (_a$3454 ")")) (jolt-invoke _a$3449 _a$3450 _a$3451 _a$3452 _a$3453 _a$3454)) (if (jolt= G__39 (keyword #f "invoke")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-invoke") node) (if (jolt= G__39 (keyword #f "vector")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-ordered") "jolt-vector" (jolt-map emit (jolt-get node (keyword #f "items")))) (if (jolt= G__39 (keyword #f "set")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-ordered") "jolt-hash-set" (jolt-map emit (jolt-get node (keyword #f "items")))) (if (jolt= G__39 (keyword #f "map")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-ordered") "jolt-hash-map" (let* ((_a$3458 (var-deref "clojure.core" "mapcat")) (_a$3459 (lambda (p) (let fnrec3455 ((p p)) (let* ((_o$3456 (jolt-invoke emit (jolt-nth p 0))) (_o$3457 (jolt-invoke emit (jolt-nth p 1)))) (jolt-vector _o$3456 _o$3457))))) (_a$3460 (jolt-get node (keyword #f "pairs")))) (jolt-invoke _a$3458 _a$3459 _a$3460))) (if (jolt= G__39 (keyword #f "quote")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-quoted") (jolt-get node (keyword #f "form"))) (if (jolt= G__39 (keyword #f "throw")) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-throw " (jolt-invoke emit (jolt-get node (keyword #f "expr"))) ")") (if (jolt= G__39 (keyword #f "try")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-try") node) (if (jolt= G__39 (keyword #f "regex")) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-regex " (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "source"))) ")") (if (jolt= G__39 (keyword #f "inst")) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-inst-from-string " (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "source"))) ")") (if (jolt= G__39 (keyword #f "uuid")) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-uuid-from-string " (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "source"))) ")") (if (jolt= G__39 (keyword #f "bigdec")) (jolt-invoke (var-deref "clojure.core" "str") "(jolt-bigdec-from-string " (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "source"))) ")") (if (jolt= G__39 (keyword #f "the-ns")) (jolt-invoke (var-deref "clojure.core" "str") "(intern-ns! " (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "name"))) ")") (if (jolt= G__39 (keyword #f "host-call")) (let* ((m (jolt-get node (keyword #f "method"))) (target (jolt-invoke emit (jolt-get node (keyword #f "target")))) (args (jolt-map emit (jolt-get node (keyword #f "args"))))) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.backend-scheme" "supported-host-methods") m)) (let* ((_a$3461 (var-deref "clojure.core" "str")) (_a$3462 "(jolt-host-call ") (_a$3463 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") m)) (_a$3464 " ") (_a$3465 target) (_a$3466 (if (jolt-empty? args) "" (jolt-invoke (var-deref "clojure.core" "str") " " (jolt-invoke (var-deref "clojure.string" "join") " " args)))) (_a$3467 ")")) (jolt-invoke _a$3461 _a$3462 _a$3463 _a$3464 _a$3465 _a$3466 _a$3467)) (let* ((_a$3468 (var-deref "clojure.core" "str")) (_a$3469 "(record-method-dispatch ") (_a$3470 target) (_a$3471 " ") (_a$3472 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") m)) (_a$3473 " (jolt-vector") (_a$3474 (if (jolt-empty? args) "" (jolt-invoke (var-deref "clojure.core" "str") " " (jolt-invoke (var-deref "clojure.string" "join") " " args)))) (_a$3475 "))")) (jolt-invoke _a$3468 _a$3469 _a$3470 _a$3471 _a$3472 _a$3473 _a$3474 _a$3475)))) (if (jolt= G__39 (keyword #f "let")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-let") node) (if (jolt= G__39 (keyword #f "loop")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-loop") node) (if (jolt= G__39 (keyword #f "recur")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-recur") node) (if (jolt= G__39 (keyword #f "ffi-fn")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-ffi-fn") node) (if (jolt= G__39 (keyword #f "fn")) (jolt-invoke (var-deref "jolt.backend-scheme" "emit-fn") node) (if (jolt= G__39 (keyword #f "def")) (if (jolt-truthy? (jolt-get node (keyword #f "no-init"))) (let* ((_a$3476 (var-deref "clojure.core" "str")) (_a$3477 "(declare-var! ") (_a$3478 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "ns")))) (_a$3479 " ") (_a$3480 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "name")))) (_a$3481 ")")) (jolt-invoke _a$3476 _a$3477 _a$3478 _a$3479 _a$3480 _a$3481)) (if (jolt-truthy? (jolt-invoke (var-deref "jolt.backend-scheme" "jmeta-nonempty?") (jolt-get node (keyword #f "meta")))) (let* ((_a$3482 (var-deref "clojure.core" "str")) (_a$3483 "(def-var-with-meta! ") (_a$3484 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "ns")))) (_a$3485 " ") (_a$3486 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "name")))) (_a$3487 " ") (_a$3488 (jolt-invoke emit (jolt-get node (keyword #f "init")))) (_a$3489 " ") (_a$3490 (jolt-invoke (var-deref "jolt.backend-scheme" "emit-quoted") (jolt-get node (keyword #f "meta")))) (_a$3491 ")")) (jolt-invoke _a$3482 _a$3483 _a$3484 _a$3485 _a$3486 _a$3487 _a$3488 _a$3489 _a$3490 _a$3491)) (if (jolt-truthy? (keyword #f "else")) (let* ((_a$3492 (var-deref "clojure.core" "str")) (_a$3493 "(def-var! ") (_a$3494 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "ns")))) (_a$3495 " ") (_a$3496 (jolt-invoke (var-deref "jolt.backend-scheme" "chez-str-lit") (jolt-get node (keyword #f "name")))) (_a$3497 " ") (_a$3498 (jolt-invoke emit (jolt-get node (keyword #f "init")))) (_a$3499 ")")) (jolt-invoke _a$3492 _a$3493 _a$3494 _a$3495 _a$3496 _a$3497 _a$3498 _a$3499)) jolt-nil))) (jolt-throw (let* ((_a$3500 (jolt-invoke (var-deref "clojure.core" "str") "emit: op not yet ported / unhandled: " (jolt-invoke (var-deref "clojure.core" "pr-str") (jolt-get node (keyword #f "op"))))) (_a$3501 (jolt-hash-map))) (jolt-ex-info _a$3500 _a$3501))))))))))))))))))))))))))))))))))))))) emit)))