impc:ti:multicset   scheme


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/runtime/llvmti.xtm

Implementation

(define (impc:ti:multicset args)
  `(let ,(map (lambda (a b n)
                (list (string->symbol (string-append "f" (number->string n) ":[void]*"))
                      (list (string->symbol
                             (string-append
                              (if (= n 0)
                                  (symbol->string a)
                                  (string-append "f" (number->string (- n 1))))
                              "." (symbol->string b))))))
              (reverse (cddddr (reverse args)))
              (cdr (reverse (cdr (reverse args))))
              (range (length (cdddr args))))
        (,(string->symbol (string-append "f" (number->string (- (length (cddddr args)) 1)) "."
                                         (symbol->string (caddr (reverse args)))
                                         ":" (symbol->string (cadr (reverse args)))))
          ,(car (reverse args)))))


Back to Index