Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
;; TODO need to refactor this to put the entire let into the macro and use gensym form to escape
(defmacro apply-by-next-n-bar
"Schedule a function by n bars in the future"
[m bar-period & rest]
(let [
next-bar-num (metro-next-periodic-bar m bar-period)
`(apply-by-bar ~m ~next-bar-num ~@rest)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment