22件ヒット
[1-22件を表示]
(0.047秒)
別のキーワード
キーワード
検索結果
-
Thread
:: ConditionVariable (24030.0) -
スレッドの同期機構の一つである状態変数を実現するクラスです。
...一つである状態変数を実現するクラスです。
以下も ConditionVariable を理解するのに参考になります。
https://ruby-doc.com/docs/ProgrammingRuby/html/tut_threads.html#UF
=== Condition Variable とは
あるスレッド A が排他領域で動いていたとしま......リソースの空きを
待っていても、いつまでも空くことはありません。
以上のような状況を解決するのが Condition Variable です。
スレッド a で条件(リソースが空いているかなど)が満たされるまで wait メソッドで
スレッドを......ッド a に対して条件が成立したことを通知します。これが典型的な
使用例です。
mutex = Mutex.new
cv = ConditionVariable.new
a = Thread.start {
mutex.synchronize {
...
while (条件が満たされない)
cv.wait(mute... -
NEWS for Ruby 3
. 0 . 0 (120.0) -
NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...ated from positional arguments.
Code that resulted in deprecation warnings in Ruby 2.7 will now
result in ArgumentError or different behavior. 14183
* Procs accepting a single rest argument and keywords are no longer
subject to autosplatting. This now matches the behavior of Procs......[(1..).step(2)] # take each second element
# => ["data1", "data2", "data3"]
//}
* Binding
* Binding#eval when called with one argument will use `"(eval)"` for `__FILE__` and `1` for `__LINE__` in the evaluated code. 4352 17419
* ConditionVariable
* ConditionVariable#wait may now invoke......cheduler hooks in a non-blocking context. 16786
* Dir
* Dir.glob and Dir.[] now sort the results by default, and accept the `sort:` keyword option. 8709
* ENV
* ENV.except has been added, which returns a hash excluding the given keys and their values. 15822
* Windows: Read ENV name... -
NEWS for Ruby 2
. 5 . 0 (60.0) -
NEWS for Ruby 2.5.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...非推奨になりました。C拡張のベースクラスでしたが、Rubyレベルに公開するのをやめました。3072
* Exception
* Exception#full_message を追加 14141 [実験的]
例外の文字列表現を取得します。その文字列は捕捉されない例外をRu......r.open, Dir.new, Dir.mkdir, Dir.rmdir,
Dir.empty? はGVLを解放するようになりました
* Dir.children を追加 11302
* Dir.each_child を追加 11302
* Enumerable
* Enumerable#any?, Enumerable#all?, Enumerable#none?, Enumerable#one?
がブロックを省略し......13803
* ConditionVariable, Queue, SizedQueue を速度向上のため再実装しました。
これらのクラスはStructのサブクラスではなくなりました。13552
=== 標準添付ライブラリの互換性(機能追加とバグ修正を除く)
* Gemification
* 以下...