Sha256: 7c6a764fa38dd15839b1075e66d3db2cf12b0688fd2102979e20a48630823ff3
Contents?: true
Size: 547 Bytes
Versions: 2
Compression:
Stored size: 547 Bytes
Contents
# encoding: utf-8 module Rubocop module Cop module Lint # This cop checks for uses of *begin...end while/until something*. class Loop < Cop MSG = 'Use Kernel#loop with break rather than ' \ 'begin/end/until(or while).' def on_while_post(node) register_offense(node) end def on_until_post(node) register_offense(node) end private def register_offense(node) add_offense(node, :keyword) end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
rubocop-0.19.1 | lib/rubocop/cop/lint/loop.rb |
rubocop-0.19.0 | lib/rubocop/cop/lint/loop.rb |