ruff 1.1.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d7f3ee79cb42e509a2fc3410d95c7d197b39883758ea0fb81d46bea40e136a01
4
- data.tar.gz: df62872b62ab83ca644d0d61bc1187d52d2f96fb2f9f85c9c38bee56f232eb58
3
+ metadata.gz: dfebb70cd49dd7912799a61968e781995e766b2ebf9c31d9bcd0e37e906428bc
4
+ data.tar.gz: 688639673c9ca99111482a18aa8f4a18f4e1b450ad628eee645df6f0bfd57c0e
5
5
  SHA512:
6
- metadata.gz: e62ad575dd7fead1098b6cae54d66b5525128e593c50e4b54808f23e9d4206514e75747a65a50e500f457ada6991c4a4b075381009d1aa049d2deb2869ab8a91
7
- data.tar.gz: 5d52c47183e2dcfcae02614d4ee9dcbee3ce596f8cd282c993221f8167959c4e76d69fd37f8aa6046594b4afc8245b26334faa685a8da16dccbbb5cb15171d25
6
+ metadata.gz: 76b93cc1a843dc47a00692e3ca4b011113e47d804bbe4e71c7933e8ca02a583f10b6632f10bac013035531294cdeaf6cee3a4c3e5768175e6e14a3c0cfe2ad93
7
+ data.tar.gz: 43f9b5c94fd98da4c9d1f248392cd775eab21110640fa963183a3a95802b7e90a95acb2a685c697244ebec8c0f5d70d5506ba66a3b83b6685dd5877d6b6b04a4
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ruff (1.0.1)
4
+ ruff (1.1.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
data/Rakefile CHANGED
@@ -1,9 +1,12 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require 'bundler/gem_tasks'
4
+ require 'rubocop/rake_task'
4
5
  require 'yard'
5
6
  # require 'ruff/version'
6
7
 
8
+ RuboCop::RakeTask.new
9
+
7
10
  YARD::Rake::YardocTask.new do |doc|
8
11
  doc.name = 'doc'
9
12
 
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Ruff
8
8
 
9
- &mdash; Ruff 1.0.1 Documentation
9
+ &mdash; Ruff 1.1.0 Documentation
10
10
 
11
11
  </title>
12
12
 
@@ -109,7 +109,7 @@
109
109
  <dt id="VERSION-constant" class="">VERSION =
110
110
 
111
111
  </dt>
112
- <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>1.0.1</span><span class='tstring_end'>&#39;</span></span></pre></dd>
112
+ <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>1.1.0</span><span class='tstring_end'>&#39;</span></span></pre></dd>
113
113
 
114
114
  </dl>
115
115
 
@@ -263,7 +263,7 @@
263
263
  <p class="tag_title">Examples:</p>
264
264
 
265
265
 
266
- <pre class="example code"><code><span class='const'>Log</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="" title="Ruff (module)">Ruff</a></span></span><span class='period'>.</span><span class='id identifier rubyid_instance'>instance</span> <span class='comment'># === Ruff::Effect.new</span></code></pre>
266
+ <pre class="example code"><code><span class='const'>Log</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="" title="Ruff (module)">Ruff</a></span></span><span class='period'>.</span><span class='id identifier rubyid_instance'>instance</span> <span class='comment'>#==&gt; Ruff::Effect.new</span></code></pre>
267
267
 
268
268
  </div>
269
269
 
@@ -301,9 +301,9 @@
301
301
  </div>
302
302
 
303
303
  <div id="footer">
304
- Generated on Fri Oct 4 13:57:07 2019 by
304
+ Generated on Fri Oct 4 21:12:21 2019 by
305
305
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
306
- 0.9.20 (ruby-2.6.4).
306
+ 0.9.20 (ruby-2.6.5).
307
307
  </div>
308
308
 
309
309
  </div>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: Ruff::Effect
8
8
 
9
- &mdash; Ruff 1.0.1 Documentation
9
+ &mdash; Ruff 1.1.0 Documentation
10
10
 
11
11
  </title>
12
12
 
@@ -404,9 +404,9 @@
404
404
  </div>
405
405
 
406
406
  <div id="footer">
407
- Generated on Fri Oct 4 13:57:07 2019 by
407
+ Generated on Fri Oct 4 21:12:21 2019 by
408
408
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
409
- 0.9.20 (ruby-2.6.4).
409
+ 0.9.20 (ruby-2.6.5).
410
410
  </div>
411
411
 
412
412
  </div>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: Ruff::Handler
8
8
 
9
- &mdash; Ruff 1.0.1 Documentation
9
+ &mdash; Ruff 1.1.0 Documentation
10
10
 
11
11
  </title>
12
12
 
@@ -146,7 +146,8 @@
146
146
 
147
147
 
148
148
 
149
- <span class="summary_desc"><div class='inline'></div></span>
149
+ <span class="summary_desc"><div class='inline'><p>is also private method.</p>
150
+ </div></span>
150
151
 
151
152
  </li>
152
153
 
@@ -326,18 +327,28 @@ Value handler is set <code>id</code> function to by default.</p>
326
327
 
327
328
 
328
329
 
329
- </h3><table class="source_code">
330
+ </h3><div class="docstring">
331
+ <div class="discussion">
332
+ <p>is also private method.</p>
333
+
334
+
335
+ </div>
336
+ </div>
337
+ <div class="tags">
338
+
339
+
340
+ </div><table class="source_code">
330
341
  <tr>
331
342
  <td>
332
343
  <pre class="lines">
333
344
 
334
345
 
335
- 112
336
346
  113
337
- 114</pre>
347
+ 114
348
+ 115</pre>
338
349
  </td>
339
350
  <td>
340
- <pre class="code"><span class="info file"># File 'lib/ruff/handler.rb', line 112</span>
351
+ <pre class="code"><span class="info file"># File 'lib/ruff/handler.rb', line 113</span>
341
352
 
342
353
  <span class='kw'>def</span> <span class='id identifier rubyid_handlers='>handlers=</span><span class='lparen'>(</span><span class='id identifier rubyid_handlers'>handlers</span><span class='rparen'>)</span>
343
354
  <span class='ivar'>@handlers</span> <span class='op'>=</span> <span class='id identifier rubyid_handlers'>handlers</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span>
@@ -675,9 +686,9 @@ in effect handlers of the handler.</p>
675
686
  </div>
676
687
 
677
688
  <div id="footer">
678
- Generated on Fri Oct 4 13:57:07 2019 by
689
+ Generated on Fri Oct 4 21:12:21 2019 by
679
690
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
680
- 0.9.20 (ruby-2.6.4).
691
+ 0.9.20 (ruby-2.6.5).
681
692
  </div>
682
693
 
683
694
  </div>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Ruff::Standard
8
8
 
9
- &mdash; Ruff 1.0.1 Documentation
9
+ &mdash; Ruff 1.1.0 Documentation
10
10
 
11
11
  </title>
12
12
 
@@ -117,7 +117,7 @@ Each module provides <code>Instance</code> class to instantiate and handle the i
117
117
  <p class="children">
118
118
 
119
119
 
120
- <strong class="modules">Modules:</strong> <span class='object_link'><a href="Standard/CurrentTime.html" title="Ruff::Standard::CurrentTime (module)">CurrentTime</a></span>, <span class='object_link'><a href="Standard/Defer.html" title="Ruff::Standard::Defer (module)">Defer</a></span>, <span class='object_link'><a href="Standard/State.html" title="Ruff::Standard::State (module)">State</a></span>
120
+ <strong class="modules">Modules:</strong> <span class='object_link'><a href="Standard/CurrentTime.html" title="Ruff::Standard::CurrentTime (module)">CurrentTime</a></span>, <span class='object_link'><a href="Standard/Defer.html" title="Ruff::Standard::Defer (module)">Defer</a></span>, <span class='object_link'><a href="Standard/MeasureTime.html" title="Ruff::Standard::MeasureTime (module)">MeasureTime</a></span>, <span class='object_link'><a href="Standard/State.html" title="Ruff::Standard::State (module)">State</a></span>
121
121
 
122
122
 
123
123
 
@@ -135,9 +135,9 @@ Each module provides <code>Instance</code> class to instantiate and handle the i
135
135
  </div>
136
136
 
137
137
  <div id="footer">
138
- Generated on Fri Oct 4 13:57:07 2019 by
138
+ Generated on Fri Oct 4 21:12:21 2019 by
139
139
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
140
- 0.9.20 (ruby-2.6.4).
140
+ 0.9.20 (ruby-2.6.5).
141
141
  </div>
142
142
 
143
143
  </div>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Ruff::Standard::CurrentTime
8
8
 
9
- &mdash; Ruff 1.0.1 Documentation
9
+ &mdash; Ruff 1.1.0 Documentation
10
10
 
11
11
  </title>
12
12
 
@@ -243,12 +243,12 @@
243
243
  <pre class="lines">
244
244
 
245
245
 
246
- 56
247
246
  57
248
- 58</pre>
247
+ 58
248
+ 59</pre>
249
249
  </td>
250
250
  <td>
251
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 56</span>
251
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 57</span>
252
252
 
253
253
  <span class='kw'>def</span> <span class='id identifier rubyid_eff'>eff</span>
254
254
  <span class='ivar'>@eff</span>
@@ -296,12 +296,12 @@
296
296
  <pre class="lines">
297
297
 
298
298
 
299
- 44
300
299
  45
301
- 46</pre>
300
+ 46
301
+ 47</pre>
302
302
  </td>
303
303
  <td>
304
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 44</span>
304
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 45</span>
305
305
 
306
306
  <span class='kw'>def</span> <span class='id identifier rubyid_get'>get</span>
307
307
  <span class='ivar'>@inst</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span>
@@ -342,12 +342,12 @@
342
342
  <pre class="lines">
343
343
 
344
344
 
345
- 49
346
345
  50
347
- 51</pre>
346
+ 51
347
+ 52</pre>
348
348
  </td>
349
349
  <td>
350
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 49</span>
350
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 50</span>
351
351
 
352
352
  <span class='kw'>def</span> <span class='id identifier rubyid_with'>with</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_th'>th</span><span class='rparen'>)</span>
353
353
  <span class='ivar'>@inst</span><span class='period'>.</span><span class='id identifier rubyid_with'>with</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_th'>th</span><span class='rparen'>)</span>
@@ -362,9 +362,9 @@
362
362
  </div>
363
363
 
364
364
  <div id="footer">
365
- Generated on Fri Oct 4 13:57:07 2019 by
365
+ Generated on Fri Oct 4 21:12:21 2019 by
366
366
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
367
- 0.9.20 (ruby-2.6.4).
367
+ 0.9.20 (ruby-2.6.5).
368
368
  </div>
369
369
 
370
370
  </div>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: Ruff::Standard::CurrentTime::Instance
8
8
 
9
- &mdash; Ruff 1.0.1 Documentation
9
+ &mdash; Ruff 1.1.0 Documentation
10
10
 
11
11
  </title>
12
12
 
@@ -251,13 +251,15 @@
251
251
 
252
252
  10
253
253
  11
254
- 12</pre>
254
+ 12
255
+ 13</pre>
255
256
  </td>
256
257
  <td>
257
258
  <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 10</span>
258
259
 
259
260
  <span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span>
260
261
  <span class='ivar'>@eff</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../../../Ruff.html" title="Ruff (module)">Ruff</a></span></span><span class='period'>.</span><span class='id identifier rubyid_instance'><span class='object_link'><a href="../../../Ruff.html#instance-class_method" title="Ruff.instance (method)">instance</a></span></span>
262
+ <span class='ivar'>@handler</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../../../Ruff.html" title="Ruff (module)">Ruff</a></span></span><span class='period'>.</span><span class='id identifier rubyid_handler'><span class='object_link'><a href="../../../Ruff.html#handler-class_method" title="Ruff.handler (method)">handler</a></span></span><span class='period'>.</span><span class='id identifier rubyid_on'>on</span><span class='lparen'>(</span><span class='ivar'>@eff</span><span class='rparen'>)</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_k'>k</span><span class='op'>|</span> <span class='id identifier rubyid_k'>k</span><span class='lbracket'>[</span><span class='const'>Time</span><span class='period'>.</span><span class='id identifier rubyid_now'>now</span><span class='rbracket'>]</span> <span class='rbrace'>}</span>
261
263
  <span class='kw'>end</span></pre>
262
264
  </td>
263
265
  </tr>
@@ -296,12 +298,12 @@
296
298
  <pre class="lines">
297
299
 
298
300
 
299
- 36
300
301
  37
301
- 38</pre>
302
+ 38
303
+ 39</pre>
302
304
  </td>
303
305
  <td>
304
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 36</span>
306
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 37</span>
305
307
 
306
308
  <span class='kw'>def</span> <span class='id identifier rubyid_eff'>eff</span>
307
309
  <span class='ivar'>@eff</span>
@@ -360,12 +362,12 @@
360
362
  <pre class="lines">
361
363
 
362
364
 
363
- 17
364
365
  18
365
- 19</pre>
366
+ 19
367
+ 20</pre>
366
368
  </td>
367
369
  <td>
368
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 17</span>
370
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 18</span>
369
371
 
370
372
  <span class='kw'>def</span> <span class='id identifier rubyid_get'>get</span>
371
373
  <span class='ivar'>@eff</span><span class='period'>.</span><span class='id identifier rubyid_perform'>perform</span>
@@ -401,7 +403,7 @@ This handler receives the <em>request</em> and returns current time.</p>
401
403
  <span class='name'>th</span>
402
404
 
403
405
 
404
- <span class='type'>(<tt>Proc&lt;(), A&gt;!{<span class='object_link'><a href="../CurrentTime.html" title="Ruff::Standard::CurrentTime (module)">CurrentTime</a></span>.<span class='object_link'><a href="#eff-instance_method" title="Ruff::Standard::CurrentTime::Instance#eff (method)">eff</a></span>, e}</tt>)</span>
406
+ <span class='type'>(<tt>Proc&lt;(), A!{<span class='object_link'><a href="../CurrentTime.html" title="Ruff::Standard::CurrentTime (module)">CurrentTime</a></span>.<span class='object_link'><a href="#eff-instance_method" title="Ruff::Standard::CurrentTime::Instance#eff (method)">eff</a></span>, e}&gt;</tt>)</span>
405
407
 
406
408
 
407
409
 
@@ -439,15 +441,15 @@ But it still has the possibility to invoke effects(<code>e</code>).</p>
439
441
  <pre class="lines">
440
442
 
441
443
 
442
- 31
443
444
  32
444
- 33</pre>
445
+ 33
446
+ 34</pre>
445
447
  </td>
446
448
  <td>
447
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 31</span>
449
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/current_time.rb', line 32</span>
448
450
 
449
451
  <span class='kw'>def</span> <span class='id identifier rubyid_with'>with</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_th'>th</span><span class='rparen'>)</span>
450
- <span class='const'><span class='object_link'><a href="../../../Ruff.html" title="Ruff (module)">Ruff</a></span></span><span class='period'>.</span><span class='id identifier rubyid_handler'><span class='object_link'><a href="../../../Ruff.html#handler-class_method" title="Ruff.handler (method)">handler</a></span></span><span class='period'>.</span><span class='id identifier rubyid_on'>on</span><span class='lparen'>(</span><span class='ivar'>@eff</span><span class='rparen'>)</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_k'>k</span><span class='op'>|</span> <span class='id identifier rubyid_k'>k</span><span class='lbracket'>[</span><span class='const'>Time</span><span class='period'>.</span><span class='id identifier rubyid_now'>now</span><span class='rbracket'>]</span> <span class='rbrace'>}</span><span class='period'>.</span><span class='id identifier rubyid_run'>run</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_th'>th</span><span class='rparen'>)</span>
452
+ <span class='ivar'>@handler</span><span class='period'>.</span><span class='id identifier rubyid_run'>run</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_th'>th</span><span class='rparen'>)</span>
451
453
  <span class='kw'>end</span></pre>
