[#84280] [Ruby trunk Bug#14181] hangs or deadlocks from waitpid, threads, and trapping SIGCHLD — nobu@...
Issue #14181 has been updated by nobu (Nobuyoshi Nakada).
3 messages
2017/12/15
[#84398] [Ruby trunk Bug#14220] WEBrick changes - failures on MSWIN, MinGW — Greg.mpls@...
Issue #14220 has been reported by MSP-Greg (Greg L).
3 messages
2017/12/22
[#84472] Re: [ruby-dev:50394] [Ruby trunk Bug#14240] warn four special variables: $; $, $/ $\ — Eric Wong <normalperson@...>
Shouldn't English posts be on ruby-core instead of ruby-dev?
3 messages
2017/12/26
[ruby-core:84532] [Ruby trunk Bug#14251] String insert changing value of other string
From:
matthew@...
Date:
2017-12-27 23:19:33 UTC
List:
ruby-core #84532
Issue #14251 has been updated by phluid61 (Matthew Kerwin). All Ruby variables are by-reference. To create a new object, use #dup ~~~ruby foo = 'abc' bar = foo.dup bar.insert(1, d) ~~~ ---------------------------------------- Bug #14251: String insert changing value of other string https://bugs.ruby-lang.org/issues/14251#change-69060 * Author: ricardovsilva (Ricardo Silva) * Status: Open * Priority: Normal * Assignee: * Target version: * ruby -v: 2.4.1p111 (2017-03-22 revision 58053) [x86_64-linux] * Backport: 2.3: UNKNOWN, 2.4: UNKNOWN, 2.5: UNKNOWN ---------------------------------------- ~~~ ruby foo = 'abc' bar = foo bar.insert(1, d) puts foo 'adbc' puts bar 'adbc' ~~~ The example above should only affect bar variable. It leads to an error by programmer. A bypass that I found is to do: ~~~ ruby foo = 'aaa' bar = String.new foo bar.insert(1, 'd') puts foo #aaa puts bar #adaa ~~~ -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>