Module: RuboCop::Cop::Sorbet::TLetCorrection

Included in:
RedundantTLet, RedundantTLetForLiteral
Defined in:
lib/rubocop/cop/sorbet/mixin/t_let_correction.rb

Overview

Shared autocorrection helper for cops that unwrap a redundant T.let(value, Type) down to value, preserving heredoc bodies that a naive corrector.replace(t_let_node, value_node.source) would drop (value_node.source stops at the marker line, so the body and its terminator sit outside it).