summaryrefslogtreecommitdiff
path: root/thread_sync.rb
AgeCommit message (Collapse)Author
2022-10-17thread_sync.c: Clarify and document the behavior of timeout == 0Jean Boussier
[Feature #18982] Instead of introducing an `exception: false` argument to have `non_block` return nil rather than raise, we can clearly document that a timeout of 0 immediately returns. The code is refactored a bit to avoid doing a time calculation in such case. Notes: Merged: https://github.com/ruby/ruby/pull/6500
2022-08-18Implement SizedQueue#push(timeout: sec)Jean Boussier
[Feature #18944] If both `non_block=true` and `timeout:` are supplied, ArgumentError is raised. Notes: Merged: https://github.com/ruby/ruby/pull/6207
2022-08-02Implement Queue#pop(timeout: sec)Jean Boussier
[Feature #18774] As well as `SizedQueue#pop(timeout: sec)` If both `non_block=true` and `timeout:` are supplied, ArgumentError is raised. Notes: Merged: https://github.com/ruby/ruby/pull/6185