452
454
  </td>
453
455
  </tr>
@@ -459,9 +461,9 @@ But it still has the possibility to invoke effects(<code>e</code>).</p>
459
461
  </div>
460
462
 
461
463
  <div id="footer">
462
- Generated on Fri Oct 4 13:57:07 2019 by
464
+ Generated on Fri Oct 4 21:12:21 2019 by
463
465
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
464
- 0.9.20 (ruby-2.6.4).
466
+ 0.9.20 (ruby-2.6.5).
465
467
  </div>
466
468
 
467
469
  </div>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Ruff::Standard::Defer
8
8
 
9
- &mdash; Ruff 1.0.1 Documentation
9
+ &mdash; Ruff 1.1.0 Documentation
10
10
 
11
11
  </title>
12
12
 
@@ -244,12 +244,12 @@ and the implementation to defer procedures .</p>
244
244
  <pre class="lines">
245
245
 
246
246
 
247
- 69
248
- 70
249
- 71</pre>
247
+ 72
248
+ 73
249
+ 74</pre>
250
250
  </td>
251
251
  <td>
252
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/defer.rb', line 69</span>
252
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/defer.rb', line 72</span>
253
253
 
254
254
  <span class='kw'>def</span> <span class='id identifier rubyid_eff'>eff</span>
