hamster 0.1.15 → 0.1.16
Sign up to get free protection for your applications and to get access to all the features.
- data/History.rdoc +16 -0
- data/README.rdoc +10 -10
- data/lib/hamster/core_ext/enumerable.rb +1 -1
- data/lib/hamster/core_ext/enumerable.rbc +481 -0
- data/lib/hamster/core_ext/io.rb +0 -1
- data/lib/hamster/core_ext/io.rbc +604 -0
- data/lib/hamster/hash.rb +6 -6
- data/lib/hamster/hash.rbc +3117 -0
- data/lib/hamster/list.rb +50 -14
- data/lib/hamster/list.rbc +7274 -0
- data/lib/hamster/set.rb +8 -7
- data/lib/hamster/set.rbc +3152 -0
- data/lib/hamster/stack.rbc +1358 -0
- data/lib/hamster/trie.rbc +3416 -0
- data/lib/hamster/version.rb +1 -1
- data/spec/hamster/core_ext/enumerable_spec.rb +1 -1
- data/spec/hamster/core_ext/enumerable_spec.rbc +747 -0
- data/spec/hamster/core_ext/io_spec.rbc +409 -0
- data/spec/hamster/hash/all_spec.rbc +1214 -0
- data/spec/hamster/hash/any_spec.rbc +1495 -0
- data/spec/hamster/hash/construction_spec.rbc +742 -0
- data/spec/hamster/hash/copying_spec.rbc +519 -0
- data/spec/hamster/hash/each_spec.rbc +908 -0
- data/spec/hamster/hash/empty_spec.rbc +517 -0
- data/spec/hamster/hash/eql_spec.rb +1 -1
- data/spec/hamster/hash/eql_spec.rbc +1702 -0
- data/spec/hamster/hash/filter_spec.rbc +1433 -0
- data/spec/hamster/hash/get_spec.rbc +791 -0
- data/spec/hamster/hash/has_key_spec.rbc +719 -0
- data/spec/hamster/hash/map_spec.rbc +1454 -0
- data/spec/hamster/hash/none_spec.rbc +1399 -0
- data/spec/hamster/hash/put_spec.rbc +1334 -0
- data/spec/hamster/hash/reduce_spec.rbc +1234 -0
- data/spec/hamster/hash/reject_spec.rbc +1445 -0
- data/spec/hamster/hash/remove_spec.rbc +1135 -0
- data/spec/hamster/hash/size_spec.rbc +596 -0
- data/spec/hamster/list/all_spec.rb +12 -4
- data/spec/hamster/list/all_spec.rbc +1760 -0
- data/spec/hamster/list/any_spec.rb +12 -4
- data/spec/hamster/list/any_spec.rbc +1888 -0
- data/spec/hamster/list/append_spec.rb +12 -5
- data/spec/hamster/list/append_spec.rbc +1555 -0
- data/spec/hamster/list/cadr_spec.rb +1 -1
- data/spec/hamster/list/cadr_spec.rbc +855 -0
- data/spec/hamster/list/cons_spec.rbc +848 -0
- data/spec/hamster/list/construction_spec.rbc +1732 -0
- data/spec/hamster/list/copying_spec.rbc +555 -0
- data/spec/hamster/list/drop_spec.rb +12 -4
- data/spec/hamster/list/drop_spec.rbc +1081 -0
- data/spec/hamster/list/drop_while_spec.rb +12 -4
- data/spec/hamster/list/drop_while_spec.rbc +1286 -0
- data/spec/hamster/list/each_spec.rb +13 -5
- data/spec/hamster/list/each_spec.rbc +1365 -0
- data/spec/hamster/list/empty_spec.rb +1 -1
- data/spec/hamster/list/empty_spec.rbc +571 -0
- data/spec/hamster/list/eql_spec.rb +15 -5
- data/spec/hamster/list/eql_spec.rbc +1819 -0
- data/spec/hamster/list/filter_spec.rb +13 -5
- data/spec/hamster/list/filter_spec.rbc +1595 -0
- data/spec/hamster/list/find_spec.rb +12 -4
- data/spec/hamster/list/find_spec.rbc +1456 -0
- data/spec/hamster/list/head_spec.rb +1 -1
- data/spec/hamster/list/head_spec.rbc +575 -0
- data/spec/hamster/list/include_spec.rb +12 -4
- data/spec/hamster/list/include_spec.rbc +1173 -0
- data/spec/hamster/list/inspect_spec.rb +13 -5
- data/spec/hamster/list/inspect_spec.rbc +995 -0
- data/spec/hamster/list/map_spec.rb +12 -4
- data/spec/hamster/list/map_spec.rbc +1545 -0
- data/spec/hamster/list/maximum_spec.rb +83 -0
- data/spec/hamster/list/minimum_spec.rb +83 -0
- data/spec/hamster/list/none_spec.rb +11 -3
- data/spec/hamster/list/none_spec.rbc +1788 -0
- data/spec/hamster/list/one_spec.rb +83 -0
- data/spec/hamster/list/partition_spec.rb +37 -9
- data/spec/hamster/list/partition_spec.rbc +2715 -0
- data/spec/hamster/list/reduce_spec.rb +12 -4
- data/spec/hamster/list/reduce_spec.rbc +2081 -0
- data/spec/hamster/list/reject_spec.rb +12 -4
- data/spec/hamster/list/reject_spec.rbc +1590 -0
- data/spec/hamster/list/reverse_spec.rb +12 -4
- data/spec/hamster/list/reverse_spec.rbc +1061 -0
- data/spec/hamster/list/size_spec.rb +13 -5
- data/spec/hamster/list/size_spec.rbc +1063 -0
- data/spec/hamster/list/tail_spec.rb +1 -1
- data/spec/hamster/list/tail_spec.rbc +595 -0
- data/spec/hamster/list/take_spec.rb +12 -4
- data/spec/hamster/list/take_spec.rbc +1075 -0
- data/spec/hamster/list/take_while_spec.rb +12 -4
- data/spec/hamster/list/take_while_spec.rbc +1446 -0
- data/spec/hamster/list/to_a_spec.rb +31 -19
- data/spec/hamster/list/to_a_spec.rbc +961 -0
- data/spec/hamster/list/to_ary_spec.rb +11 -3
- data/spec/hamster/list/to_ary_spec.rbc +1080 -0
- data/spec/hamster/list/to_list_spec.rb +31 -0
- data/spec/hamster/set/add_spec.rbc +1039 -0
- data/spec/hamster/set/all_spec.rbc +1316 -0
- data/spec/hamster/set/any_spec.rbc +1444 -0
- data/spec/hamster/set/construction_spec.rbc +422 -0
- data/spec/hamster/set/copying_spec.rbc +469 -0
- data/spec/hamster/set/each_spec.rbc +820 -0
- data/spec/hamster/set/empty_spec.rbc +452 -0
- data/spec/hamster/set/eql_spec.rb +1 -1
- data/spec/hamster/set/eql_spec.rbc +1309 -0
- data/spec/hamster/set/filter_spec.rbc +1272 -0
- data/spec/hamster/set/include_spec.rbc +657 -0
- data/spec/hamster/set/map_spec.rbc +1285 -0
- data/spec/hamster/set/none_spec.rbc +1344 -0
- data/spec/hamster/set/reduce_spec.rbc +1177 -0
- data/spec/hamster/set/reject_spec.rbc +1273 -0
- data/spec/hamster/set/remove_spec.rbc +947 -0
- data/spec/hamster/set/size_spec.rbc +531 -0
- data/spec/hamster/set/to_a_spec.rb +16 -12
- data/spec/hamster/set/to_a_spec.rbc +559 -0
- data/spec/hamster/stack/construction_spec.rbc +862 -0
- data/spec/hamster/stack/copying_spec.rbc +555 -0
- data/spec/hamster/stack/empty_spec.rb +1 -1
- data/spec/hamster/stack/empty_spec.rbc +571 -0
- data/spec/hamster/stack/eql_spec.rb +1 -1
- data/spec/hamster/stack/eql_spec.rbc +1281 -0
- data/spec/hamster/stack/inspect_spec.rb +1 -1
- data/spec/hamster/stack/inspect_spec.rbc +586 -0
- data/spec/hamster/stack/pop_spec.rbc +1099 -0
- data/spec/hamster/stack/push_spec.rbc +848 -0
- data/spec/hamster/stack/size_spec.rb +1 -1
- data/spec/hamster/stack/size_spec.rbc +650 -0
- data/spec/hamster/stack/top_spec.rbc +676 -0
- data/spec/hamster/trie/remove_spec.rbc +40 -0
- data/spec/spec_helper.rbc +163 -0
- data/tasks/spec.rbc +201 -0
- metadata +90 -2
@@ -0,0 +1,595 @@
|
|
1
|
+
!RBIX
|
2
|
+
0
|
3
|
+
x
|
4
|
+
M
|
5
|
+
1
|
6
|
+
n
|
7
|
+
n
|
8
|
+
x
|
9
|
+
10
|
10
|
+
__script__
|
11
|
+
i
|
12
|
+
50
|
13
|
+
5
|
14
|
+
42
|
15
|
+
0
|
16
|
+
1
|
17
|
+
42
|
18
|
+
0
|
19
|
+
2
|
20
|
+
61
|
21
|
+
45
|
22
|
+
3
|
23
|
+
46
|
24
|
+
4
|
25
|
+
1
|
26
|
+
7
|
27
|
+
5
|
28
|
+
60
|
29
|
+
77
|
30
|
+
6
|
31
|
+
46
|
32
|
+
7
|
33
|
+
1
|
34
|
+
44
|
35
|
+
46
|
36
|
+
8
|
37
|
+
1
|
38
|
+
14
|
39
|
+
5
|
40
|
+
7
|
41
|
+
9
|
42
|
+
60
|
43
|
+
44
|
44
|
+
46
|
45
|
+
8
|
46
|
+
1
|
47
|
+
14
|
48
|
+
5
|
49
|
+
42
|
50
|
+
10
|
51
|
+
11
|
52
|
+
40
|
53
|
+
12
|
54
|
+
53
|
55
|
+
13
|
56
|
+
44
|
57
|
+
47
|
58
|
+
14
|
59
|
+
1
|
60
|
+
14
|
61
|
+
2
|
62
|
+
11
|
63
|
+
I
|
64
|
+
4
|
65
|
+
I
|
66
|
+
0
|
67
|
+
I
|
68
|
+
0
|
69
|
+
I
|
70
|
+
0
|
71
|
+
n
|
72
|
+
p
|
73
|
+
15
|
74
|
+
x
|
75
|
+
4
|
76
|
+
File
|
77
|
+
n
|
78
|
+
n
|
79
|
+
x
|
80
|
+
11
|
81
|
+
active_path
|
82
|
+
x
|
83
|
+
7
|
84
|
+
dirname
|
85
|
+
s
|
86
|
+
18
|
87
|
+
/../../spec_helper
|
88
|
+
x
|
89
|
+
1
|
90
|
+
+
|
91
|
+
x
|
92
|
+
11
|
93
|
+
expand_path
|
94
|
+
x
|
95
|
+
7
|
96
|
+
require
|
97
|
+
s
|
98
|
+
12
|
99
|
+
hamster/list
|
100
|
+
x
|
101
|
+
7
|
102
|
+
Hamster
|
103
|
+
n
|
104
|
+
x
|
105
|
+
4
|
106
|
+
List
|
107
|
+
M
|
108
|
+
1
|
109
|
+
n
|
110
|
+
n
|
111
|
+
x
|
112
|
+
9
|
113
|
+
__block__
|
114
|
+
i
|
115
|
+
11
|
116
|
+
5
|
117
|
+
7
|
118
|
+
0
|
119
|
+
60
|
120
|
+
53
|
121
|
+
1
|
122
|
+
44
|
123
|
+
47
|
124
|
+
2
|
125
|
+
1
|
126
|
+
11
|
127
|
+
I
|
128
|
+
4
|
129
|
+
I
|
130
|
+
0
|
131
|
+
I
|
132
|
+
-1
|
133
|
+
I
|
134
|
+
-1
|
135
|
+
n
|
136
|
+
p
|
137
|
+
3
|
138
|
+
s
|
139
|
+
5
|
140
|
+
#tail
|
141
|
+
M
|
142
|
+
1
|
143
|
+
n
|
144
|
+
n
|
145
|
+
x
|
146
|
+
9
|
147
|
+
__block__
|
148
|
+
i
|
149
|
+
44
|
150
|
+
32
|
151
|
+
0
|
152
|
+
32
|
153
|
+
0
|
154
|
+
32
|
155
|
+
2
|
156
|
+
7
|
157
|
+
0
|
158
|
+
60
|
159
|
+
32
|
160
|
+
1
|
161
|
+
32
|
162
|
+
0
|
163
|
+
32
|
164
|
+
2
|
165
|
+
7
|
166
|
+
0
|
167
|
+
60
|
168
|
+
7
|
169
|
+
1
|
170
|
+
60
|
171
|
+
7
|
172
|
+
2
|
173
|
+
60
|
174
|
+
32
|
175
|
+
3
|
176
|
+
7
|
177
|
+
1
|
178
|
+
60
|
179
|
+
7
|
180
|
+
2
|
181
|
+
60
|
182
|
+
32
|
183
|
+
2
|
184
|
+
32
|
185
|
+
2
|
186
|
+
32
|
187
|
+
3
|
188
|
+
53
|
189
|
+
3
|
190
|
+
47
|
191
|
+
4
|
192
|
+
0
|
193
|
+
11
|
194
|
+
I
|
195
|
+
6
|
196
|
+
I
|
197
|
+
0
|
198
|
+
I
|
199
|
+
-1
|
200
|
+
I
|
201
|
+
-1
|
202
|
+
n
|
203
|
+
p
|
204
|
+
5
|
205
|
+
s
|
206
|
+
1
|
207
|
+
A
|
208
|
+
s
|
209
|
+
1
|
210
|
+
B
|
211
|
+
s
|
212
|
+
1
|
213
|
+
C
|
214
|
+
M
|
215
|
+
1
|
216
|
+
n
|
217
|
+
n
|
218
|
+
x
|
219
|
+
9
|
220
|
+
__block__
|
221
|
+
i
|
222
|
+
30
|
223
|
+
55
|
224
|
+
33
|
225
|
+
34
|
226
|
+
17
|
227
|
+
0
|
228
|
+
14
|
229
|
+
34
|
230
|
+
17
|
231
|
+
1
|
232
|
+
14
|
233
|
+
14
|
234
|
+
5
|
235
|
+
18
|
236
|
+
0
|
237
|
+
45
|
238
|
+
0
|
239
|
+
44
|
240
|
+
45
|
241
|
+
1
|
242
|
+
7
|
243
|
+
2
|
244
|
+
60
|
245
|
+
59
|
246
|
+
53
|
247
|
+
3
|
248
|
+
44
|
249
|
+
47
|
250
|
+
4
|
251
|
+
1
|
252
|
+
11
|
253
|
+
I
|
254
|
+
6
|
255
|
+
I
|
256
|
+
2
|
257
|
+
I
|
258
|
+
2
|
259
|
+
I
|
260
|
+
2
|
261
|
+
n
|
262
|
+
p
|
263
|
+
5
|
264
|
+
x
|
265
|
+
7
|
266
|
+
inspect
|
267
|
+
x
|
268
|
+
4
|
269
|
+
to_s
|
270
|
+
s
|
271
|
+
3
|
272
|
+
on
|
273
|
+
M
|
274
|
+
1
|
275
|
+
n
|
276
|
+
n
|
277
|
+
x
|
278
|
+
9
|
279
|
+
__block__
|
280
|
+
i
|
281
|
+
28
|
282
|
+
5
|
283
|
+
53
|
284
|
+
0
|
285
|
+
44
|
286
|
+
47
|
287
|
+
1
|
288
|
+
0
|
289
|
+
14
|
290
|
+
5
|
291
|
+
19
|
292
|
+
1
|
293
|
+
1
|
294
|
+
45
|
295
|
+
2
|
296
|
+
44
|
297
|
+
45
|
298
|
+
3
|
299
|
+
7
|
300
|
+
4
|
301
|
+
60
|
302
|
+
59
|
303
|
+
53
|
304
|
+
5
|
305
|
+
44
|
306
|
+
47
|
307
|
+
6
|
308
|
+
1
|
309
|
+
11
|
310
|
+
I
|
311
|
+
4
|
312
|
+
I
|
313
|
+
0
|
314
|
+
I
|
315
|
+
-1
|
316
|
+
I
|
317
|
+
-1
|
318
|
+
n
|
319
|
+
p
|
320
|
+
7
|
321
|
+
M
|
322
|
+
1
|
323
|
+
n
|
324
|
+
n
|
325
|
+
x
|
326
|
+
9
|
327
|
+
__block__
|
328
|
+
i
|
329
|
+
14
|
330
|
+
42
|
331
|
+
0
|
332
|
+
1
|
333
|
+
19
|
334
|
+
2
|
335
|
+
0
|
336
|
+
33
|
337
|
+
1
|
338
|
+
48
|
339
|
+
2
|
340
|
+
0
|
341
|
+
35
|
342
|
+
3
|
343
|
+
11
|
344
|
+
I
|
345
|
+
4
|
346
|
+
I
|
347
|
+
0
|
348
|
+
I
|
349
|
+
-1
|
350
|
+
I
|
351
|
+
-1
|
352
|
+
n
|
353
|
+
p
|
354
|
+
4
|
355
|
+
x
|
356
|
+
7
|
357
|
+
Hamster
|
358
|
+
n
|
359
|
+
x
|
360
|
+
4
|
361
|
+
list
|
362
|
+
x
|
363
|
+
5
|
364
|
+
@list
|
365
|
+
p
|
366
|
+
5
|
367
|
+
I
|
368
|
+
0
|
369
|
+
I
|
370
|
+
11
|
371
|
+
I
|
372
|
+
0
|
373
|
+
I
|
374
|
+
12
|
375
|
+
I
|
376
|
+
e
|
377
|
+
x
|
378
|
+
32
|
379
|
+
./spec/hamster/list/tail_spec.rb
|
380
|
+
p
|
381
|
+
0
|
382
|
+
x
|
383
|
+
6
|
384
|
+
before
|
385
|
+
x
|
386
|
+
7
|
387
|
+
inspect
|
388
|
+
x
|
389
|
+
4
|
390
|
+
to_s
|
391
|
+
s
|
392
|
+
8
|
393
|
+
returns
|
394
|
+
M
|
395
|
+
1
|
396
|
+
n
|
397
|
+
n
|
398
|
+
x
|
399
|
+
9
|
400
|
+
__block__
|
401
|
+
i
|
402
|
+
20
|
403
|
+
36
|
404
|
+
0
|
405
|
+
45
|
406
|
+
1
|
407
|
+
45
|
408
|
+
2
|
409
|
+
42
|
410
|
+
3
|
411
|
+
4
|
412
|
+
19
|
413
|
+
2
|
414
|
+
1
|
415
|
+
33
|
416
|
+
1
|
417
|
+
48
|
418
|
+
5
|
419
|
+
0
|
420
|
+
79
|
421
|
+
6
|
422
|
+
11
|
423
|
+
I
|
424
|
+
5
|
425
|
+
I
|
426
|
+
0
|
427
|
+
I
|
428
|
+
-1
|
429
|
+
I
|
430
|
+
-1
|
431
|
+
n
|
432
|
+
p
|
433
|
+
7
|
434
|
+
x
|
435
|
+
5
|
436
|
+
@list
|
437
|
+
x
|
438
|
+
4
|
439
|
+
tail
|
440
|
+
x
|
441
|
+
6
|
442
|
+
should
|
443
|
+
x
|
444
|
+
7
|
445
|
+
Hamster
|
446
|
+
n
|
447
|
+
x
|
448
|
+
4
|
449
|
+
list
|
450
|
+
x
|
451
|
+
2
|
452
|
+
==
|
453
|
+
p
|
454
|
+
5
|
455
|
+
I
|
456
|
+
0
|
457
|
+
I
|
458
|
+
15
|
459
|
+
I
|
460
|
+
0
|
461
|
+
I
|
462
|
+
16
|
463
|
+
I
|
464
|
+
14
|
465
|
+
x
|
466
|
+
32
|
467
|
+
./spec/hamster/list/tail_spec.rb
|
468
|
+
p
|
469
|
+
0
|
470
|
+
x
|
471
|
+
2
|
472
|
+
it
|
473
|
+
p
|
474
|
+
7
|
475
|
+
I
|
476
|
+
0
|
477
|
+
I
|
478
|
+
f
|
479
|
+
I
|
480
|
+
0
|
481
|
+
I
|
482
|
+
11
|
483
|
+
I
|
484
|
+
8
|
485
|
+
I
|
486
|
+
15
|
487
|
+
I
|
488
|
+
1c
|
489
|
+
x
|
490
|
+
32
|
491
|
+
./spec/hamster/list/tail_spec.rb
|
492
|
+
p
|
493
|
+
0
|
494
|
+
x
|
495
|
+
8
|
496
|
+
describe
|
497
|
+
p
|
498
|
+
7
|
499
|
+
I
|
500
|
+
0
|
501
|
+
I
|
502
|
+
a
|
503
|
+
I
|
504
|
+
3
|
505
|
+
I
|
506
|
+
d
|
507
|
+
I
|
508
|
+
b
|
509
|
+
I
|
510
|
+
f
|
511
|
+
I
|
512
|
+
1e
|
513
|
+
x
|
514
|
+
32
|
515
|
+
./spec/hamster/list/tail_spec.rb
|
516
|
+
p
|
517
|
+
2
|
518
|
+
x
|
519
|
+
6
|
520
|
+
values
|
521
|
+
x
|
522
|
+
8
|
523
|
+
expected
|
524
|
+
x
|
525
|
+
4
|
526
|
+
each
|
527
|
+
p
|
528
|
+
9
|
529
|
+
I
|
530
|
+
0
|
531
|
+
I
|
532
|
+
7
|
533
|
+
I
|
534
|
+
0
|
535
|
+
I
|
536
|
+
a
|
537
|
+
I
|
538
|
+
6
|
539
|
+
I
|
540
|
+
b
|
541
|
+
I
|
542
|
+
f
|
543
|
+
I
|
544
|
+
c
|
545
|
+
I
|
546
|
+
2c
|
547
|
+
x
|
548
|
+
32
|
549
|
+
./spec/hamster/list/tail_spec.rb
|
550
|
+
p
|
551
|
+
0
|
552
|
+
x
|
553
|
+
8
|
554
|
+
describe
|
555
|
+
p
|
556
|
+
5
|
557
|
+
I
|
558
|
+
0
|
559
|
+
I
|
560
|
+
5
|
561
|
+
I
|
562
|
+
0
|
563
|
+
I
|
564
|
+
7
|
565
|
+
I
|
566
|
+
b
|
567
|
+
x
|
568
|
+
32
|
569
|
+
./spec/hamster/list/tail_spec.rb
|
570
|
+
p
|
571
|
+
0
|
572
|
+
x
|
573
|
+
8
|
574
|
+
describe
|
575
|
+
p
|
576
|
+
7
|
577
|
+
I
|
578
|
+
0
|
579
|
+
I
|
580
|
+
1
|
581
|
+
I
|
582
|
+
1a
|
583
|
+
I
|
584
|
+
3
|
585
|
+
I
|
586
|
+
23
|
587
|
+
I
|
588
|
+
5
|
589
|
+
I
|
590
|
+
32
|
591
|
+
x
|
592
|
+
32
|
593
|
+
./spec/hamster/list/tail_spec.rb
|
594
|
+
p
|
595
|
+
0
|