Skip to content

Instantly share code, notes, and snippets.

@bosskovic
Forked from svenfuchs/gist:247648
Created August 15, 2013 09:46
Show Gist options
  • Save bosskovic/6239658 to your computer and use it in GitHub Desktop.
Save bosskovic/6239658 to your computer and use it in GitHub Desktop.
module Base
def listen
puts "think: interesting stuff ..."
end
end
class Attendee
include Base
end
module Tweets
def listen
super
puts "tweet: great conference! :D"
end
end
module Applause
def listen
super
puts "applause!"
end
end
attendee = Attendee.new
class Attendee
include Tweets
include Applause
end
attendee.listen
# think: interesting stuff ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment