rbs
rbs copied to clipboard
Add support for `__END__` in rbs files
(This was originally a discussion, #1610. I think it's more apt as an issue, so it's been moved here).
One thing I really like about Ruby is the fact that you can type \n__END__\n and it'll comment out the rest of the file. I use it very extensively, from testing quick snippets, to commenting out code i'm replacing, to finding where the missing end originated from.
I'd really like if we could support \n__END__\n in RBS. It'd act just like Ruby's (except for no DATA) and would "comment out" the rest of the file.
Oh no, you want __END__ in RBS too? 😳
class Foo
end
__END__
class Foo # Comment
end
Technically, it's possible. __END__ is not a valid identifier in RBS.