255
255
  <span class='ivar'>@eff</span>
@@ -297,12 +297,12 @@ and the implementation to defer procedures .</p>
297
297
  <pre class="lines">
298
298
 
299
299
 
300
- 57
301
- 58
302
- 59</pre>
300
+ 60
301
+ 61
302
+ 62</pre>
303
303
  </td>
304
304
  <td>
305
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/defer.rb', line 57</span>
305
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/defer.rb', line 60</span>
306
306
 
307
307
  <span class='kw'>def</span> <span class='id identifier rubyid_register'>register</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_prc'>prc</span><span class='rparen'>)</span>
308
308
  <span class='ivar'>@inst</span><span class='period'>.</span><span class='id identifier rubyid_register'>register</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_prc'>prc</span><span class='rparen'>)</span>
@@ -343,12 +343,12 @@ and the implementation to defer procedures .</p>
343
343
  <pre class="lines">
344
344
 
345
345
 
346
- 62
347
- 63
348
- 64</pre>
346
+ 65
347
+ 66
348
+ 67</pre>
349
349
  </td>
350
350
  <td>
351
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/defer.rb', line 62</span>
351
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/defer.rb', line 65</span>
352
352
 
353
353
  <span class='kw'>def</span> <span class='id identifier rubyid_with'>with</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_th'>th</span><span class='rparen'>)</span>
