Improve frozen-string-literals compatibility. #436
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Some changes to get Aruba in a state that's happy to run when the
--enable-frozen-string-literal
flag is being used.Motivation and Context
I'm trying to get the RSpec test suite to a point where it can run with frozen string literals on MRI 2.4, and it makes use of Cucumber and Aruba, hence this patch (and another shortly for Cucumber as well).
How Has This Been Tested?
The test suite for Aruba doesn't seem to be passing in its current state? So, my testing of this patch was done via running the Cucumber and rspec-core suites instead (which make use of Aruba). Hence, these patches may not be all the places where frozen string literals are being misused, but they're certainly the only places that crop up via either of the other test suites.
Types of changes
Depends if you consider supporting frozen string literals a feature or a bug. ¯_(ツ)_/¯
Checklist:
As discussed above, the test suite in master wasn't green. Also, my changes don't require new tests (though at some point it'd be nice to have the test suite run in MRI 2.4 with the frozen string literal flag, to avoid regressions).