Skip to content

Instantly share code, notes, and snippets.

@TikiTDO
Last active August 29, 2015 14:03
Show Gist options
  • Select an option

  • Save TikiTDO/56d15c3e2584ab119def to your computer and use it in GitHub Desktop.

Select an option

Save TikiTDO/56d15c3e2584ab119def to your computer and use it in GitHub Desktop.
Blank ruby class
class Blank
core_methods = %w(__id__ __send__ object_id instance_eval methods class nil? is_a?
respond_to?)
instance_methods.each {|m| undef_method(m) unless core_methods.include?(m.to_s)}
def respond_to_missing?
true
end
def method_missing(name, *args, &block)
puts name
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment