Project

General

Profile

Actions

Bug #11759

closed

URI breaks with frozen strings

Added by mperham (Mike Perham) almost 9 years ago. Updated almost 9 years ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
2.3.0-preview1
[ruby-core:71785]

Description

It appears URI uses String mutation and breaks frozen string mode.

$ RUBYOPT="--enable-frozen-string-literal" bundle exec rake
/Users/mike/.rubies/ruby-2.3.0-preview1/lib/ruby/2.3.0/uri/generic.rb:1344:in `to_s': can't modify frozen String (RuntimeError)
/Users/mike/.gem/ruby/2.3.0/gems/bundler-1.10.6/lib/bundler/source/rubygems.rb:257:in `normalize_uri'
/Users/mike/.gem/ruby/2.3.0/gems/bundler-1.10.6/lib/bundler/source/rubygems.rb:198:in `add_remote'
/Users/mike/.gem/ruby/2.3.0/gems/bundler-1.10.6/lib/bundler/source/rubygems.rb:25:in `block in initialize'
/Users/mike/.gem/ruby/2.3.0/gems/bundler-1.10.6/lib/bundler/source/rubygems.rb:25:in `reverse_each'
/Users/mike/.gem/ruby/2.3.0/gems/bundler-1.10.6/lib/bundler/source/rubygems.rb:25:in `initialize'

Files

0001-Do-not-mutate-strings-in-URI-to_s.patch (1.76 KB) 0001-Do-not-mutate-strings-in-URI-to_s.patch davidcelis (David Celis), 12/02/2015 01:30 AM
11759.patch (610 Bytes) 11759.patch colindkelley (Colin Kelley), 12/02/2015 07:08 AM
11759-rev2.patch (3.21 KB) 11759-rev2.patch colindkelley (Colin Kelley), 12/05/2015 04:15 PM
11759-rev3.patch (3.21 KB) 11759-rev3.patch colindkelley (Colin Kelley), 12/07/2015 03:57 PM
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0