[ruby-core:99698] [Ruby master Feature#17125] Remove Thread.exclusive
From:
naruse@...
Date:
2020-08-26 07:30:18 UTC
List:
ruby-core #99698
Issue #17125 has been updated by naruse (Yui NARUSE).
We checked gems which use this API and they look obsoleted.e
We should check the impact with preview.
Go ahead
----------------------------------------
Feature #17125: Remove Thread.exclusive
https://bugs.ruby-lang.org/issues/17125#change-87189
* Author: znz (Kazuhiro NISHIYAMA)
* Status: Open
* Priority: Normal
----------------------------------------
`Thread.exclusive` is deprecated since 2.3.
```
% docker run -it --rm rubylang/all-ruby env ALL_RUBY_SINCE=ruby-1.8 ./all-ruby -r thread -e 'Thread.exclusive{}'
ruby-1.8.0
...
ruby-2.3.0-preview1
ruby-2.3.0-preview2 Thread.exclusive is deprecated, use Mutex
-e:1:in `<main>'
...
ruby-2.4.0-preview1 Thread.exclusive is deprecated, use Mutex
-e:1:in `<main>'
ruby-2.4.0-preview2 Thread.exclusive is deprecated, use Thread::Mutex
-e:1:in `<main>'
...
ruby-2.7.0-preview1 Thread.exclusive is deprecated, use Thread::Mutex
-e:1:in `<main>'
ruby-2.7.0-preview2 -e:1: warning: Thread.exclusive is deprecated, use Thread::Mutex
...
ruby-2.7.1 -e:1: warning: Thread.exclusive is deprecated, use Thread::Mutex
```
--
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>