stdlib/console.rb
# Time the given block with the given label.
Time the given block with the given label.
Time the given block with the given label .
def time(label, &block)
    raise ArgumentError, 'no block given' unless block
    `#{@native}.time(label)`
    begin
      if block.arity == 0
        instance_exec(&block)
      else
        yield(self)
      end
    ensure
      `#{@native}.timeEnd()`
    end
  end
def time ( label , & block ) raise ArgumentError , 'no block given' unless block ` #{ @native } .time(label) ` begin if block . arity == 0 instance_exec ( & block ) else yield ( self ) end ensure ` #{ @native } .timeEnd() ` end end
Time the given block with the given label.
Time the given block with the given label .
label
<not_specific>
block
<not_specific>