summaryrefslogtreecommitdiff
path: root/thread_sync.c
diff options
context:
space:
mode:
authorShane Becker <veganstraightedge@gmail.com>2023-07-12 17:11:43 -0700
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2023-07-13 14:22:47 +0900
commit7524675330eaf96caba155852bb06b34b809b2a9 (patch)
tree40304baa62e3c0f7a19a63317edbf286ef15b91a /thread_sync.c
parent3ef6364a988ab24ca7fdbb7d1b6840b2a40f1466 (diff)
[DOC] Fix example code indentation from 3 to 2
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/8063
Diffstat (limited to 'thread_sync.c')
-rw-r--r--thread_sync.c12
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
*