class Async::Scheduler

def run(...)

Run the reactor until all tasks are finished. Proxies arguments to {#async} immediately before entering the loop, if a block is provided.
def run(...)
	Kernel::raise ClosedError if @selector.nil?
	
	initial_task = self.async(...) if block_given?
	
	@interrupted = false
	
	while self.run_once
		if @interrupted
			break
		end
	end
	
	return initial_task
ensure
	Console.logger.debug(self) {"Exiting run-loop because #{$! ? $! : 'finished'}."}
end