Open adamvy-google opened 8 years ago
Pass subscription or subscription destructor as extra argument to listeners so that they can easily unsubscribe without throwing an Exception. Will avoid the use of non-error Exceptions and will be faster because try/catch blocks disable V8 JIT.
Isn't it only finally
that destroys optimizations? In any case, we should do this.
No, try/catch is sufficient: http://www.html5rocks.com/en/tutorials/speed/v8/
Use some programatic means of unsubscribing.