354
354
  <span class='ivar'>@inst</span><span class='period'>.</span><span class='id identifier rubyid_with'>with</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_th'>th</span><span class='rparen'>)</span>
@@ -363,9 +363,9 @@ and the implementation to defer procedures .</p>
363
363
  </div>
364
364
 
365
365
  <div id="footer">
366
- Generated on Fri Oct 4 13:57:07 2019 by
366
+ Generated on Fri Oct 4 21:12:21 2019 by
367
367
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
368
- 0.9.20 (ruby-2.6.4).
368
+ 0.9.20 (ruby-2.6.5).
369
369
  </div>
370
370
 
371
371
  </div>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: Ruff::Standard::Defer::Instance
8
8
 
9
- &mdash; Ruff 1.0.1 Documentation
9
+ &mdash; Ruff 1.1.0 Documentation
10
10
 
11
11
  </title>
12
12
 
@@ -296,12 +296,12 @@
296
296
  <pre class="lines">
297
297
 
298
298
 
299
- 49
300
- 50
301
- 51</pre>
299
+ 52
300
+ 53
301
+ 54</pre>
302
302
  </td>
303
303
  <td>
304
- <pre class="code"><span class="info file"># File 'lib/ruff/standard/defer.rb', line 49</span>
304
+ <pre class="code"><span class="info file"># File 'lib/ruff/standard/defer.rb', line 52</span>
305
305
 
306
306
  <span class='kw'>def</span> <span class='id identifier rubyid_eff'>eff</span>
307
307
  <span class='ivar'>@eff</span>
@@ -467,7 +467,10 @@ But it still has the possibility to invoke effects(<code>e</code>).</p>
467
467
  43
468
468
  44
469
469
  45
470
- 46</pre>
470
+ 46
471
+ 47
472
+ 48
473
+ 49</pre>
471
474
  </td>
472
475
  <td>
473
476
  <pre class="code"><span class="info file"># File 'lib/ruff/standard/defer.rb', line 32</span>
@@ -476,14 +479,17 @@ But it still has the possibility to invoke effects(<code>e</code>).</p>
476
479
  <span class='comment'># This is a stack to store deferred procedures.
477
480
  </span> <span class='id identifier rubyid_procs'>procs</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
478
481
 
479
- <span class='const'><span class='object_link'><a href="../../../Ruff.html" title="Ruff (module)">Ruff</a></span></span><span class='period'>.</span><span class='id identifier rubyid_handler'><span class='object_link'><a href="../../../Ruff.html#handler-class_method" title="Ruff.handler (method)">handler</a></span></span>
482
+ <span class='comment'># The handler *closes* `procs` variable so it should be created every time.
483
+ </span> <span class='const'><span class='object_link'><a href="../../../Ruff.html" title="Ruff (module)">Ruff</a></span></span><span class='period'>.</span><span class='id identifier rubyid_handler'><span class='object_link'><a href="../../../Ruff.html#handler-class_method" title="Ruff.handler (method)">handler</a></span></span>
480
484
  <span class='period'>.</span><span class='id identifier rubyid_on'>on</span><span class='lparen'>(</span><span class='ivar'>@eff</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_k'>k</span><span class='comma'>,</span> <span class='id identifier rubyid_prc'>prc</span><span class='op'>|</span>
481
485
  <span class='id identifier rubyid_procs'>procs</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_prc'>prc</span>
482
486
  <span class='id identifier rubyid_k'>k</span><span class='lbracket'>[</span><span class='rbracket'>]</span>
483
487
  <span class='kw'>end</span>
484
- <span class='period'>.</span><span class='id identifier rubyid_to'>to</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid__'>_</span><span class='op'>|</span>
488
+ <span class='period'>.</span><span class='id identifier rubyid_to'>to</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_v'>v</span><span class='op'>|</span>
485
489
  <span class='comment'># Like Go&#39;s defer functions, it crashes the thunk by reversed order.
486
490
  </span> <span class='id identifier rubyid_procs'>procs</span><span class='period'>.</span><span class='id identifier rubyid_reverse_each'>reverse_each</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='symbol'>:[]</span><span class='rparen'>)</span>
491
+
492
+ <span class='id identifier rubyid_v'>v</span>
487
493
  <span class='kw'>end</span>
488
494
  <span class='period'>.</span><span class='id identifier rubyid_run'>run</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_th'>th</span><span class='rparen'>)</span>
489
495
  <span class='kw'>end</span></pre>
@@ -497,9 +503,9 @@ But it still has the possibility to invoke effects(<code>e</code>).</p>
497
503
  </div>
498
504
 
499
505
  <div id="footer">
500
- Generated on Fri Oct 4 13:57:07 2019 by
506
+ Generated on Fri Oct 4 21:12:21 2019 by
501
507
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
502
- 0.9.20 (ruby-2.6.4).
508
+ 0.9.20 (ruby-2.6.5).
503
509
  </div>
504
510
 
505
511
  </div>