diff options
author | Shane Becker <veganstraightedge@gmail.com> | 2023-07-12 17:11:43 -0700 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2023-07-13 14:22:47 +0900 |
commit | 7524675330eaf96caba155852bb06b34b809b2a9 (patch) | |
tree | 40304baa62e3c0f7a19a63317edbf286ef15b91a /thread_sync.c | |
parent | 3ef6364a988ab24ca7fdbb7d1b6840b2a40f1466 (diff) | |
download | ruby-7524675330eaf96caba155852bb06b34b809b2a9.tar.gz |
[DOC] Fix example code indentation from 3 to 2
Diffstat (limited to 'thread_sync.c')
-rw-r--r-- | thread_sync.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/thread_sync.c b/thread_sync.c index cbcb7c2eaf..5b3fb95030 100644 --- a/thread_sync.c +++ b/thread_sync.c @@ -855,17 +855,17 @@ queue_closed_result(VALUE self, struct rb_queue *q) * * producer = Thread.new do * 5.times do |i| - * sleep rand(i) # simulate expense - * queue << i - * puts "#{i} produced" + * sleep rand(i) # simulate expense + * queue << i + * puts "#{i} produced" * end * end * * consumer = Thread.new do * 5.times do |i| - * value = queue.pop - * sleep rand(i/2) # simulate expense - * puts "consumed #{value}" + * value = queue.pop + * sleep rand(i/2) # simulate expense + * puts "consumed #{value}" * end * end * |