class Async::IO

def wrap_blocking_method(new_name, method_name, &block)

Invokes `$2` on the underlying {io}. If the operation would block, the current task is paused until the operation can succeed, at which point it's resumed and the operation is completed.
@method $1
@!macro [attach] wrap_blocking_method
def wrap_blocking_method(new_name, method_name, &block)
	if block_given?
		define_method(new_name, &block)
	else
		define_method(new_name) do |*args|
			async_send(method_name, *args)
		end
	end
end