debian-mirror-gitlab/rubocop/ext/variable_force.rb
2022-11-25 23:54:43 +05:30

17 lines
334 B
Ruby

# frozen_string_literal: true
module RuboCop
module Ext
module VariableForce
def scanned_node?(node)
scanned_nodes.include?(node)
end
def scanned_nodes
@scanned_nodes ||= Set.new.compare_by_identity
end
end
end
end
RuboCop::Cop::VariableForce.prepend RuboCop::Ext::VariableForce