opensoul.org

Raise the roof, yo!

Check out this awesome abuse of Ruby syntax from Don Petersen:

module Kernel
  def the(a, b)
    a.new(b)
  end

  def roof
    Exception
  end

  def yo!
    "Get your hands in the air, wave them like..."
  end
end
 
raise the roof, yo!
# Exception: Get your hands in the air, wave them like...

ruby and tidbit December 05, 2010

6 Comments

  1. Steve Smith Steve Smith December 5, 2010

    Awe. Some.

  2. Kieran P Kieran P December 5, 2010

    Haha. It’s always neat to see these things.

    Now try  ’the roof, the roof, the roof is on fire!’  :-P

  3. Rcoder Rcoder December 6, 2010

    LOL … :D

  4. Sam Figueroa Sam Figueroa December 6, 2010

    You just have to love it. Very cool.

  5. Jim Myhrberg Jim Myhrberg December 6, 2010

    Like Steve said: Awe. Some. :D

  6. Henning Koch Henning Koch December 6, 2010

    This is great.

Post a Comment

Comments use textile. Anonymous comments will be deleted.

My name is Brandon Keepers. I like to build things, usually in Ruby or JavaScript. I work at GitHub and live in Holland, MI.

Popular Posts