[#80531] Re: [ruby-cvs:65407] normal:r58236 (trunk): thread.c: comments on M:N threading [ci skip] — Eric Wong <normalperson@...>
SASADA Koichi <ko1@ruby-lang.org> wrote:
On 2017/04/02 11:35, Eric Wong wrote:
SASADA Koichi <ko1@atdot.net> wrote:
Eric Wong <normalperson@yhbt.net> wrote:
On 2017/05/08 9:33, Eric Wong wrote:
On 2017/05/08 10:53, SASADA Koichi wrote:
SASADA Koichi <ko1@atdot.net> wrote:
On 2017/05/08 12:01, Eric Wong wrote:
SASADA Koichi <ko1@atdot.net> wrote:
On 2017/05/08 15:36, Eric Wong wrote:
SASADA Koichi <ko1@atdot.net> wrote:
On 2017/05/09 12:38, Eric Wong wrote:
SASADA Koichi <ko1@atdot.net> wrote:
On 2017/05/09 14:12, Eric Wong wrote:
SASADA Koichi <ko1@atdot.net> wrote:
On 2017/05/09 15:23, Eric Wong wrote:
SASADA Koichi <ko1@atdot.net> wrote:
Thank you.
[#80763] [Ruby trunk Feature#13434] better method definition in C API — naruse@...
Issue #13434 has been updated by naruse (Yui NARUSE).
[#80844] [Ruby trunk Bug#13503] Improve performance of some Time & Rational methods — watson1978@...
Issue #13503 has been updated by watson1978 (Shizuo Fujita).
[#80892] [Ruby trunk Misc#13514] [PATCH] thread_pthread.c (native_sleep): preserve old unblock function — ko1@...
Issue #13514 has been updated by ko1 (Koichi Sasada).
ko1@atdot.net wrote:
On 2017/04/27 8:58, Eric Wong wrote:
SASADA Koichi <ko1@atdot.net> wrote:
Eric Wong <normalperson@yhbt.net> wrote:
[ruby-core:80764] [Ruby trunk Bug#13444] compatibility breaking change: backticks is not evalueted as shell script call while in "unless" operator context
Issue #13444 has been updated by dikderoy (Roman Bulgakov).
Or putting a warning, because optimization actually changes behavior.
----------------------------------------
Bug #13444: compatibility breaking change: backticks is not evalueted as shell script call while in "unless" operator context
https://bugs.ruby-lang.org/issues/13444#change-64352
* Author: dikderoy (Roman Bulgakov)
* Status: Open
* Priority: Normal
* Assignee:
* Target version:
* ruby -v: ruby 2.4.1p111 (2017-03-22 revision 58053) [x86_64-linux]
* Backport: 2.2: UNKNOWN, 2.3: UNKNOWN, 2.4: UNKNOWN
----------------------------------------
Ruby versions from 2.0 to 2.3.x while executing shell script via backticks inside of "unless" construction had it executed and evalueted output as condition,
version 2.4 and onwards had condition evaluated as true but script is not executed.
I haven't find any note regarding such change in release-notes for 2.4.0 and 2.4.1
**Steps to reproduce:**
giving following code:
~~~ ruby
unless `touch abc.txt`
raise 'Error'
end
~~~
**Expected:**
cwd has a file abc.txt created
**Actual:**
cwd has no file abc.txt and no exception has been raised
----
**Test-case (with version comparison via rvm)**
file [test.rb]:
~~~ ruby
unless `touch test-#{RUBY_VERSION}`
raise 'Error'
end
begin
puts $?.success?
rescue StandardError => e
puts "rescued:#{e.message}"
end
s = `ls -l test-#{RUBY_VERSION}`
puts s.lines.length == 1 ? 'OK' : 'NOK'
~~~
exec:
**$ rvm list**
~~~ text
rvm rubies
ruby-2.0.0-p648 [ x86_64 ]
ruby-2.1.10 [ x86_64 ]
ruby-2.2.6 [ x86_64 ]
ruby-2.3.3 [ x86_64 ]
* ruby-2.4.0 [ x86_64 ]
=> ruby-2.4.1 [ x86_64 ]
~~~
**$ rvm all --verbose do ruby test.rb**
~~~ text
ruby-2.1.10: ruby 2.1.10p492 (2016-04-01 revision 54464) [x86_64-linux]
true
OK
ruby-2.2.6: ruby 2.2.6p396 (2016-11-15 revision 56800) [x86_64-linux]
true
OK
ruby-2.0.0-p648: ruby 2.0.0p648 (2015-12-16 revision 53162) [x86_64-linux]
true
OK
ruby-2.3.3: ruby 2.3.3p222 (2016-11-21 revision 56859) [x86_64-linux]
true
OK
ruby-2.4.0: ruby 2.4.0p0 (2016-12-24 revision 57164) [x86_64-linux]
rescued:undefined method `success?' for nil:NilClass
NOK
ruby-2.4.1: ruby 2.4.1p111 (2017-03-22 revision 58053) [x86_64-linux]
rescued:undefined method `success?' for nil:NilClass
NOK
~~~
**$ ls -l test-***
~~~ text
-rw-rw-r-- 1 user user 0 апр. 17 23:50 test-2.0.0
-rw-rw-r-- 1 user user 0 апр. 17 23:50 test-2.1.10
-rw-rw-r-- 1 user user 0 апр. 17 23:50 test-2.2.6
-rw-rw-r-- 1 user user 0 апр. 17 23:50 test-2.3.3
~~~
**OS:** Ubuntu 14.04
**cat /etc/debian_version:** jessie/sid
**uname -isoprvm:** Linux 3.13.0-116-generic #163-Ubuntu SMP Fri Mar 31 14:13:22 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
---Files--------------------------------
test.rb (218 Bytes)
--
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>