Sha256: 309b43ef7cb8cc0fb1ed887de28cda87cce703ad6dffda8937fd308774397883

Contents?: true

Size: 365 Bytes

Versions: 2

Compression:

Stored size: 365 Bytes

Contents

# encoding: utf-8

module Rubocop
  module Cop
    class BlockComments < Cop
      MSG = 'Do not use block comments.'

      def inspect(source, tokens, ast, comments)
        comments.each do |comment|
          if comment.text.start_with?('=begin')
            add_offence(:convention, comment.loc.line, MSG)
          end
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rubocop-0.8.3 lib/rubocop/cop/block_comments.rb
rubocop-0.8.2 lib/rubocop/cop/block_comments.rb