Skip to content

Fix frozen string literal mutation#1626

Closed
viralpraxis wants to merge 1 commit intolsegal:mainfrom
viralpraxis:fix-frozen-string-literal-mutation
Closed

Fix frozen string literal mutation#1626
viralpraxis wants to merge 1 commit intolsegal:mainfrom
viralpraxis:fix-frozen-string-literal-mutation

Conversation

@viralpraxis
Copy link

There's a warning

ruby_lex.rb:987: warning: literal string will be frozen in the future (run with --debug-frozen-string-literal for more information

which will lead to an error when frozen strings literals (MRI 3.5?) will be frozen by default.

Description

Describe your pull request and problem statement here.

Completed Tasks

  • I have read the Contributing Guide.
  • The pull request is complete (implemented / written).
  • Git commits have been cleaned up (squash WIP / revert commits).
  • I wrote tests and ran bundle exec rake locally (if code is attached to PR).

There's a warning

```shell
ruby_lex.rb:987: warning: literal string will be frozen in the future (run with --debug-frozen-string-literal for more information
```

which will lead to an error when frozen strings literals (MRI 3.5?) will be frozen by default.
@viralpraxis viralpraxis force-pushed the fix-frozen-string-literal-mutation branch from 5915717 to 984f82f Compare September 10, 2025 20:30
@lsegal
Copy link
Owner

lsegal commented Dec 5, 2025

Getting to this pretty late but seems like this would break encoding support in YARD.

lsegal added a commit that referenced this pull request Dec 5, 2025
@lsegal
Copy link
Owner

lsegal commented Dec 5, 2025

Fixed by c92f02a

@lsegal lsegal closed this Dec 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants