I'm wondering if it'd be possible to have some sort of Lazy instantiation of EventListener? It's often the case that I call removeEventListener in the body of an event listener, which requires having a handle to the event listener.
Conceptually laziness seems to be safe, as I don't think an EventListener can be called during the same tick as its creation without some unsafeCoerce-ery. At the same time, I'm not quite sure how to implement that API wise. I'm pretty sure there's a language extension that accomplishes this in Haskell (when you have a left-binded expression that refers to its own variable name) but I forget the name.