Maintenance Ruby 3.4 gets fixes, but no new features. Switch to Ruby 4.0 →
instance method
Prism::InlineComment#trailing?
trailing?
lib/prism/parse_result.rb
View on GitHub ↗
# File tmp/rubies/ruby-3.4.1/lib/prism/parse_result.rb, line 532
def trailing?
!location.start_line_slice.strip.empty?
end
Returns true if this comment happens on the same line as other code and false if the comment is by itself.