Skip to content

End of Life Ruby 3.2 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →

instance method

SyntaxSuggest::CodeLine#trailing_slash?

trailing_slash?

Determines if the given line has a trailing slash

lines = CodeLine.from_source(<<~EOM)
  it "foo" \
EOM
expect(lines.first.trailing_slash?).to eq(true)
See also #to_s #visible? #set_kw_end also in 4.0 · 3.4 · 3.3