class RuboCop::Cop::Sorbet::RedundantExtendTSig
end
def no_op; end
sig { void }
class Example
# good
end
def no_op; end
sig { void }
extend T::Sig
class Example
# bad
@example
patched ‘Module`.
This cop should not be enabled in applications that have not monkey
@safety
which would make it redundant.
applications that monkey patch `Module.include(T::Sig)` globally,
Forbids the use of redundant `extend T::Sig`. Only for use in
def on_send(node)
def on_send(node) return unless extend_t_sig?(node) add_offense(node) do |corrector| corrector.remove(range_by_whole_lines(node.source_range, include_final_newline: true)) end end