(defmacro event-handler (link: argsv & body)
`(reify EventHandler (~'handle ~argsv ~@body)))
(macroexpand
'(macrolet (link: (add-handler [& body)
`(event-handler
(link: ~'this ~'e) ~@body))]
(add-handler 1)))
results in (notice the extra paren after handle
and before (link: this e)
):
(do (reify* (link: javafx.event.EventHandler) (handle ((link: this e) 1))))