Slide 8
Slide 8 text
# File: timeout.rb
module Timeout
def timeout(sec, klass = nil) #:yield: +sec+
# Implementation of the timeout functionality
end
module_function :timeout
end
# Identical to:
#
# Timeout::timeout(n, e, &block).
#
# This method is deprecated and provided only for backwards compatibility.
# You should use Timeout#timeout instead.
def timeout(n, e = nil, &block)
Timeout::timeout(n, e, &block)
end
Global
Namespace
Pollution!