Fork me on GitHub

is there an a/map but meant more fore side-effecting? I have a channel I want to map over, but I don't care about returning anything, and the fn passed to my "`map`" is useful only for it's side-effects.


The single-arity version of map gives you a transducer, and transduce is eager so it supports side effects. See I would probably just use loop/`recur` and call the function.


would someone consider this to be a bug, or just "you shouldn't do it" kinda thing?

(defmacro bug-loop []
  (go-loop []))
=> java.lang.IllegalArgumentException
   Unable to resolve classname: LinkedList


you're running a go-loop during macroexpansion, did you mean to quote

`(go-loop [])


either way - "you shouldn't do it" 🙂


yes, I did quote, but Im doing a macro where I convert symbols to text, so as soon as its quoted and unquoted everything goes south. Im doing so much macro hacking that I would rather nobody knew about it (and nobody will see it except me). I can use normal loop in this case. But if a go-loop should work like this is 99,999% no problem for anyone.


same goes for go inside macro but not <!! or any other async function.