module RuboCop::AST::HashElementNode

def same_line?(other)

Returns:
  • (Boolean) - whether this element is on the same line as `other`

Other tags:
    Note: - A multiline element is considered to be on the same line if it
def same_line?(other)
  loc.last_line == other.loc.line || loc.line == other.loc.last_line
end