Class: Object
- Inherits:
- BasicObject
- Defined in:
- lib/goodsheet/aux.rb
Instance Method Summary collapse
Instance Method Details
#chrono(msg, &block) ⇒ Object
2 3 4 5 6 7 8 9 |
# File 'lib/goodsheet/aux.rb', line 2 def chrono(msg, &block) puts "--------- starting #{msg} -------->" t = Time.now yield delta_t = Time.now-t puts "<-------- #{msg} takes #{delta_t}s" return delta_t end |