Style/FrozenStringLiteralComment
- invalid byte sequence in UTF-8
#12034
Labels
Style/FrozenStringLiteralComment
- invalid byte sequence in UTF-8
#12034
Hello 👋 I have a tricky issue, with
Style/FrozenStringLiteralComment
. Regex give me nightmare, so can't help more than providing as much as possible information. Do not hesitate if you need something else!Given a file
foo.rb
:Which is a valid syntax:
Expected behavior
Should not trigger an error. And probably propose a fix to add the comment.
Actual behavior
bin/rubocop -d --only Style/FrozenStringLiteralComment foo.rb
Steps to reproduce the problem
In
Style::FrozenStringLiteralComment
the methodlast_special_comment
receive an argumentprocessed_source
,Its raised an error on Regex match check:
rubocop/lib/rubocop/cop/style/frozen_string_literal_comment.rb
Lines 137 to 148 in 1a13d7a
RuboCop version
The text was updated successfully, but these errors were encountered: