Sha256: efce764e2997ec90156316a1d6cdfa2a80a6c9a02c3175417bfa4adb763fedfe

Contents?: true

Size: 355 Bytes

Versions: 1

Compression:

Stored size: 355 Bytes

Contents

# $Id: first.rb 25 2007-08-15 14:18:09Z yuyakato $

require "rubygems"
require "kagemusha"

musha = Kagemusha.new(Time)
musha.defs(:now) { self.local(1984, 5, 11) }
musha.def(:+) { |other| other }

p Time.now
p Time.now + 60 * 60 * 24

puts "---"

musha.swap {
  p Time.now
  p Time.now + 60 * 60 * 24
}

puts "---"

p Time.now
p Time.now + 60 * 60 * 24

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
kagemusha-0.0.1 examples/first.rb