Avoid creating a Queue instance for every Future

Instead just use the queue in #value as a local lock. Since using #value is pretty rare it's better to create a Queue instance every time it's called, than creating one for every future created.
Inline wait/signal logic in Future#value

Instead of using Queue as a signalling mechanism, just do it a bit closer to the metal.
Reuse the existing mutex in Future#value
Lock less in Future

Don't lock while running complete and failure listeners that are added after the future has been completed or failed
Avoid saving a future's complete and failure listeners when not needed
Make Future#value a little bit safer

It's unclear what Mutex#sleep really guarantees, so run it in a loop if it spuriously wakes up.
Fix thread safety errors in IoReactor

Don't clear out closed sockets and completed timers without locking -- but to avoid having to take the lock in the reactor thread, clear them out when adding new.