textmate / ruby.tmbundle

TextMate support for Ruby
178 stars 91 forks source link

Ruby text remains comment.block.documentation.ruby after block quotes end. #139

Open alexr00 opened 2 years ago

alexr00 commented 2 years ago

Originally from @Zibokwe in https://github.com/microsoft/vscode/issues/136007.

Snippet:

=begin test =end

puts "enter a number:"

image It happens with any kind of block quote (in Ruby only), anything that begins with =begin will turn the rest of the code green even after the =end. The code after doesn't matter, it can be literally anything.

elia commented 2 years ago

=end must start at the beginning of the line in order to end the comment block, so the current behavior is correct

This is the correct way of using multiline comment blocks:

=begin
test
=end

puts "enter a number:"