Skip to content

Conversation

@credbbl
Copy link

@credbbl credbbl commented Feb 6, 2026

Future versions of Ruby will default to frozen strings and Ruby 3.4 starts to warn about it. However all the tests rely on modifiable, aka not frozen, strings.

Future versions of Ruby will default to frozen strings and Ruby 3.4
starts to warn about it.  However all the tests rely on modifiable, aka
not frozen, strings.
Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd prefer to deal with frozen strings instead because it could hide items.

For my own references: https://rubyapi.org/4.0/o/string#class-String-label-Modifying lists all methods modifying strings and that lists gsub!.

I'd suggest to replacegsub! with something like:

call = call.gsub('"', '\\\\"')

Having said that, I see in the code gsub! is also used in the code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants