geet 0.22.0 → 0.23.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.
Files changed (65) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ci.yml +20 -0
  3. data/bin/tapioca +1 -14
  4. data/geet.gemspec +5 -3
  5. data/lib/geet/helpers/os_helper.rb +8 -1
  6. data/lib/geet/version.rb +1 -1
  7. data/sorbet/config +5 -0
  8. data/sorbet/rbi/annotations/.gitattributes +1 -0
  9. data/sorbet/rbi/annotations/rainbow.rbi +269 -0
  10. data/sorbet/rbi/annotations/webmock.rbi +9 -0
  11. data/sorbet/rbi/gems/.gitattributes +1 -0
  12. data/sorbet/rbi/gems/addressable@2.8.7.rbi +1994 -0
  13. data/sorbet/rbi/gems/ast@2.4.2.rbi +585 -0
  14. data/sorbet/rbi/gems/base64@0.3.0.rbi +545 -0
  15. data/sorbet/rbi/gems/benchmark@0.5.0.rbi +637 -0
  16. data/sorbet/rbi/gems/bigdecimal@3.1.8.rbi +9 -0
  17. data/sorbet/rbi/gems/byebug@11.1.3.rbi +37 -0
  18. data/sorbet/rbi/gems/crack@1.0.0.rbi +145 -0
  19. data/sorbet/rbi/gems/diff-lcs@1.6.2.rbi +1134 -0
  20. data/sorbet/rbi/gems/erubi@1.13.1.rbi +155 -0
  21. data/sorbet/rbi/gems/hashdiff@1.1.1.rbi +353 -0
  22. data/sorbet/rbi/gems/json@2.7.2.rbi +1608 -0
  23. data/sorbet/rbi/gems/logger@1.7.0.rbi +963 -0
  24. data/sorbet/rbi/gems/netrc@0.11.0.rbi +159 -0
  25. data/sorbet/rbi/gems/ostruct@0.6.3.rbi +354 -0
  26. data/sorbet/rbi/gems/parallel@1.27.0.rbi +291 -0
  27. data/sorbet/rbi/gems/parseconfig@1.1.2.rbi +9 -0
  28. data/sorbet/rbi/gems/parser@3.3.9.0.rbi +5535 -0
  29. data/sorbet/rbi/gems/pastel@0.8.0.rbi +9 -0
  30. data/sorbet/rbi/gems/prism@1.6.0.rbi +42068 -0
  31. data/sorbet/rbi/gems/public_suffix@6.0.1.rbi +936 -0
  32. data/sorbet/rbi/gems/racc@1.8.1.rbi +154 -0
  33. data/sorbet/rbi/gems/rainbow@3.1.1.rbi +9 -0
  34. data/sorbet/rbi/gems/rake@12.3.3.rbi +3020 -0
  35. data/sorbet/rbi/gems/rbi@0.3.7.rbi +7115 -0
  36. data/sorbet/rbi/gems/rbs@3.9.5.rbi +6978 -0
  37. data/sorbet/rbi/gems/regexp_parser@2.11.2.rbi +9 -0
  38. data/sorbet/rbi/gems/rexml@3.3.5.rbi +5283 -0
  39. data/sorbet/rbi/gems/rspec-core@3.13.6.rbi +11004 -0
  40. data/sorbet/rbi/gems/rspec-expectations@3.13.5.rbi +8189 -0
  41. data/sorbet/rbi/gems/rspec-mocks@3.13.6.rbi +5350 -0
  42. data/sorbet/rbi/gems/rspec-support@3.13.6.rbi +1627 -0
  43. data/sorbet/rbi/gems/rspec@3.13.2.rbi +83 -0
  44. data/sorbet/rbi/gems/rubocop-ast@1.46.0.rbi +9 -0
  45. data/sorbet/rbi/gems/rubocop@1.35.1.rbi +9 -0
  46. data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +9 -0
  47. data/sorbet/rbi/gems/simple_scripting@0.14.0.rbi +9 -0
  48. data/sorbet/rbi/gems/spoom@1.6.3.rbi +6985 -0
  49. data/sorbet/rbi/gems/strscan@3.1.0.rbi +9 -0
  50. data/sorbet/rbi/gems/tapioca@0.16.11.rbi +3628 -0
  51. data/sorbet/rbi/gems/thor@1.4.0.rbi +4399 -0
  52. data/sorbet/rbi/gems/tty-color@0.6.0.rbi +9 -0
  53. data/sorbet/rbi/gems/tty-cursor@0.7.1.rbi +9 -0
  54. data/sorbet/rbi/gems/tty-prompt@0.23.1.rbi +9 -0
  55. data/sorbet/rbi/gems/tty-reader@0.9.0.rbi +9 -0
  56. data/sorbet/rbi/gems/tty-screen@0.8.2.rbi +9 -0
  57. data/sorbet/rbi/gems/unicode-display_width@2.5.0.rbi +9 -0
  58. data/sorbet/rbi/gems/vcr@6.1.0.rbi +2830 -0
  59. data/sorbet/rbi/gems/webmock@3.1.1.rbi +1660 -0
  60. data/sorbet/rbi/gems/wisper@2.0.1.rbi +9 -0
  61. data/sorbet/rbi/gems/yard-sorbet@0.9.0.rbi +435 -0
  62. data/sorbet/rbi/gems/yard@0.9.37.rbi +18379 -0
  63. data/sorbet/tapioca/config.yml +13 -0
  64. data/sorbet/tapioca/require.rb +4 -0
  65. metadata +92 -8
@@ -0,0 +1,637 @@
1
+ # typed: true
2
+
3
+ # DO NOT EDIT MANUALLY
4
+ # This is an autogenerated file for types exported from the `benchmark` gem.
5
+ # Please instead update this file by running `bin/tapioca gem benchmark`.
6
+
7
+
8
+ # The Benchmark module provides methods to measure and report the time
9
+ # used to execute Ruby code.
10
+ #
11
+ # * Measure the time to construct the string given by the expression
12
+ # <code>"a"*1_000_000_000</code>:
13
+ #
14
+ # require 'benchmark'
15
+ #
16
+ # puts Benchmark.measure { "a"*1_000_000_000 }
17
+ #
18
+ # On my machine (OSX 10.8.3 on i5 1.7 GHz) this generates:
19
+ #
20
+ # 0.350000 0.400000 0.750000 ( 0.835234)
21
+ #
22
+ # This report shows the user CPU time, system CPU time, the total time
23
+ # (sum of user CPU time, system CPU time, children's user CPU time,
24
+ # and children's system CPU time), and the elapsed real time. The unit
25
+ # of time is seconds.
26
+ #
27
+ # * Do some experiments sequentially using the #bm method:
28
+ #
29
+ # require 'benchmark'
30
+ #
31
+ # n = 5000000
32
+ # Benchmark.bm do |x|
33
+ # x.report { for i in 1..n; a = "1"; end }
34
+ # x.report { n.times do ; a = "1"; end }
35
+ # x.report { 1.upto(n) do ; a = "1"; end }
36
+ # end
37
+ #
38
+ # The result:
39
+ #
40
+ # user system total real
41
+ # 1.010000 0.000000 1.010000 ( 1.014479)
42
+ # 1.000000 0.000000 1.000000 ( 0.998261)
43
+ # 0.980000 0.000000 0.980000 ( 0.981335)
44
+ #
45
+ # * Continuing the previous example, put a label in each report:
46
+ #
47
+ # require 'benchmark'
48
+ #
49
+ # n = 5000000
50
+ # Benchmark.bm(7) do |x|
51
+ # x.report("for:") { for i in 1..n; a = "1"; end }
52
+ # x.report("times:") { n.times do ; a = "1"; end }
53
+ # x.report("upto:") { 1.upto(n) do ; a = "1"; end }
54
+ # end
55
+ #
56
+ # The result:
57
+ #
58
+ # user system total real
59
+ # for: 1.010000 0.000000 1.010000 ( 1.015688)
60
+ # times: 1.000000 0.000000 1.000000 ( 1.003611)
61
+ # upto: 1.030000 0.000000 1.030000 ( 1.028098)
62
+ #
63
+ # * The times for some benchmarks depend on the order in which items
64
+ # are run. These differences are due to the cost of memory
65
+ # allocation and garbage collection. To avoid these discrepancies,
66
+ # the #bmbm method is provided. For example, to compare ways to
67
+ # sort an array of floats:
68
+ #
69
+ # require 'benchmark'
70
+ #
71
+ # array = (1..1000000).map { rand }
72
+ #
73
+ # Benchmark.bmbm do |x|
74
+ # x.report("sort!") { array.dup.sort! }
75
+ # x.report("sort") { array.dup.sort }
76
+ # end
77
+ #
78
+ # The result:
79
+ #
80
+ # Rehearsal -----------------------------------------
81
+ # sort! 1.490000 0.010000 1.500000 ( 1.490520)
82
+ # sort 1.460000 0.000000 1.460000 ( 1.463025)
83
+ # -------------------------------- total: 2.960000sec
84
+ #
85
+ # user system total real
86
+ # sort! 1.460000 0.000000 1.460000 ( 1.460465)
87
+ # sort 1.450000 0.010000 1.460000 ( 1.448327)
88
+ #
89
+ # * Report statistics of sequential experiments with unique labels,
90
+ # using the #benchmark method:
91
+ #
92
+ # require 'benchmark'
93
+ # include Benchmark # we need the CAPTION and FORMAT constants
94
+ #
95
+ # n = 5000000
96
+ # Benchmark.benchmark(CAPTION, 7, FORMAT, ">total:", ">avg:") do |x|
97
+ # tf = x.report("for:") { for i in 1..n; a = "1"; end }
98
+ # tt = x.report("times:") { n.times do ; a = "1"; end }
99
+ # tu = x.report("upto:") { 1.upto(n) do ; a = "1"; end }
100
+ # [tf+tt+tu, (tf+tt+tu)/3]
101
+ # end
102
+ #
103
+ # The result:
104
+ #
105
+ # user system total real
106
+ # for: 0.950000 0.000000 0.950000 ( 0.952039)
107
+ # times: 0.980000 0.000000 0.980000 ( 0.984938)
108
+ # upto: 0.950000 0.000000 0.950000 ( 0.946787)
109
+ # >total: 2.880000 0.000000 2.880000 ( 2.883764)
110
+ # >avg: 0.960000 0.000000 0.960000 ( 0.961255)
111
+ #
112
+ # source://benchmark//lib/benchmark.rb#123
113
+ module Benchmark
114
+ private
115
+
116
+ # Invokes the block with a Benchmark::Report object, which
117
+ # may be used to collect and report on the results of individual
118
+ # benchmark tests. Reserves +label_width+ leading spaces for
119
+ # labels on each line. Prints +caption+ at the top of the
120
+ # report, and uses +format+ to format each line.
121
+ # (Note: +caption+ must contain a terminating newline character,
122
+ # see the default Benchmark::Tms::CAPTION for an example.)
123
+ #
124
+ # Returns an array of Benchmark::Tms objects.
125
+ #
126
+ # If the block returns an array of
127
+ # Benchmark::Tms objects, these will be used to format
128
+ # additional lines of output. If +labels+ parameter are
129
+ # given, these are used to label these extra lines.
130
+ #
131
+ # _Note_: Other methods provide a simpler interface to this one, and are
132
+ # suitable for nearly all benchmarking requirements. See the examples in
133
+ # Benchmark, and the #bm and #bmbm methods.
134
+ #
135
+ # Example:
136
+ #
137
+ # require 'benchmark'
138
+ # include Benchmark # we need the CAPTION and FORMAT constants
139
+ #
140
+ # n = 5000000
141
+ # Benchmark.benchmark(CAPTION, 7, FORMAT, ">total:", ">avg:") do |x|
142
+ # tf = x.report("for:") { for i in 1..n; a = "1"; end }
143
+ # tt = x.report("times:") { n.times do ; a = "1"; end }
144
+ # tu = x.report("upto:") { 1.upto(n) do ; a = "1"; end }
145
+ # [tf+tt+tu, (tf+tt+tu)/3]
146
+ # end
147
+ #
148
+ # Generates:
149
+ #
150
+ # user system total real
151
+ # for: 0.970000 0.000000 0.970000 ( 0.970493)
152
+ # times: 0.990000 0.000000 0.990000 ( 0.989542)
153
+ # upto: 0.970000 0.000000 0.970000 ( 0.972854)
154
+ # >total: 2.930000 0.000000 2.930000 ( 2.932889)
155
+ # >avg: 0.976667 0.000000 0.976667 ( 0.977630)
156
+ #
157
+ # source://benchmark//lib/benchmark.rb#171
158
+ def benchmark(caption = T.unsafe(nil), label_width = T.unsafe(nil), format = T.unsafe(nil), *labels); end
159
+
160
+ # A simple interface to the #benchmark method, #bm generates sequential
161
+ # reports with labels. +label_width+ and +labels+ parameters have the same
162
+ # meaning as for #benchmark.
163
+ #
164
+ # require 'benchmark'
165
+ #
166
+ # n = 5000000
167
+ # Benchmark.bm(7) do |x|
168
+ # x.report("for:") { for i in 1..n; a = "1"; end }
169
+ # x.report("times:") { n.times do ; a = "1"; end }
170
+ # x.report("upto:") { 1.upto(n) do ; a = "1"; end }
171
+ # end
172
+ #
173
+ # Generates:
174
+ #
175
+ # user system total real
176
+ # for: 0.960000 0.000000 0.960000 ( 0.957966)
177
+ # times: 0.960000 0.000000 0.960000 ( 0.960423)
178
+ # upto: 0.950000 0.000000 0.950000 ( 0.954864)
179
+ #
180
+ # source://benchmark//lib/benchmark.rb#216
181
+ def bm(label_width = T.unsafe(nil), *labels, &blk); end
182
+
183
+ # Sometimes benchmark results are skewed because code executed
184
+ # earlier encounters different garbage collection overheads than
185
+ # that run later. #bmbm attempts to minimize this effect by running
186
+ # the tests twice, the first time as a rehearsal in order to get the
187
+ # runtime environment stable, the second time for
188
+ # real. GC.start is executed before the start of each of
189
+ # the real timings; the cost of this is not included in the
190
+ # timings. In reality, though, there's only so much that #bmbm can
191
+ # do, and the results are not guaranteed to be isolated from garbage
192
+ # collection and other effects.
193
+ #
194
+ # Because #bmbm takes two passes through the tests, it can
195
+ # calculate the required label width.
196
+ #
197
+ # require 'benchmark'
198
+ #
199
+ # array = (1..1000000).map { rand }
200
+ #
201
+ # Benchmark.bmbm do |x|
202
+ # x.report("sort!") { array.dup.sort! }
203
+ # x.report("sort") { array.dup.sort }
204
+ # end
205
+ #
206
+ # Generates:
207
+ #
208
+ # Rehearsal -----------------------------------------
209
+ # sort! 1.440000 0.010000 1.450000 ( 1.446833)
210
+ # sort 1.440000 0.000000 1.440000 ( 1.448257)
211
+ # -------------------------------- total: 2.890000sec
212
+ #
213
+ # user system total real
214
+ # sort! 1.460000 0.000000 1.460000 ( 1.458065)
215
+ # sort 1.450000 0.000000 1.450000 ( 1.455963)
216
+ #
217
+ # #bmbm yields a Benchmark::Job object and returns an array of
218
+ # Benchmark::Tms objects.
219
+ #
220
+ # source://benchmark//lib/benchmark.rb#258
221
+ def bmbm(width = T.unsafe(nil)); end
222
+
223
+ # Returns the time used to execute the given block as a
224
+ # Benchmark::Tms object. Takes +label+ option.
225
+ #
226
+ # require 'benchmark'
227
+ #
228
+ # n = 1000000
229
+ #
230
+ # time = Benchmark.measure do
231
+ # n.times { a = "1" }
232
+ # end
233
+ # puts time
234
+ #
235
+ # Generates:
236
+ #
237
+ # 0.220000 0.000000 0.220000 ( 0.227313)
238
+ #
239
+ # source://benchmark//lib/benchmark.rb#303
240
+ def measure(label = T.unsafe(nil)); end
241
+
242
+ # Returns the elapsed real time used to execute the given block.
243
+ # The unit of time is milliseconds.
244
+ #
245
+ # Benchmark.ms { "a" * 1_000_000_000 }
246
+ # #=> 509.8029999935534
247
+ #
248
+ # source://benchmark//lib/benchmark.rb#335
249
+ def ms; end
250
+
251
+ # Returns the elapsed real time used to execute the given block.
252
+ # The unit of time is seconds.
253
+ #
254
+ # Benchmark.realtime { "a" * 1_000_000_000 }
255
+ # #=> 0.5098029999935534
256
+ #
257
+ # source://benchmark//lib/benchmark.rb#322
258
+ def realtime; end
259
+
260
+ class << self
261
+ # Invokes the block with a Benchmark::Report object, which
262
+ # may be used to collect and report on the results of individual
263
+ # benchmark tests. Reserves +label_width+ leading spaces for
264
+ # labels on each line. Prints +caption+ at the top of the
265
+ # report, and uses +format+ to format each line.
266
+ # (Note: +caption+ must contain a terminating newline character,
267
+ # see the default Benchmark::Tms::CAPTION for an example.)
268
+ #
269
+ # Returns an array of Benchmark::Tms objects.
270
+ #
271
+ # If the block returns an array of
272
+ # Benchmark::Tms objects, these will be used to format
273
+ # additional lines of output. If +labels+ parameter are
274
+ # given, these are used to label these extra lines.
275
+ #
276
+ # _Note_: Other methods provide a simpler interface to this one, and are
277
+ # suitable for nearly all benchmarking requirements. See the examples in
278
+ # Benchmark, and the #bm and #bmbm methods.
279
+ #
280
+ # Example:
281
+ #
282
+ # require 'benchmark'
283
+ # include Benchmark # we need the CAPTION and FORMAT constants
284
+ #
285
+ # n = 5000000
286
+ # Benchmark.benchmark(CAPTION, 7, FORMAT, ">total:", ">avg:") do |x|
287
+ # tf = x.report("for:") { for i in 1..n; a = "1"; end }
288
+ # tt = x.report("times:") { n.times do ; a = "1"; end }
289
+ # tu = x.report("upto:") { 1.upto(n) do ; a = "1"; end }
290
+ # [tf+tt+tu, (tf+tt+tu)/3]
291
+ # end
292
+ #
293
+ # Generates:
294
+ #
295
+ # user system total real
296
+ # for: 0.970000 0.000000 0.970000 ( 0.970493)
297
+ # times: 0.990000 0.000000 0.990000 ( 0.989542)
298
+ # upto: 0.970000 0.000000 0.970000 ( 0.972854)
299
+ # >total: 2.930000 0.000000 2.930000 ( 2.932889)
300
+ # >avg: 0.976667 0.000000 0.976667 ( 0.977630)
301
+ #
302
+ # source://benchmark//lib/benchmark.rb#171
303
+ def benchmark(caption = T.unsafe(nil), label_width = T.unsafe(nil), format = T.unsafe(nil), *labels); end
304
+
305
+ # A simple interface to the #benchmark method, #bm generates sequential
306
+ # reports with labels. +label_width+ and +labels+ parameters have the same
307
+ # meaning as for #benchmark.
308
+ #
309
+ # require 'benchmark'
310
+ #
311
+ # n = 5000000
312
+ # Benchmark.bm(7) do |x|
313
+ # x.report("for:") { for i in 1..n; a = "1"; end }
314
+ # x.report("times:") { n.times do ; a = "1"; end }
315
+ # x.report("upto:") { 1.upto(n) do ; a = "1"; end }
316
+ # end
317
+ #
318
+ # Generates:
319
+ #
320
+ # user system total real
321
+ # for: 0.960000 0.000000 0.960000 ( 0.957966)
322
+ # times: 0.960000 0.000000 0.960000 ( 0.960423)
323
+ # upto: 0.950000 0.000000 0.950000 ( 0.954864)
324
+ #
325
+ # source://benchmark//lib/benchmark.rb#216
326
+ def bm(label_width = T.unsafe(nil), *labels, &blk); end
327
+
328
+ # Sometimes benchmark results are skewed because code executed
329
+ # earlier encounters different garbage collection overheads than
330
+ # that run later. #bmbm attempts to minimize this effect by running
331
+ # the tests twice, the first time as a rehearsal in order to get the
332
+ # runtime environment stable, the second time for
333
+ # real. GC.start is executed before the start of each of
334
+ # the real timings; the cost of this is not included in the
335
+ # timings. In reality, though, there's only so much that #bmbm can
336
+ # do, and the results are not guaranteed to be isolated from garbage
337
+ # collection and other effects.
338
+ #
339
+ # Because #bmbm takes two passes through the tests, it can
340
+ # calculate the required label width.
341
+ #
342
+ # require 'benchmark'
343
+ #
344
+ # array = (1..1000000).map { rand }
345
+ #
346
+ # Benchmark.bmbm do |x|
347
+ # x.report("sort!") { array.dup.sort! }
348
+ # x.report("sort") { array.dup.sort }
349
+ # end
350
+ #
351
+ # Generates:
352
+ #
353
+ # Rehearsal -----------------------------------------
354
+ # sort! 1.440000 0.010000 1.450000 ( 1.446833)
355
+ # sort 1.440000 0.000000 1.440000 ( 1.448257)
356
+ # -------------------------------- total: 2.890000sec
357
+ #
358
+ # user system total real
359
+ # sort! 1.460000 0.000000 1.460000 ( 1.458065)
360
+ # sort 1.450000 0.000000 1.450000 ( 1.455963)
361
+ #
362
+ # #bmbm yields a Benchmark::Job object and returns an array of
363
+ # Benchmark::Tms objects.
364
+ #
365
+ # source://benchmark//lib/benchmark.rb#258
366
+ def bmbm(width = T.unsafe(nil)); end
367
+
368
+ # Returns the time used to execute the given block as a
369
+ # Benchmark::Tms object. Takes +label+ option.
370
+ #
371
+ # require 'benchmark'
372
+ #
373
+ # n = 1000000
374
+ #
375
+ # time = Benchmark.measure do
376
+ # n.times { a = "1" }
377
+ # end
378
+ # puts time
379
+ #
380
+ # Generates:
381
+ #
382
+ # 0.220000 0.000000 0.220000 ( 0.227313)
383
+ #
384
+ # source://benchmark//lib/benchmark.rb#303
385
+ def measure(label = T.unsafe(nil)); end
386
+
387
+ # Returns the elapsed real time used to execute the given block.
388
+ # The unit of time is milliseconds.
389
+ #
390
+ # Benchmark.ms { "a" * 1_000_000_000 }
391
+ # #=> 509.8029999935534
392
+ #
393
+ # source://benchmark//lib/benchmark.rb#335
394
+ def ms; end
395
+
396
+ # Returns the elapsed real time used to execute the given block.
397
+ # The unit of time is seconds.
398
+ #
399
+ # Benchmark.realtime { "a" * 1_000_000_000 }
400
+ # #=> 0.5098029999935534
401
+ #
402
+ # source://benchmark//lib/benchmark.rb#322
403
+ def realtime; end
404
+ end
405
+ end
406
+
407
+ # A Job is a sequence of labelled blocks to be processed by the
408
+ # Benchmark.bmbm method. It is of little direct interest to the user.
409
+ #
410
+ # source://benchmark//lib/benchmark.rb#347
411
+ class Benchmark::Job
412
+ # Returns an initialized Job instance.
413
+ # Usually, one doesn't call this method directly, as new
414
+ # Job objects are created by the #bmbm method.
415
+ # +width+ is a initial value for the label offset used in formatting;
416
+ # the #bmbm method passes its +width+ argument to this constructor.
417
+ #
418
+ # @return [Job] a new instance of Job
419
+ #
420
+ # source://benchmark//lib/benchmark.rb#355
421
+ def initialize(width); end
422
+
423
+ # Registers the given label and block pair in the job list.
424
+ #
425
+ # @raise [ArgumentError]
426
+ #
427
+ # source://benchmark//lib/benchmark.rb#363
428
+ def item(label = T.unsafe(nil), &blk); end
429
+
430
+ # An array of 2-element arrays, consisting of label and block pairs.
431
+ #
432
+ # source://benchmark//lib/benchmark.rb#375
433
+ def list; end
434
+
435
+ # Registers the given label and block pair in the job list.
436
+ #
437
+ # @raise [ArgumentError]
438
+ #
439
+ # source://benchmark//lib/benchmark.rb#363
440
+ def report(label = T.unsafe(nil), &blk); end
441
+
442
+ # Length of the widest label in the #list.
443
+ #
444
+ # source://benchmark//lib/benchmark.rb#378
445
+ def width; end
446
+ end
447
+
448
+ # This class is used by the Benchmark.benchmark and Benchmark.bm methods.
449
+ # It is of little direct interest to the user.
450
+ #
451
+ # source://benchmark//lib/benchmark.rb#385
452
+ class Benchmark::Report
453
+ # Returns an initialized Report instance.
454
+ # Usually, one doesn't call this method directly, as new
455
+ # Report objects are created by the #benchmark and #bm methods.
456
+ # +width+ and +format+ are the label offset and
457
+ # format string used by Tms#format.
458
+ #
459
+ # @return [Report] a new instance of Report
460
+ #
461
+ # source://benchmark//lib/benchmark.rb#393
462
+ def initialize(width = T.unsafe(nil), format = T.unsafe(nil)); end
463
+
464
+ # An array of Benchmark::Tms objects representing each item.
465
+ #
466
+ # source://benchmark//lib/benchmark.rb#412
467
+ def format; end
468
+
469
+ # Prints the +label+ and measured time for the block,
470
+ # formatted by +format+. See Tms#format for the
471
+ # formatting rules.
472
+ #
473
+ # source://benchmark//lib/benchmark.rb#402
474
+ def item(label = T.unsafe(nil), *format, &blk); end
475
+
476
+ # An array of Benchmark::Tms objects representing each item.
477
+ #
478
+ # source://benchmark//lib/benchmark.rb#412
479
+ def list; end
480
+
481
+ # Prints the +label+ and measured time for the block,
482
+ # formatted by +format+. See Tms#format for the
483
+ # formatting rules.
484
+ #
485
+ # source://benchmark//lib/benchmark.rb#402
486
+ def report(label = T.unsafe(nil), *format, &blk); end
487
+
488
+ # An array of Benchmark::Tms objects representing each item.
489
+ #
490
+ # source://benchmark//lib/benchmark.rb#412
491
+ def width; end
492
+ end
493
+
494
+ # A data object, representing the times associated with a benchmark
495
+ # measurement.
496
+ #
497
+ # source://benchmark//lib/benchmark.rb#421
498
+ class Benchmark::Tms
499
+ # Returns an initialized Tms object which has
500
+ # +utime+ as the user CPU time, +stime+ as the system CPU time,
501
+ # +cutime+ as the children's user CPU time, +cstime+ as the children's
502
+ # system CPU time, +real+ as the elapsed real time and +label+ as the label.
503
+ #
504
+ # @return [Tms] a new instance of Tms
505
+ #
506
+ # source://benchmark//lib/benchmark.rb#456
507
+ def initialize(utime = T.unsafe(nil), stime = T.unsafe(nil), cutime = T.unsafe(nil), cstime = T.unsafe(nil), real = T.unsafe(nil), label = T.unsafe(nil)); end
508
+
509
+ # Returns a new Tms object obtained by memberwise multiplication
510
+ # of the individual times for this Tms object by +x+.
511
+ #
512
+ # source://benchmark//lib/benchmark.rb#504
513
+ def *(x); end
514
+
515
+ # Returns a new Tms object obtained by memberwise summation
516
+ # of the individual times for this Tms object with those of the +other+
517
+ # Tms object.
518
+ # This method and #/() are useful for taking statistics.
519
+ #
520
+ # source://benchmark//lib/benchmark.rb#491
521
+ def +(other); end
522
+
523
+ # Returns a new Tms object obtained by memberwise subtraction
524
+ # of the individual times for the +other+ Tms object from those of this
525
+ # Tms object.
526
+ #
527
+ # source://benchmark//lib/benchmark.rb#498
528
+ def -(other); end
529
+
530
+ # Returns a new Tms object obtained by memberwise division
531
+ # of the individual times for this Tms object by +x+.
532
+ # This method and #+() are useful for taking statistics.
533
+ #
534
+ # source://benchmark//lib/benchmark.rb#511
535
+ def /(x); end
536
+
537
+ # Returns a new Tms object whose times are the sum of the times for this
538
+ # Tms object, plus the time required to execute the code block (+blk+).
539
+ #
540
+ # source://benchmark//lib/benchmark.rb#465
541
+ def add(&blk); end
542
+
543
+ # An in-place version of #add.
544
+ # Changes the times of this Tms object by making it the sum of the times
545
+ # for this Tms object, plus the time required to execute
546
+ # the code block (+blk+).
547
+ #
548
+ # source://benchmark//lib/benchmark.rb#475
549
+ def add!(&blk); end
550
+
551
+ # System CPU time of children
552
+ #
553
+ # source://benchmark//lib/benchmark.rb#439
554
+ def cstime; end
555
+
556
+ # User CPU time of children
557
+ #
558
+ # source://benchmark//lib/benchmark.rb#436
559
+ def cutime; end
560
+
561
+ # Returns the contents of this Tms object as
562
+ # a formatted string, according to a +format+ string
563
+ # like that passed to Kernel.format. In addition, #format
564
+ # accepts the following extensions:
565
+ #
566
+ # <tt>%u</tt>:: Replaced by the user CPU time, as reported by Tms#utime.
567
+ # <tt>%y</tt>:: Replaced by the system CPU time, as reported by Tms#stime (Mnemonic: y of "s*y*stem")
568
+ # <tt>%U</tt>:: Replaced by the children's user CPU time, as reported by Tms#cutime
569
+ # <tt>%Y</tt>:: Replaced by the children's system CPU time, as reported by Tms#cstime
570
+ # <tt>%t</tt>:: Replaced by the total CPU time, as reported by Tms#total
571
+ # <tt>%r</tt>:: Replaced by the elapsed real time, as reported by Tms#real
572
+ # <tt>%n</tt>:: Replaced by the label string, as reported by Tms#label (Mnemonic: n of "*n*ame")
573
+ #
574
+ # If +format+ is not given, FORMAT is used as default value, detailing the
575
+ # user, system, total and real elapsed time.
576
+ #
577
+ # source://benchmark//lib/benchmark.rb#530
578
+ def format(format = T.unsafe(nil), *args); end
579
+
580
+ # Label
581
+ #
582
+ # source://benchmark//lib/benchmark.rb#448
583
+ def label; end
584
+
585
+ # Elapsed real time
586
+ #
587
+ # source://benchmark//lib/benchmark.rb#442
588
+ def real; end
589
+
590
+ # System CPU time
591
+ #
592
+ # source://benchmark//lib/benchmark.rb#433
593
+ def stime; end
594
+
595
+ # Returns a new 6-element array, consisting of the
596
+ # label, user CPU time, system CPU time, children's
597
+ # user CPU time, children's system CPU time and elapsed
598
+ # real time.
599
+ #
600
+ # source://benchmark//lib/benchmark.rb#555
601
+ def to_a; end
602
+
603
+ # Returns a hash containing the same data as `to_a`.
604
+ #
605
+ # source://benchmark//lib/benchmark.rb#562
606
+ def to_h; end
607
+
608
+ # Same as #format.
609
+ #
610
+ # source://benchmark//lib/benchmark.rb#545
611
+ def to_s; end
612
+
613
+ # Total time, that is +utime+ + +stime+ + +cutime+ + +cstime+
614
+ #
615
+ # source://benchmark//lib/benchmark.rb#445
616
+ def total; end
617
+
618
+ # User CPU time
619
+ #
620
+ # source://benchmark//lib/benchmark.rb#430
621
+ def utime; end
622
+
623
+ protected
624
+
625
+ # Returns a new Tms object obtained by memberwise operation +op+
626
+ # of the individual times for this Tms object with those of the other
627
+ # Tms object (+x+).
628
+ #
629
+ # +op+ can be a mathematical operation such as <tt>+</tt>, <tt>-</tt>,
630
+ # <tt>*</tt>, <tt>/</tt>
631
+ #
632
+ # source://benchmark//lib/benchmark.rb#583
633
+ def memberwise(op, x); end
634
+ end
635
+
636
+ # source://benchmark//lib/benchmark.rb#125
637
+ Benchmark::VERSION = T.let(T.unsafe(nil), String)
@@ -0,0 +1,9 @@
1
+ # typed: true
2
+
3
+ # DO NOT EDIT MANUALLY
4
+ # This is an autogenerated file for types exported from the `bigdecimal` gem.
5
+ # Please instead update this file by running `bin/tapioca gem bigdecimal`.
6
+
7
+
8
+ # THIS IS AN EMPTY RBI FILE.
9
+ # see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem
@@ -0,0 +1,37 @@
1
+ # typed: true
2
+
3
+ # DO NOT EDIT MANUALLY
4
+ # This is an autogenerated file for types exported from the `byebug` gem.
5
+ # Please instead update this file by running `bin/tapioca gem byebug`.
6
+
7
+
8
+ # Reopen main module to define the library version
9
+ #
10
+ # source://byebug//lib/byebug/attacher.rb#6
11
+ module Byebug
12
+ class << self
13
+ # Starts byebug, and stops at the first line of user's code.
14
+ #
15
+ # source://byebug//lib/byebug/attacher.rb#10
16
+ def attach; end
17
+
18
+ # source://byebug//lib/byebug/attacher.rb#21
19
+ def spawn(host = T.unsafe(nil), port = T.unsafe(nil)); end
20
+ end
21
+ end
22
+
23
+ # Adds a `byebug` method to the Kernel module.
24
+ #
25
+ # Dropping a `byebug` call anywhere in your code, you get a debug prompt.
26
+ #
27
+ # source://byebug//lib/byebug/attacher.rb#34
28
+ module Kernel
29
+ # source://byebug//lib/byebug/attacher.rb#35
30
+ def byebug; end
31
+
32
+ # source://byebug//lib/byebug/attacher.rb#35
33
+ def debugger; end
34
+
35
+ # source://byebug//lib/byebug/attacher.rb#41
36
+ def remote_byebug(host = T.unsafe(nil), port = T.unsafe(nil)); end
37
+ end