rbs 3.10.0 → 3.10.1
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 +4 -4
- data/.github/workflows/c-check.yml +1 -1
- data/.github/workflows/comments.yml +3 -3
- data/.github/workflows/ruby.yml +7 -8
- data/CHANGELOG.md +11 -0
- data/core/array.rbs +5 -9
- data/core/comparable.rbs +13 -6
- data/core/complex.rbs +8 -4
- data/core/dir.rbs +2 -2
- data/core/enumerator.rbs +25 -0
- data/core/fiber.rbs +24 -16
- data/core/file.rbs +22 -7
- data/core/float.rbs +15 -11
- data/core/hash.rbs +5 -6
- data/core/integer.rbs +26 -25
- data/core/io/buffer.rbs +3 -3
- data/core/kernel.rbs +4 -0
- data/core/method.rbs +49 -19
- data/core/module.rbs +18 -11
- data/core/numeric.rbs +9 -1
- data/core/pathname.rbs +0 -34
- data/core/proc.rbs +15 -16
- data/core/ractor.rbs +155 -144
- data/core/rational.rbs +19 -10
- data/core/set.rbs +2 -2
- data/core/signal.rbs +24 -14
- data/core/string.rbs +34 -30
- data/core/symbol.rbs +13 -7
- data/core/thread.rbs +3 -4
- data/lib/rbs/collection/config/lockfile_generator.rb +7 -0
- data/lib/rbs/environment_loader.rb +0 -6
- data/lib/rbs/subtractor.rb +3 -1
- data/lib/rbs/version.rb +1 -1
- data/stdlib/cgi/0/core.rbs +11 -1
- data/stdlib/cgi-escape/0/escape.rbs +33 -15
- data/stdlib/pathname/0/pathname.rbs +36 -0
- metadata +3 -2
data/core/set.rbs
CHANGED
|
@@ -299,7 +299,7 @@ class Set[unchecked out A]
|
|
|
299
299
|
# rdoc-file=set.c
|
|
300
300
|
# - add(obj) -> self
|
|
301
301
|
# -->
|
|
302
|
-
# Adds the given object to the set and returns self.
|
|
302
|
+
# Adds the given object to the set and returns self. Use Set#merge to add many
|
|
303
303
|
# elements at once.
|
|
304
304
|
#
|
|
305
305
|
# Set[1, 2].add(3) #=> Set[1, 2, 3]
|
|
@@ -309,7 +309,7 @@ class Set[unchecked out A]
|
|
|
309
309
|
def add: (A) -> self
|
|
310
310
|
|
|
311
311
|
# <!-- rdoc-file=set.c -->
|
|
312
|
-
# Adds the given object to the set and returns self.
|
|
312
|
+
# Adds the given object to the set and returns self. Use Set#merge to add many
|
|
313
313
|
# elements at once.
|
|
314
314
|
#
|
|
315
315
|
# Set[1, 2].add(3) #=> Set[1, 2, 3]
|
data/core/signal.rbs
CHANGED
|
@@ -65,26 +65,36 @@ module Signal
|
|
|
65
65
|
|
|
66
66
|
# <!--
|
|
67
67
|
# rdoc-file=signal.c
|
|
68
|
-
# - Signal.trap(
|
|
69
|
-
# - Signal.trap(
|
|
68
|
+
# - Signal.trap(signal, command) -> obj
|
|
69
|
+
# - Signal.trap(signal) { ... } -> obj
|
|
70
70
|
# -->
|
|
71
|
-
# Specifies the handling of signals.
|
|
72
|
-
#
|
|
73
|
-
#
|
|
74
|
-
#
|
|
75
|
-
#
|
|
76
|
-
#
|
|
77
|
-
#
|
|
78
|
-
# command
|
|
79
|
-
#
|
|
80
|
-
#
|
|
81
|
-
#
|
|
71
|
+
# Specifies the handling of signals. Returns the previous handler for the given
|
|
72
|
+
# signal.
|
|
73
|
+
#
|
|
74
|
+
# Argument `signal` is a signal name (a string or symbol such as `SIGALRM` or
|
|
75
|
+
# `SIGUSR1`) or an integer signal number. When `signal` is a string or symbol,
|
|
76
|
+
# the leading characters `SIG` may be omitted.
|
|
77
|
+
#
|
|
78
|
+
# Argument `command` or block provided specifies code to be run when the signal
|
|
79
|
+
# is raised.
|
|
80
|
+
#
|
|
81
|
+
# Argument `command` may also be a string or symbol with the following special
|
|
82
|
+
# values:
|
|
83
|
+
#
|
|
84
|
+
# * `IGNORE`, `SIG_IGN`: the signal will be ignored.
|
|
85
|
+
# * `DEFAULT`, `SIG_DFL`: Ruby's default handler will be invoked.
|
|
86
|
+
# * `EXIT`: the process will be terminated by the signal.
|
|
87
|
+
# * `SYSTEM_DEFAULT`: the operating system's default handler will be invoked.
|
|
88
|
+
#
|
|
89
|
+
# The special signal name `EXIT` or signal number zero will be invoked just
|
|
90
|
+
# prior to program termination:
|
|
82
91
|
#
|
|
83
92
|
# Signal.trap(0, proc { puts "Terminating: #{$$}" })
|
|
84
93
|
# Signal.trap("CLD") { puts "Child died" }
|
|
85
94
|
# fork && Process.wait
|
|
86
95
|
#
|
|
87
|
-
#
|
|
96
|
+
# Outputs:
|
|
97
|
+
#
|
|
88
98
|
# Terminating: 27461
|
|
89
99
|
# Child died
|
|
90
100
|
# Terminating: 27460
|
data/core/string.rbs
CHANGED
|
@@ -1177,23 +1177,28 @@ class String
|
|
|
1177
1177
|
|
|
1178
1178
|
# <!--
|
|
1179
1179
|
# rdoc-file=string.c
|
|
1180
|
-
# - self <=>
|
|
1180
|
+
# - self <=> other -> -1, 0, 1, or nil
|
|
1181
1181
|
# -->
|
|
1182
|
-
# Compares `self` and `
|
|
1182
|
+
# Compares `self` and `other`, evaluating their *contents*, not their *lengths*.
|
|
1183
1183
|
#
|
|
1184
|
-
#
|
|
1185
|
-
#
|
|
1186
|
-
# * 1 if `
|
|
1187
|
-
# * `
|
|
1184
|
+
# Returns:
|
|
1185
|
+
#
|
|
1186
|
+
# * `-1`, if `self` is smaller.
|
|
1187
|
+
# * `0`, if the two are equal.
|
|
1188
|
+
# * `1`, if `self` is larger.
|
|
1189
|
+
# * `nil`, if the two are incomparable.
|
|
1188
1190
|
#
|
|
1189
1191
|
# Examples:
|
|
1190
1192
|
#
|
|
1191
|
-
# '
|
|
1192
|
-
# '
|
|
1193
|
-
# '
|
|
1194
|
-
# '
|
|
1195
|
-
# '
|
|
1196
|
-
# '
|
|
1193
|
+
# 'a' <=> 'b' # => -1
|
|
1194
|
+
# 'a' <=> 'ab' # => -1
|
|
1195
|
+
# 'a' <=> 'a' # => 0
|
|
1196
|
+
# 'b' <=> 'a' # => 1
|
|
1197
|
+
# 'ab' <=> 'a' # => 1
|
|
1198
|
+
# 'a' <=> :a # => nil
|
|
1199
|
+
#
|
|
1200
|
+
# Class String includes module Comparable, each of whose methods uses String#<=>
|
|
1201
|
+
# for comparison.
|
|
1197
1202
|
#
|
|
1198
1203
|
# Related: see [Comparing](rdoc-ref:String@Comparing).
|
|
1199
1204
|
#
|
|
@@ -1576,9 +1581,9 @@ class String
|
|
|
1576
1581
|
# s['ll'] = 'foo' # => "foo"
|
|
1577
1582
|
# s # => "hefooo"
|
|
1578
1583
|
#
|
|
1579
|
-
# s = '
|
|
1580
|
-
# s['
|
|
1581
|
-
# s # => "
|
|
1584
|
+
# s = 'Привет'
|
|
1585
|
+
# s['ив'] = 'foo' # => "foo"
|
|
1586
|
+
# s # => "Прfooет"
|
|
1582
1587
|
#
|
|
1583
1588
|
# s = 'こんにちは'
|
|
1584
1589
|
# s['んにち'] = 'foo' # => "foo"
|
|
@@ -1817,8 +1822,8 @@ class String
|
|
|
1817
1822
|
# -->
|
|
1818
1823
|
# Returns an array of the bytes in `self`:
|
|
1819
1824
|
#
|
|
1820
|
-
# 'hello'.bytes
|
|
1821
|
-
# '
|
|
1825
|
+
# 'hello'.bytes # => [104, 101, 108, 108, 111]
|
|
1826
|
+
# 'Привет'.bytes # => [208, 159, 209, 128, 208, 184, 208, 178, 208, 181, 209, 130]
|
|
1822
1827
|
# 'こんにちは'.bytes
|
|
1823
1828
|
# # => [227, 129, 147, 227, 130, 147, 227, 129, 171, 227, 129, 161, 227, 129, 175]
|
|
1824
1829
|
#
|
|
@@ -1840,9 +1845,9 @@ class String
|
|
|
1840
1845
|
# s = 'foo'
|
|
1841
1846
|
# s.bytesize # => 3
|
|
1842
1847
|
# s.size # => 3
|
|
1843
|
-
# s = '
|
|
1844
|
-
# s.bytesize # =>
|
|
1845
|
-
# s.size # =>
|
|
1848
|
+
# s = 'Привет'
|
|
1849
|
+
# s.bytesize # => 12
|
|
1850
|
+
# s.size # => 6
|
|
1846
1851
|
# s = 'こんにちは'
|
|
1847
1852
|
# s.bytesize # => 15
|
|
1848
1853
|
# s.size # => 5
|
|
@@ -2108,7 +2113,7 @@ class String
|
|
|
2108
2113
|
# 'hello'.center(20, '-|') # => "-|-|-|-hello-|-|-|-|" # Some padding repeated.
|
|
2109
2114
|
# 'hello'.center(10, 'abcdefg') # => "abhelloabc" # Some padding not used.
|
|
2110
2115
|
# ' hello '.center(13) # => " hello "
|
|
2111
|
-
# '
|
|
2116
|
+
# 'Привет'.center(10) # => " Привет "
|
|
2112
2117
|
# 'こんにちは'.center(10) # => " こんにちは " # Multi-byte characters.
|
|
2113
2118
|
#
|
|
2114
2119
|
# If `size` is less than or equal to the size of `self`, returns an unpadded
|
|
@@ -2129,7 +2134,7 @@ class String
|
|
|
2129
2134
|
# Returns an array of the characters in `self`:
|
|
2130
2135
|
#
|
|
2131
2136
|
# 'hello'.chars # => ["h", "e", "l", "l", "o"]
|
|
2132
|
-
# '
|
|
2137
|
+
# 'Привет'.chars # => ["П", "р", "и", "в", "е", "т"]
|
|
2133
2138
|
# 'こんにちは'.chars # => ["こ", "ん", "に", "ち", "は"]
|
|
2134
2139
|
# ''.chars # => []
|
|
2135
2140
|
#
|
|
@@ -3927,8 +3932,8 @@ class String
|
|
|
3927
3932
|
# `self`, not `self`.
|
|
3928
3933
|
#
|
|
3929
3934
|
# If `pattern` is a Regexp, performs the equivalent of `self.match(pattern)`
|
|
3930
|
-
# (also setting [
|
|
3931
|
-
# variables](rdoc-ref:language/globals.md@
|
|
3935
|
+
# (also setting [matched-data
|
|
3936
|
+
# variables](rdoc-ref:language/globals.md@Matched+Data)):
|
|
3932
3937
|
#
|
|
3933
3938
|
# 'hello'.partition(/h/) # => ["", "h", "ello"]
|
|
3934
3939
|
# 'hello'.partition(/l/) # => ["he", "l", "lo"]
|
|
@@ -3941,8 +3946,8 @@ class String
|
|
|
3941
3946
|
#
|
|
3942
3947
|
# If `pattern` is not a Regexp, converts it to a string (if it is not already
|
|
3943
3948
|
# one), then performs the equivalent of `self.index(pattern)` (and does *not*
|
|
3944
|
-
# set [
|
|
3945
|
-
# variables](rdoc-ref:language/globals.md@
|
|
3949
|
+
# set [matched-data global
|
|
3950
|
+
# variables](rdoc-ref:language/globals.md@Matched+Data)):
|
|
3946
3951
|
#
|
|
3947
3952
|
# 'hello'.partition('h') # => ["", "h", "ello"]
|
|
3948
3953
|
# 'hello'.partition('l') # => ["he", "l", "lo"]
|
|
@@ -4132,8 +4137,8 @@ class String
|
|
|
4132
4137
|
# `self`, not `self`.
|
|
4133
4138
|
#
|
|
4134
4139
|
# If `pattern` is a Regexp, searches for the last matching substring (also
|
|
4135
|
-
# setting [
|
|
4136
|
-
# variables](rdoc-ref:language/globals.md@
|
|
4140
|
+
# setting [matched-data global
|
|
4141
|
+
# variables](rdoc-ref:language/globals.md@Matched+Data)):
|
|
4137
4142
|
#
|
|
4138
4143
|
# 'hello'.rpartition(/l/) # => ["hel", "l", "o"]
|
|
4139
4144
|
# 'hello'.rpartition(/ll/) # => ["he", "ll", "o"]
|
|
@@ -4146,8 +4151,7 @@ class String
|
|
|
4146
4151
|
#
|
|
4147
4152
|
# If `pattern` is not a Regexp, converts it to a string (if it is not already
|
|
4148
4153
|
# one), then searches for the last matching substring (and does *not* set
|
|
4149
|
-
# [
|
|
4150
|
-
# variables](rdoc-ref:language/globals.md@Pattern+Matching)):
|
|
4154
|
+
# [matched-data global variables](rdoc-ref:language/globals.md@Matched+Data)):
|
|
4151
4155
|
#
|
|
4152
4156
|
# 'hello'.rpartition('l') # => ["hel", "l", "o"]
|
|
4153
4157
|
# 'hello'.rpartition('ll') # => ["he", "ll", "o"]
|
data/core/symbol.rbs
CHANGED
|
@@ -130,19 +130,25 @@ class Symbol
|
|
|
130
130
|
|
|
131
131
|
# <!--
|
|
132
132
|
# rdoc-file=string.c
|
|
133
|
-
# -
|
|
133
|
+
# - self <=> other -> -1, 0, 1, or nil
|
|
134
134
|
# -->
|
|
135
|
-
#
|
|
136
|
-
# object.to_s`:
|
|
135
|
+
# Compares `self` and `other`, using String#<=>.
|
|
137
136
|
#
|
|
138
|
-
#
|
|
139
|
-
# :foo <=> :foo # => 0
|
|
140
|
-
# :foo <=> :bar # => 1
|
|
137
|
+
# Returns:
|
|
141
138
|
#
|
|
142
|
-
#
|
|
139
|
+
# * `self.to_s <=> other.to_s`, if `other` is a symbol.
|
|
140
|
+
# * `nil`, otherwise.
|
|
143
141
|
#
|
|
142
|
+
# Examples:
|
|
143
|
+
#
|
|
144
|
+
# :bar <=> :foo # => -1
|
|
145
|
+
# :foo <=> :foo # => 0
|
|
146
|
+
# :foo <=> :bar # => 1
|
|
144
147
|
# :foo <=> 'bar' # => nil
|
|
145
148
|
#
|
|
149
|
+
# Class Symbol includes module Comparable, each of whose methods uses Symbol#<=>
|
|
150
|
+
# for comparison.
|
|
151
|
+
#
|
|
146
152
|
# Related: String#<=>.
|
|
147
153
|
#
|
|
148
154
|
def <=>: (Symbol object) -> (-1 | 0 | 1)
|
data/core/thread.rbs
CHANGED
|
@@ -963,12 +963,11 @@ class Thread < Object
|
|
|
963
963
|
|
|
964
964
|
# <!--
|
|
965
965
|
# rdoc-file=thread.c
|
|
966
|
-
# -
|
|
967
|
-
# -
|
|
968
|
-
# - thr.raise(exception [, string [, array]])
|
|
966
|
+
# - raise(exception, message = exception.to_s, backtrace = nil, cause: $!)
|
|
967
|
+
# - raise(message = nil, cause: $!)
|
|
969
968
|
# -->
|
|
970
969
|
# Raises an exception from the given thread. The caller does not have to be
|
|
971
|
-
# `thr`. See Kernel#raise for more information.
|
|
970
|
+
# `thr`. See Kernel#raise for more information on arguments.
|
|
972
971
|
#
|
|
973
972
|
# Thread.abort_on_exception = true
|
|
974
973
|
# a = Thread.new { sleep(200) }
|
|
@@ -184,6 +184,13 @@ module RBS
|
|
|
184
184
|
lockfile.gems[name] = { name: name, version: "0", source: source }
|
|
185
185
|
end
|
|
186
186
|
return
|
|
187
|
+
when 'set', 'pathname'
|
|
188
|
+
# set and pathname is migrated to core from stdlib.
|
|
189
|
+
RBS.logger.info {
|
|
190
|
+
from = from_gem || "rbs_collection.yaml"
|
|
191
|
+
"`#{name}` is a part of the Ruby core library. The dependency to the library can be safely deleted from #{from}."
|
|
192
|
+
}
|
|
193
|
+
return
|
|
187
194
|
when *ALUMNI_STDLIBS.keys
|
|
188
195
|
version = ALUMNI_STDLIBS.fetch(name)
|
|
189
196
|
if from_gem
|
|
@@ -50,12 +50,6 @@ module RBS
|
|
|
50
50
|
when path
|
|
51
51
|
dirs << path
|
|
52
52
|
when library
|
|
53
|
-
case library
|
|
54
|
-
when 'pathname'
|
|
55
|
-
RBS.logger.warn "`#{library}` has been moved to core library, so it is always loaded. Remove explicit loading `#{library}`"
|
|
56
|
-
return
|
|
57
|
-
end
|
|
58
|
-
|
|
59
53
|
if libs.add?(Library.new(name: library, version: version)) && resolve_dependencies
|
|
60
54
|
resolve_dependencies(library: library, version: version)
|
|
61
55
|
end
|
data/lib/rbs/subtractor.rb
CHANGED
|
@@ -107,7 +107,9 @@ module RBS
|
|
|
107
107
|
each_member(owner).any? do |m|
|
|
108
108
|
case m
|
|
109
109
|
when AST::Members::InstanceVariable
|
|
110
|
-
m.name == name
|
|
110
|
+
m.name == name && kind == :instance
|
|
111
|
+
when AST::Members::ClassInstanceVariable
|
|
112
|
+
m.name == name && kind == :singleton
|
|
111
113
|
when AST::Members::Attribute
|
|
112
114
|
ivar_name = m.ivar_name == false ? nil : m.ivar_name || :"@#{m.name}"
|
|
113
115
|
ivar_name == name && m.kind == kind
|
data/lib/rbs/version.rb
CHANGED
data/stdlib/cgi/0/core.rbs
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# <!-- rdoc-file=lib/cgi/escape.rb -->
|
|
2
|
-
#
|
|
2
|
+
# Since Ruby 4.0, CGI is a small holder for various escaping methods, included
|
|
3
|
+
# from CGI::Escape
|
|
4
|
+
#
|
|
5
|
+
# require 'cgi/escape'
|
|
6
|
+
#
|
|
7
|
+
# CGI.escape("Ruby programming language")
|
|
8
|
+
# #=> "Ruby+programming+language"
|
|
9
|
+
# CGI.escapeURIComponent("Ruby programming language")
|
|
10
|
+
# #=> "Ruby%20programming%20language"
|
|
11
|
+
#
|
|
12
|
+
# See CGI::Escape module for methods list and their description.
|
|
3
13
|
#
|
|
4
14
|
class CGI
|
|
5
15
|
include CGI::Util
|
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# <!-- rdoc-file=lib/cgi/escape.rb -->
|
|
2
|
-
#
|
|
2
|
+
# Since Ruby 4.0, CGI is a small holder for various escaping methods, included
|
|
3
|
+
# from CGI::Escape
|
|
4
|
+
#
|
|
5
|
+
# require 'cgi/escape'
|
|
6
|
+
#
|
|
7
|
+
# CGI.escape("Ruby programming language")
|
|
8
|
+
# #=> "Ruby+programming+language"
|
|
9
|
+
# CGI.escapeURIComponent("Ruby programming language")
|
|
10
|
+
# #=> "Ruby%20programming%20language"
|
|
11
|
+
#
|
|
12
|
+
# See CGI::Escape module for methods list and their description.
|
|
3
13
|
#
|
|
4
14
|
class CGI
|
|
5
15
|
include Escape
|
|
@@ -7,7 +17,7 @@ class CGI
|
|
|
7
17
|
extend Escape
|
|
8
18
|
|
|
9
19
|
# <!-- rdoc-file=lib/cgi/escape.rb -->
|
|
10
|
-
#
|
|
20
|
+
# Web-related escape/unescape functionality.
|
|
11
21
|
#
|
|
12
22
|
module Escape
|
|
13
23
|
# <!--
|
|
@@ -15,7 +25,7 @@ class CGI
|
|
|
15
25
|
# - escape(string)
|
|
16
26
|
# -->
|
|
17
27
|
# URL-encode a string into application/x-www-form-urlencoded. Space characters
|
|
18
|
-
# (
|
|
28
|
+
# (`" "`) are encoded with plus signs (`"+"`)
|
|
19
29
|
# url_encoded_string = CGI.escape("'Stop!' said Fred")
|
|
20
30
|
# # => "%27Stop%21%27+said+Fred"
|
|
21
31
|
#
|
|
@@ -45,7 +55,7 @@ class CGI
|
|
|
45
55
|
# rdoc-file=lib/cgi/escape.rb
|
|
46
56
|
# - escapeHTML(string)
|
|
47
57
|
# -->
|
|
48
|
-
# Escape special characters in HTML, namely '
|
|
58
|
+
# Escape special characters in HTML, namely `'&\"<>`
|
|
49
59
|
# CGI.escapeHTML('Usage: foo "bar" <baz>')
|
|
50
60
|
# # => "Usage: foo "bar" <baz>"
|
|
51
61
|
#
|
|
@@ -55,20 +65,24 @@ class CGI
|
|
|
55
65
|
# rdoc-file=lib/cgi/escape.rb
|
|
56
66
|
# - escapeURIComponent(string)
|
|
57
67
|
# -->
|
|
58
|
-
# URL-encode a string following RFC 3986 Space characters (
|
|
59
|
-
# with (
|
|
68
|
+
# URL-encode a string following RFC 3986 Space characters (`" "`) are encoded
|
|
69
|
+
# with (`"%20"`)
|
|
60
70
|
# url_encoded_string = CGI.escapeURIComponent("'Stop!' said Fred")
|
|
61
71
|
# # => "%27Stop%21%27%20said%20Fred"
|
|
62
72
|
#
|
|
63
73
|
def escapeURIComponent: (string) -> String
|
|
64
74
|
|
|
65
|
-
# <!--
|
|
66
|
-
#
|
|
75
|
+
# <!--
|
|
76
|
+
# rdoc-file=lib/cgi/escape.rb
|
|
77
|
+
# - escape_element(string, *elements)
|
|
78
|
+
# -->
|
|
67
79
|
#
|
|
68
80
|
alias escape_element escapeElement
|
|
69
81
|
|
|
70
|
-
# <!--
|
|
71
|
-
#
|
|
82
|
+
# <!--
|
|
83
|
+
# rdoc-file=lib/cgi/escape.rb
|
|
84
|
+
# - escape_html(string)
|
|
85
|
+
# -->
|
|
72
86
|
#
|
|
73
87
|
alias escape_html escapeHTML
|
|
74
88
|
|
|
@@ -101,7 +115,7 @@ class CGI
|
|
|
101
115
|
# rdoc-file=lib/cgi/escape.rb
|
|
102
116
|
# - unescapeElement(string, *elements)
|
|
103
117
|
# -->
|
|
104
|
-
# Undo escaping such as that done by CGI.escapeElement
|
|
118
|
+
# Undo escaping such as that done by CGI.escapeElement
|
|
105
119
|
#
|
|
106
120
|
# print CGI.unescapeElement(
|
|
107
121
|
# CGI.escapeHTML('<BR><A HREF="url"></A>'), "A", "IMG")
|
|
@@ -133,13 +147,17 @@ class CGI
|
|
|
133
147
|
#
|
|
134
148
|
def unescapeURIComponent: (string) -> String
|
|
135
149
|
|
|
136
|
-
# <!--
|
|
137
|
-
#
|
|
150
|
+
# <!--
|
|
151
|
+
# rdoc-file=lib/cgi/escape.rb
|
|
152
|
+
# - unescape_element(string, *elements)
|
|
153
|
+
# -->
|
|
138
154
|
#
|
|
139
155
|
alias unescape_element unescapeElement
|
|
140
156
|
|
|
141
|
-
# <!--
|
|
142
|
-
#
|
|
157
|
+
# <!--
|
|
158
|
+
# rdoc-file=lib/cgi/escape.rb
|
|
159
|
+
# - unescape_html(string)
|
|
160
|
+
# -->
|
|
143
161
|
#
|
|
144
162
|
alias unescape_html unescapeHTML
|
|
145
163
|
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
%a{annotate:rdoc:skip}
|
|
2
|
+
class Pathname
|
|
3
|
+
# <!--
|
|
4
|
+
# rdoc-file=lib/pathname.rb
|
|
5
|
+
# - find(ignore_error: true) { |pathname| ... }
|
|
6
|
+
# -->
|
|
7
|
+
# Iterates over the directory tree in a depth first manner, yielding a Pathname
|
|
8
|
+
# for each file under "this" directory.
|
|
9
|
+
#
|
|
10
|
+
# Note that you need to require 'pathname' to use this method.
|
|
11
|
+
#
|
|
12
|
+
# Returns an Enumerator if no block is given.
|
|
13
|
+
#
|
|
14
|
+
# Since it is implemented by the standard library module Find, Find.prune can be
|
|
15
|
+
# used to control the traversal.
|
|
16
|
+
#
|
|
17
|
+
# If `self` is `.`, yielded pathnames begin with a filename in the current
|
|
18
|
+
# directory, not `./`.
|
|
19
|
+
#
|
|
20
|
+
# See Find.find
|
|
21
|
+
#
|
|
22
|
+
def find: (?ignore_error: boolish) { (Pathname) -> untyped } -> nil
|
|
23
|
+
| (?ignore_error: boolish) -> Enumerator[Pathname, nil]
|
|
24
|
+
|
|
25
|
+
# <!--
|
|
26
|
+
# rdoc-file=lib/pathname.rb
|
|
27
|
+
# - rmtree(noop: nil, verbose: nil, secure: nil)
|
|
28
|
+
# -->
|
|
29
|
+
# Recursively deletes a directory, including all directories beneath it.
|
|
30
|
+
#
|
|
31
|
+
# Note that you need to require 'pathname' to use this method.
|
|
32
|
+
#
|
|
33
|
+
# See FileUtils.rm_rf
|
|
34
|
+
#
|
|
35
|
+
def rmtree: () -> self
|
|
36
|
+
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rbs
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.10.
|
|
4
|
+
version: 3.10.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Soutaro Matsumoto
|
|
@@ -460,6 +460,7 @@ files:
|
|
|
460
460
|
- stdlib/openssl/0/manifest.yaml
|
|
461
461
|
- stdlib/openssl/0/openssl.rbs
|
|
462
462
|
- stdlib/optparse/0/optparse.rbs
|
|
463
|
+
- stdlib/pathname/0/pathname.rbs
|
|
463
464
|
- stdlib/pp/0/manifest.yaml
|
|
464
465
|
- stdlib/pp/0/pp.rbs
|
|
465
466
|
- stdlib/prettyprint/0/prettyprint.rbs
|
|
@@ -562,7 +563,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
562
563
|
- !ruby/object:Gem::Version
|
|
563
564
|
version: '0'
|
|
564
565
|
requirements: []
|
|
565
|
-
rubygems_version: 4.0.
|
|
566
|
+
rubygems_version: 4.0.3
|
|
566
567
|
specification_version: 4
|
|
567
568
|
summary: Type signature for Ruby.
|
|
568
569
|
test_files: []
|