Skip to content

Latest commit

 

History

History
23 lines (14 loc) · 272 Bytes

enable-ruby-warnings.md

File metadata and controls

23 lines (14 loc) · 272 Bytes

Enable ruby warnings

$VERBOSE = true

class WarnMe
  def var
    @var || 42
  end
end


p WarnMe.new.var


# Result:
# ./enable_ruby_warnings.rb:5: warning: instance variable @var not initialized
# 42

View Source