rbs 2.5.0 → 2.7.0.pre.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/comments.yml +1 -1
- data/.github/workflows/ruby.yml +3 -3
- data/.gitignore +2 -0
- data/.rubocop.yml +5 -0
- data/CHANGELOG.md +104 -0
- data/Gemfile.lock +11 -10
- data/Rakefile +2 -39
- data/Steepfile +7 -2
- data/core/basic_object.rbs +2 -2
- data/core/constants.rbs +1 -1
- data/core/env.rbs +1 -1323
- data/core/fiber.rbs +304 -14
- data/core/float.rbs +2 -0
- data/core/global_variables.rbs +1 -1
- data/core/hash.rbs +3 -3
- data/core/io.rbs +95 -1
- data/core/kernel.rbs +3 -3
- data/core/module.rbs +1 -1
- data/core/random.rbs +5 -220
- data/core/rational.rbs +3 -3
- data/core/rbs/unnamed/argf.rbs +965 -0
- data/core/rbs/unnamed/env_class.rbs +1325 -0
- data/core/rbs/unnamed/random.rbs +270 -0
- data/core/regexp.rbs +2 -3
- data/core/string_io.rbs +1 -1
- data/core/warning.rbs +1 -1
- data/docs/CONTRIBUTING.md +2 -2
- data/ext/rbs_extension/lexer.c +1343 -1353
- data/ext/rbs_extension/lexer.re +2 -2
- data/ext/rbs_extension/parser.c +36 -10
- data/ext/rbs_extension/rbs_extension.h +1 -1
- data/ext/rbs_extension/ruby_objs.c +4 -2
- data/ext/rbs_extension/ruby_objs.h +2 -2
- data/ext/rbs_extension/unescape.c +17 -10
- data/lib/rbs/ancestor_graph.rb +2 -0
- data/lib/rbs/annotate/annotations.rb +2 -0
- data/lib/rbs/annotate/formatter.rb +4 -2
- data/lib/rbs/annotate/rdoc_annotator.rb +2 -0
- data/lib/rbs/annotate/rdoc_source.rb +2 -0
- data/lib/rbs/annotate.rb +2 -0
- data/lib/rbs/ast/annotation.rb +2 -0
- data/lib/rbs/ast/comment.rb +2 -0
- data/lib/rbs/ast/declarations.rb +2 -0
- data/lib/rbs/ast/members.rb +8 -3
- data/lib/rbs/ast/type_param.rb +3 -1
- data/lib/rbs/buffer.rb +2 -0
- data/lib/rbs/builtin_names.rb +2 -0
- data/lib/rbs/cli.rb +41 -2
- data/lib/rbs/collection/cleaner.rb +2 -0
- data/lib/rbs/collection/config/lockfile_generator.rb +8 -3
- data/lib/rbs/collection/config.rb +2 -0
- data/lib/rbs/collection/installer.rb +2 -0
- data/lib/rbs/collection/sources/base.rb +14 -0
- data/lib/rbs/collection/sources/git.rb +3 -0
- data/lib/rbs/collection/sources/rubygems.rb +3 -0
- data/lib/rbs/collection/sources/stdlib.rb +12 -7
- data/lib/rbs/collection/sources.rb +3 -0
- data/lib/rbs/collection.rb +2 -0
- data/lib/rbs/constant.rb +2 -0
- data/lib/rbs/constant_table.rb +5 -3
- data/lib/rbs/definition.rb +13 -1
- data/lib/rbs/definition_builder/ancestor_builder.rb +2 -0
- data/lib/rbs/definition_builder/method_builder.rb +2 -0
- data/lib/rbs/definition_builder.rb +75 -13
- data/lib/rbs/environment.rb +2 -0
- data/lib/rbs/environment_loader.rb +25 -5
- data/lib/rbs/environment_walker.rb +2 -0
- data/lib/rbs/errors.rb +3 -1
- data/lib/rbs/factory.rb +4 -0
- data/lib/rbs/location_aux.rb +3 -1
- data/lib/rbs/locator.rb +2 -0
- data/lib/rbs/method_type.rb +7 -5
- data/lib/rbs/namespace.rb +9 -5
- data/lib/rbs/parser_aux.rb +2 -0
- data/lib/rbs/parser_compat/lexer_error.rb +2 -0
- data/lib/rbs/parser_compat/located_value.rb +2 -0
- data/lib/rbs/parser_compat/semantics_error.rb +2 -0
- data/lib/rbs/parser_compat/syntax_error.rb +2 -0
- data/lib/rbs/prototype/helpers.rb +14 -13
- data/lib/rbs/prototype/rb.rb +107 -56
- data/lib/rbs/prototype/rbi.rb +73 -33
- data/lib/rbs/prototype/runtime.rb +17 -7
- data/lib/rbs/repository.rb +4 -4
- data/lib/rbs/resolver/constant_resolver.rb +2 -0
- data/lib/rbs/resolver/type_name_resolver.rb +2 -0
- data/lib/rbs/sorter.rb +168 -0
- data/lib/rbs/substitution.rb +2 -0
- data/lib/rbs/test/errors.rb +2 -0
- data/lib/rbs/test/hook.rb +2 -0
- data/lib/rbs/test/observer.rb +2 -0
- data/lib/rbs/test/setup.rb +2 -0
- data/lib/rbs/test/setup_helper.rb +8 -1
- data/lib/rbs/test/spy.rb +2 -0
- data/lib/rbs/test/tester.rb +2 -0
- data/lib/rbs/test/type_check.rb +2 -0
- data/lib/rbs/test.rb +2 -0
- data/lib/rbs/type_alias_dependency.rb +2 -0
- data/lib/rbs/type_alias_regularity.rb +2 -0
- data/lib/rbs/type_name.rb +2 -0
- data/lib/rbs/type_name_resolver.rb +4 -2
- data/lib/rbs/types.rb +68 -18
- data/lib/rbs/validator.rb +2 -0
- data/lib/rbs/variance_calculator.rb +2 -0
- data/lib/rbs/vendorer.rb +2 -0
- data/lib/rbs/version.rb +3 -1
- data/lib/rbs/writer.rb +3 -1
- data/lib/rbs.rb +4 -2
- data/lib/rdoc/discover.rb +20 -0
- data/lib/rdoc_plugin/parser.rb +163 -0
- data/schema/members.json +4 -1
- data/schema/methodType.json +7 -1
- data/schema/types.json +13 -1
- data/sig/ancestor_builder.rbs +66 -7
- data/sig/annotation.rbs +7 -6
- data/sig/builtin_names.rbs +2 -0
- data/sig/cli.rbs +8 -0
- data/sig/collection/config.rbs +16 -4
- data/sig/collection/installer.rbs +2 -0
- data/sig/collection/sources.rbs +23 -4
- data/sig/definition.rbs +8 -0
- data/sig/definition_builder.rbs +64 -7
- data/sig/environment.rbs +4 -0
- data/sig/environment_loader.rbs +4 -2
- data/sig/factory.rbs +5 -0
- data/sig/location.rbs +8 -4
- data/sig/manifest.yaml +1 -0
- data/sig/members.rbs +1 -1
- data/sig/method_builder.rbs +10 -0
- data/sig/namespace.rbs +54 -31
- data/sig/prototype/helpers.rbs +23 -0
- data/sig/prototype/rb.rbs +88 -0
- data/sig/prototype/rbi.rbs +73 -0
- data/sig/rbs.rbs +8 -6
- data/sig/rdoc/rbs.rbs +63 -0
- data/sig/shims/abstract_syntax_tree.rbs +25 -0
- data/sig/shims/enumerable.rbs +5 -0
- data/sig/shims/pp.rbs +3 -0
- data/sig/shims/ripper.rbs +8 -0
- data/sig/{polyfill.rbs → shims.rbs} +1 -31
- data/sig/sorter.rbs +23 -0
- data/sig/types.rbs +14 -2
- data/sig/vendorer.rbs +32 -25
- data/stdlib/bigdecimal/0/big_decimal.rbs +250 -0
- data/stdlib/cgi/0/manifest.yaml +2 -0
- data/stdlib/date/0/time.rbs +26 -0
- data/stdlib/erb/0/erb.rbs +107 -0
- data/stdlib/etc/0/etc.rbs +745 -0
- data/stdlib/logger/0/logger.rbs +2 -2
- data/stdlib/minitest/0/kernel.rbs +42 -0
- data/stdlib/minitest/0/manifest.yaml +2 -0
- data/stdlib/minitest/0/minitest/abstract_reporter.rbs +49 -0
- data/stdlib/minitest/0/minitest/assertion.rbs +16 -0
- data/stdlib/minitest/0/minitest/assertions.rbs +545 -0
- data/stdlib/minitest/0/minitest/backtrace_filter.rbs +16 -0
- data/stdlib/minitest/0/minitest/bench_spec.rbs +102 -0
- data/stdlib/minitest/0/minitest/benchmark.rbs +258 -0
- data/stdlib/minitest/0/minitest/composite_reporter.rbs +25 -0
- data/stdlib/minitest/0/minitest/expectation.rbs +2 -0
- data/stdlib/minitest/0/minitest/expectations.rbs +21 -0
- data/stdlib/minitest/0/minitest/guard.rbs +64 -0
- data/stdlib/minitest/0/minitest/mock.rbs +60 -0
- data/stdlib/minitest/0/minitest/parallel/executor.rbs +42 -0
- data/stdlib/minitest/0/minitest/parallel/test/class_methods.rbs +6 -0
- data/stdlib/minitest/0/minitest/parallel/test.rbs +3 -0
- data/stdlib/minitest/0/minitest/parallel.rbs +2 -0
- data/stdlib/minitest/0/minitest/pride_io.rbs +54 -0
- data/stdlib/minitest/0/minitest/pride_lol.rbs +17 -0
- data/stdlib/minitest/0/minitest/progress_reporter.rbs +11 -0
- data/stdlib/minitest/0/minitest/reportable.rbs +51 -0
- data/stdlib/minitest/0/minitest/reporter.rbs +5 -0
- data/stdlib/minitest/0/minitest/result.rbs +28 -0
- data/stdlib/minitest/0/minitest/runnable.rbs +131 -0
- data/stdlib/minitest/0/minitest/skip.rbs +6 -0
- data/stdlib/minitest/0/minitest/spec/dsl/instance_methods.rbs +48 -0
- data/stdlib/minitest/0/minitest/spec/dsl.rbs +125 -0
- data/stdlib/minitest/0/minitest/spec.rbs +11 -0
- data/stdlib/minitest/0/minitest/statistics_reporter.rbs +76 -0
- data/stdlib/minitest/0/minitest/summary_reporter.rbs +25 -0
- data/stdlib/minitest/0/minitest/test/lifecycle_hooks.rbs +92 -0
- data/stdlib/minitest/0/minitest/test.rbs +76 -0
- data/stdlib/minitest/0/minitest/unexpected_error.rbs +10 -0
- data/stdlib/minitest/0/minitest/unit/test_case.rbs +3 -0
- data/stdlib/minitest/0/minitest/unit.rbs +5 -0
- data/stdlib/minitest/0/minitest.rbs +966 -0
- data/stdlib/rdoc/0/rdoc.rbs +758 -0
- data/stdlib/rubygems/0/errors.rbs +113 -0
- data/steep/Gemfile.lock +8 -8
- metadata +63 -7
- data/lib/rbs/char_scanner.rb +0 -20
- data/stdlib/fiber/0/fiber.rbs +0 -99
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: aeae92c94238c9c1b417f2efd334c6af1435c94b6f43480f6979b413694936b4
|
4
|
+
data.tar.gz: 8abf8d32d6ce0b2103696436698fe5687bef05a677da6f46a317f83adfe73380
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6bdb78cad95578cf94728625e0d20ca211a1ed8140a728f5f723b2331731733d73bc6d33e0ec4f914782ff1cde52d52079c5625afe008a297c1952b115870075
|
7
|
+
data.tar.gz: 0c56b8f9ce630cc77ec080ca5ad172611005fb2cd6cfcc18ea239dc5a8490aa11f74a0f4bd9d3045a8e71f6920b41d203fb7d228207696ea92d0c74c9069b317
|
data/.github/workflows/ruby.yml
CHANGED
@@ -46,9 +46,9 @@ jobs:
|
|
46
46
|
if: contains(matrix.job, 'lexer')
|
47
47
|
run: |
|
48
48
|
cd /tmp
|
49
|
-
curl -L https://github.com/skvadrik/re2c/archive/refs/tags/
|
50
|
-
tar xf re2c-
|
51
|
-
cd re2c-
|
49
|
+
curl -L https://github.com/skvadrik/re2c/archive/refs/tags/3.0.tar.gz > re2c-3.0.tar.gz
|
50
|
+
tar xf re2c-3.0.tar.gz
|
51
|
+
cd re2c-3.0
|
52
52
|
autoreconf -i -W all
|
53
53
|
./configure
|
54
54
|
make
|
data/.gitignore
CHANGED
data/.rubocop.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,110 @@
|
|
2
2
|
|
3
3
|
## master
|
4
4
|
|
5
|
+
## 2.7.0.pre.1 (2022-09-02)
|
6
|
+
|
7
|
+
See [Release Note 2.7](https://github.com/ruby/rbs/wiki/Release-Note-2.7) for the highlights of this release.
|
8
|
+
|
9
|
+
### Signature updates
|
10
|
+
|
11
|
+
* fiber ([#1071](https://github.com/ruby/rbs/pull/1071))
|
12
|
+
* `BigDecimal` ([#1053](https://github.com/ruby/rbs/pull/1053))
|
13
|
+
* `ERB::Util`, `ERB::DefMethod` ([#1074](https://github.com/ruby/rbs/pull/1074))
|
14
|
+
* `Float::Infinity` ([#1095](https://github.com/ruby/rbs/pull/1095))
|
15
|
+
* `Logger` ([#1046](https://github.com/ruby/rbs/pull/1046))
|
16
|
+
* `IO.pipe`, `IO.foreach` ([#1057](https://github.com/ruby/rbs/pull/1057))
|
17
|
+
* `Module#refine` ([#1064](https://github.com/ruby/rbs/pull/1064))
|
18
|
+
* `Regexp.new` ([#1059](https://github.com/ruby/rbs/pull/1059))
|
19
|
+
* `StringIO#write` ([#1065](https://github.com/ruby/rbs/pull/1065))
|
20
|
+
* `Warning.#warn`, `Kernel.#warn` ([#1056](https://github.com/ruby/rbs/pull/1056))
|
21
|
+
|
22
|
+
### Language updates
|
23
|
+
|
24
|
+
* Type of `self` in blocks/procs ([#1077](https://github.com/ruby/rbs/issues/1077), [#1101](https://github.com/ruby/rbs/pull/1101))
|
25
|
+
|
26
|
+
### Library changes
|
27
|
+
|
28
|
+
* RDoc plugin ([#1048](https://github.com/ruby/rbs/pull/1048))
|
29
|
+
* Dedupe method comments ([#1103](https://github.com/ruby/rbs/pull/1103))
|
30
|
+
* Reduce object allocations for GC ([#1102](https://github.com/ruby/rbs/pull/1102))
|
31
|
+
* Add `frozen_string_literal: true` ([#1100](https://github.com/ruby/rbs/pull/1100))
|
32
|
+
* Load dependencies on `-r` option also ([#1013](https://github.com/ruby/rbs/pull/1013))
|
33
|
+
* Fix DefinitionBuilder for methods aliased from module self constraints ([#1099](https://github.com/ruby/rbs/pull/1099))
|
34
|
+
* Fix RBS type definitions ([#1098](https://github.com/ruby/rbs/pull/1098))
|
35
|
+
* Give aliases of `.new` methods correct type ([#1097](https://github.com/ruby/rbs/pull/1097))
|
36
|
+
* `nil` versions are discouraged and will be deprecated in Rubygems 4 ([#1091](https://github.com/ruby/rbs/pull/1091))
|
37
|
+
* Fixes towards Rubygems 4.0 ([#1090](https://github.com/ruby/rbs/pull/1090))
|
38
|
+
* Remove redundant `add` for `Repository.default` ([#1062](https://github.com/ruby/rbs/pull/1062))
|
39
|
+
* Refactor: Use Repository in stdlib source ([#1063](https://github.com/ruby/rbs/pull/1063))
|
40
|
+
* Move `bin/sort` implementation to under `lib/` ([#1051](https://github.com/ruby/rbs/pull/1051))
|
41
|
+
|
42
|
+
#### rbs prototype
|
43
|
+
|
44
|
+
* Fix some error on `prototype runtime` ([#1055](https://github.com/ruby/rbs/pull/1055))
|
45
|
+
* Skip existing RBS files from batch `prototype` ([#1060](https://github.com/ruby/rbs/pull/1060))
|
46
|
+
|
47
|
+
### Miscellaneous
|
48
|
+
|
49
|
+
* Discard outputs from test code ([#1093](https://github.com/ruby/rbs/pull/1093))
|
50
|
+
* Skip testing visibility methods with Ruby 3.2 ([#1082](https://github.com/ruby/rbs/pull/1082))
|
51
|
+
|
52
|
+
## 2.6.0 (2022-06-22)
|
53
|
+
|
54
|
+
RBS 2.6 ships with `rbs prototype` commands improvements and signature updates.
|
55
|
+
New minitest RBS definitions will help you to type check your tests.
|
56
|
+
|
57
|
+
### Signature updates
|
58
|
+
|
59
|
+
* etc ([\#1006](https://github.com/ruby/rbs/pull/1006))
|
60
|
+
* minitest ([\#1009](https://github.com/ruby/rbs/pull/1009))
|
61
|
+
* date ([\#1033](https://github.com/ruby/rbs/pull/1033))
|
62
|
+
* `ENV`. `ARGF`, `Random::Base` ([\#1041](https://github.com/ruby/rbs/pull/1041))
|
63
|
+
* `Hash#dig` ([\#1011](https://github.com/ruby/rbs/pull/1011))
|
64
|
+
* `Hash#reject` ([\#1016](https://github.com/ruby/rbs/pull/1016))
|
65
|
+
* `Kernel?.fail` ([\#1026](https://github.com/ruby/rbs/pull/1026), [\#1028](https://github.com/ruby/rbs/pull/1028))
|
66
|
+
* `Rational#*` ([\#1012](https://github.com/ruby/rbs/pull/1012))
|
67
|
+
* `Regexp.new` ([\#1040](https://github.com/ruby/rbs/pull/1040))
|
68
|
+
|
69
|
+
### Library changes
|
70
|
+
|
71
|
+
* Add `visibility` columns in {AttrReader,AttrAccessor,AttrWriter}#to_json ([\#1014](https://github.com/ruby/rbs/pull/1014))
|
72
|
+
* Add support for RSpec's verifying doubles in test setup helper ([\#1015](https://github.com/ruby/rbs/pull/1015))
|
73
|
+
* Fix lexer to analyze escape characters ([\#1043](https://github.com/ruby/rbs/pull/1043))
|
74
|
+
|
75
|
+
#### rbs prototype
|
76
|
+
|
77
|
+
* [rb] Support the case where the return value is `self` ([\#1003](https://github.com/ruby/rbs/pull/1003))
|
78
|
+
* [rb] Lean to the optional side ([\#1021](https://github.com/ruby/rbs/pull/1021))
|
79
|
+
* [rb] Fix method commenting ([\#1027](https://github.com/ruby/rbs/pull/1027))
|
80
|
+
* [runtime] Fix decls of output from `Prototype::Runtime` ([\#1030](https://github.com/ruby/rbs/pull/1030))
|
81
|
+
* [runtime] Fix class name resolution of prototype runtime ([\#1032](https://github.com/ruby/rbs/pull/1032))
|
82
|
+
* [rbi] Improve `Prototype::RBI` ([\#1018](https://github.com/ruby/rbs/pull/1018))
|
83
|
+
|
84
|
+
### Miscellaneous
|
85
|
+
|
86
|
+
* Fix typo in `CONTRIBUTING.md` ([\#1004](https://github.com/ruby/rbs/pull/1004))
|
87
|
+
* Use manifest.yaml instead of manually for validate task ([\#1010](https://github.com/ruby/rbs/pull/1010))
|
88
|
+
* Update re2c ([\#1017](https://github.com/ruby/rbs/pull/1017))
|
89
|
+
* Type check `Prototype::RB` ([\#1019](https://github.com/ruby/rbs/pull/1019))
|
90
|
+
* Minor cleanup & fix ([\#1020](https://github.com/ruby/rbs/pull/1020))
|
91
|
+
* Fix type errors ([\#1023](https://github.com/ruby/rbs/pull/1023))
|
92
|
+
* Clarify GHA step name for rake annotate ([\#1024](https://github.com/ruby/rbs/pull/1024))
|
93
|
+
* Silence parser warning ([\#1039](https://github.com/ruby/rbs/pull/1039))
|
94
|
+
* Fix warnings ([\#1035](https://github.com/ruby/rbs/pull/1035))
|
95
|
+
|
96
|
+
## 2.5.1 (2022-06-19)
|
97
|
+
|
98
|
+
This is a maintenance release mainly to fix errors detected in CI of `ruby/ruby`.
|
99
|
+
Nothing changed related to the users of RBS gem.
|
100
|
+
|
101
|
+
### Miscellaneous
|
102
|
+
|
103
|
+
* Skip failing tests on ruby/ruby CI ([\#1036](https://github.com/ruby/rbs/pull/1036))
|
104
|
+
* Fix warnings ([\#1035](https://github.com/ruby/rbs/pull/1035) except changes on `test/tools/sort_test.rb` that is not included in this release)
|
105
|
+
* Fix `Regexp.new` argument ([\#1034](https://github.com/ruby/rbs/pull/1034))
|
106
|
+
* Fix errors with OpenSSL 3 ([\#1029](https://github.com/ruby/rbs/pull/1029))
|
107
|
+
* Fix `OpenSSL::PKey::PKeyError: EVP_PKEY_keygen: bad ffc parameters` with OpenSSL 3 ([\#1005](https://github.com/ruby/rbs/pull/1005))
|
108
|
+
|
5
109
|
## 2.5.0 (2022-05-20)
|
6
110
|
|
7
111
|
This is a minor release with tuple type/record type syntax updates and `rbs prototype` improvements.
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
rbs (2.
|
4
|
+
rbs (2.7.0.pre.1)
|
5
5
|
|
6
6
|
PATH
|
7
7
|
remote: test/assets/test-gem
|
@@ -30,9 +30,9 @@ GEM
|
|
30
30
|
json-schema (3.0.0)
|
31
31
|
addressable (>= 2.8)
|
32
32
|
marcel (1.0.2)
|
33
|
-
minitest (5.
|
33
|
+
minitest (5.16.3)
|
34
34
|
parallel (1.22.1)
|
35
|
-
parser (3.1.2.
|
35
|
+
parser (3.1.2.1)
|
36
36
|
ast (~> 2.4.1)
|
37
37
|
power_assert (2.0.1)
|
38
38
|
prime (0.1.2)
|
@@ -47,7 +47,7 @@ GEM
|
|
47
47
|
rake
|
48
48
|
rdoc (6.4.0)
|
49
49
|
psych (>= 4.0.0)
|
50
|
-
regexp_parser (2.
|
50
|
+
regexp_parser (2.5.0)
|
51
51
|
rexml (3.2.5)
|
52
52
|
rspec (3.11.0)
|
53
53
|
rspec-core (~> 3.11.0)
|
@@ -62,16 +62,17 @@ GEM
|
|
62
62
|
diff-lcs (>= 1.2.0, < 2.0)
|
63
63
|
rspec-support (~> 3.11.0)
|
64
64
|
rspec-support (3.11.0)
|
65
|
-
rubocop (1.
|
65
|
+
rubocop (1.35.1)
|
66
|
+
json (~> 2.3)
|
66
67
|
parallel (~> 1.10)
|
67
|
-
parser (>= 3.1.
|
68
|
+
parser (>= 3.1.2.1)
|
68
69
|
rainbow (>= 2.2.2, < 4.0)
|
69
70
|
regexp_parser (>= 1.8, < 3.0)
|
70
71
|
rexml (>= 3.2.5, < 4.0)
|
71
|
-
rubocop-ast (>= 1.
|
72
|
+
rubocop-ast (>= 1.20.1, < 2.0)
|
72
73
|
ruby-progressbar (~> 1.7)
|
73
74
|
unicode-display_width (>= 1.4.0, < 3.0)
|
74
|
-
rubocop-ast (1.
|
75
|
+
rubocop-ast (1.21.0)
|
75
76
|
parser (>= 3.1.1.0)
|
76
77
|
rubocop-rubycw (0.1.6)
|
77
78
|
rubocop (~> 1.0)
|
@@ -79,13 +80,13 @@ GEM
|
|
79
80
|
rake (>= 0.8.1)
|
80
81
|
ruby-progressbar (1.11.0)
|
81
82
|
singleton (0.1.1)
|
82
|
-
stackprof (0.2.
|
83
|
+
stackprof (0.2.21)
|
83
84
|
stringio (3.0.2)
|
84
85
|
strong_json (2.1.2)
|
85
86
|
tempfile (0.1.2)
|
86
87
|
test-unit (3.5.3)
|
87
88
|
power_assert
|
88
|
-
unicode-display_width (2.
|
89
|
+
unicode-display_width (2.2.0)
|
89
90
|
|
90
91
|
PLATFORMS
|
91
92
|
ruby
|
data/Rakefile
CHANGED
@@ -54,50 +54,13 @@ task :test_doc do
|
|
54
54
|
end
|
55
55
|
|
56
56
|
task :validate => :compile do
|
57
|
+
require 'yaml'
|
58
|
+
|
57
59
|
sh "#{ruby} #{rbs} validate --silent"
|
58
60
|
|
59
61
|
FileList["stdlib/*"].each do |path|
|
60
62
|
lib = [File.basename(path).to_s]
|
61
63
|
|
62
|
-
if lib == ["bigdecimal-math"]
|
63
|
-
lib << "bigdecimal"
|
64
|
-
end
|
65
|
-
|
66
|
-
if lib == ["yaml"]
|
67
|
-
lib << "dbm"
|
68
|
-
lib << "pstore"
|
69
|
-
end
|
70
|
-
|
71
|
-
if lib == ["logger"]
|
72
|
-
lib << "monitor"
|
73
|
-
end
|
74
|
-
|
75
|
-
if lib == ["cgi"]
|
76
|
-
lib << "tempfile"
|
77
|
-
end
|
78
|
-
|
79
|
-
if lib == ["csv"]
|
80
|
-
lib << "forwardable"
|
81
|
-
end
|
82
|
-
|
83
|
-
if lib == ["prime"]
|
84
|
-
lib << "singleton"
|
85
|
-
end
|
86
|
-
|
87
|
-
if lib == ["net-http"]
|
88
|
-
lib << "uri"
|
89
|
-
lib << "timeout"
|
90
|
-
end
|
91
|
-
|
92
|
-
if lib == ["resolv"]
|
93
|
-
lib << "socket"
|
94
|
-
lib << "timeout"
|
95
|
-
end
|
96
|
-
|
97
|
-
if lib == ["openssl"]
|
98
|
-
lib << "socket"
|
99
|
-
end
|
100
|
-
|
101
64
|
sh "#{ruby} #{rbs} #{lib.map {|l| "-r #{l}"}.join(" ")} validate --silent"
|
102
65
|
end
|
103
66
|
end
|
data/Steepfile
CHANGED
@@ -3,12 +3,17 @@ D = Steep::Diagnostic
|
|
3
3
|
target :lib do
|
4
4
|
signature "sig"
|
5
5
|
check "lib"
|
6
|
-
ignore
|
6
|
+
ignore(
|
7
|
+
"lib/rbs/prototype/runtime.rb",
|
8
|
+
"lib/rbs/test",
|
9
|
+
"lib/rbs/test.rb"
|
10
|
+
)
|
7
11
|
|
8
|
-
library "set", "pathname", "json", "logger", "monitor", "tsort", "uri"
|
12
|
+
library "set", "pathname", "json", "logger", "monitor", "tsort", "uri", 'yaml', 'dbm', 'pstore', 'singleton', 'shellwords', 'fileutils', 'find', 'digest'
|
9
13
|
signature "stdlib/strscan/0/"
|
10
14
|
signature "stdlib/rubygems/0/"
|
11
15
|
signature "stdlib/optparse/0/"
|
16
|
+
signature "stdlib/rdoc/0/"
|
12
17
|
|
13
18
|
configure_code_diagnostics do |config|
|
14
19
|
config[D::Ruby::MethodDefinitionMissing] = :hint
|
data/core/basic_object.rbs
CHANGED
@@ -257,7 +257,7 @@ class BasicObject
|
|
257
257
|
# k.instance_eval {|obj| obj == self } #=> true
|
258
258
|
#
|
259
259
|
def instance_eval: (String, ?String filename, ?Integer lineno) -> untyped
|
260
|
-
| [U] () { (self) -> U } -> U
|
260
|
+
| [U] () { (self) [self: self] -> U } -> U
|
261
261
|
|
262
262
|
# <!--
|
263
263
|
# rdoc-file=vm_eval.c
|
@@ -276,7 +276,7 @@ class BasicObject
|
|
276
276
|
# k = KlassWithSecret.new
|
277
277
|
# k.instance_exec(5) {|x| @secret+x } #=> 104
|
278
278
|
#
|
279
|
-
def instance_exec: [U, V] (*V args) { (*V args) -> U } -> U
|
279
|
+
def instance_exec: [U, V] (*V args) { (*V args) [self: self] -> U } -> U
|
280
280
|
|
281
281
|
# <!--
|
282
282
|
# rdoc-file=object.c
|