Pastie now auto-senses if line-wrap is a bad or good idea. Feedback?
## mark a section (Learn more)
This paste will be private.
class StaticScope def to_s puts "parent: #{@parent}, module: #{@module}" end end class Fruit def initialize(name) @name = name puts MethodContext.current.method.staticscope.to_s end end pineapple = Fruit.new("pineapple")
From the Design Piracy series on my blog: