0.0
No commit activity in last 3 years
No release in over 3 years
reincarnation for classes and modules
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

 Project Readme

reincarnation

monkey patch existing class and modules with the added comfort of "super". in other words: you shouldn't even consider using this.

example for classes:

require 'reincarnation'

class Abc
  def foo
    "foo"
  end
end

Abc.reincarnate

class Abc
  def foo
    puts super
  end
end

Abc.new.foo

example for modules:

require 'reincarnation'

module Boo
  def bar
    "bar"
  end
end

Boo.reincarnate

module Boo
  def bar
    puts super
  end
end

class BooTest
  include Boo
end

BooTest.new.bar

MIT license