steep 0.11.1 → 0.12.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (299) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ruby.yml +27 -0
  3. data/.gitmodules +3 -0
  4. data/CHANGELOG.md +5 -0
  5. data/README.md +48 -90
  6. data/Rakefile +10 -6
  7. data/Steepfile +1 -0
  8. data/bin/setup +1 -0
  9. data/bin/smoke_runner.rb +9 -14
  10. data/exe/rbs +3 -0
  11. data/exe/ruby-signature +3 -0
  12. data/exe/steep +1 -0
  13. data/lib/steep.rb +32 -26
  14. data/lib/steep/annotation_parser.rb +167 -0
  15. data/lib/steep/ast/annotation/collection.rb +7 -7
  16. data/lib/steep/ast/types.rb +60 -0
  17. data/lib/steep/ast/types/any.rb +1 -1
  18. data/lib/steep/ast/types/factory.rb +535 -0
  19. data/lib/steep/ast/types/name.rb +3 -3
  20. data/lib/steep/ast/types/var.rb +1 -1
  21. data/lib/steep/cli.rb +56 -240
  22. data/lib/steep/drivers/annotations.rb +36 -19
  23. data/lib/steep/drivers/check.rb +55 -91
  24. data/lib/steep/drivers/init.rb +54 -0
  25. data/lib/steep/drivers/langserver.rb +241 -150
  26. data/lib/steep/drivers/print_project.rb +56 -0
  27. data/lib/steep/drivers/signature_error_printer.rb +25 -0
  28. data/lib/steep/drivers/trace_printer.rb +25 -0
  29. data/lib/steep/drivers/utils/driver_helper.rb +26 -0
  30. data/lib/steep/drivers/validate.rb +18 -38
  31. data/lib/steep/drivers/vendor.rb +46 -0
  32. data/lib/steep/drivers/watch.rb +78 -140
  33. data/lib/steep/errors.rb +22 -13
  34. data/lib/steep/interface/interface.rb +91 -0
  35. data/lib/steep/interface/method.rb +0 -4
  36. data/lib/steep/interface/method_type.rb +362 -2
  37. data/lib/steep/interface/substitution.rb +22 -0
  38. data/lib/steep/project.rb +25 -233
  39. data/lib/steep/project/dsl.rb +132 -0
  40. data/lib/steep/project/file.rb +93 -76
  41. data/lib/steep/project/file_loader.rb +63 -0
  42. data/lib/steep/project/options.rb +7 -0
  43. data/lib/steep/project/target.rb +190 -0
  44. data/lib/steep/signature/errors.rb +25 -77
  45. data/lib/steep/signature/validator.rb +122 -0
  46. data/lib/steep/source.rb +12 -7
  47. data/lib/steep/subtyping/check.rb +357 -633
  48. data/lib/steep/subtyping/constraints.rb +2 -2
  49. data/lib/steep/subtyping/trace.rb +23 -0
  50. data/lib/steep/type_construction.rb +509 -455
  51. data/lib/steep/type_inference/constant_env.rb +16 -24
  52. data/lib/steep/type_inference/type_env.rb +26 -18
  53. data/lib/steep/version.rb +1 -1
  54. data/sample/Steepfile +6 -0
  55. data/sample/lib/conference.rb +12 -0
  56. data/sample/sig/conference.rbs +6 -0
  57. data/smoke/alias/Steepfile +4 -0
  58. data/smoke/alias/a.rb +2 -2
  59. data/smoke/alias/{a.rbi → a.rbs} +1 -1
  60. data/smoke/and/Steepfile +4 -0
  61. data/smoke/array/Steepfile +4 -0
  62. data/smoke/array/a.rb +2 -2
  63. data/smoke/array/b.rb +4 -4
  64. data/smoke/array/c.rb +2 -2
  65. data/smoke/block/Steepfile +5 -0
  66. data/smoke/block/{a.rbi → a.rbs} +1 -1
  67. data/smoke/block/{c.rbi → c.rbs} +0 -0
  68. data/smoke/block/d.rb +6 -6
  69. data/smoke/case/Steepfile +4 -0
  70. data/smoke/case/a.rb +4 -3
  71. data/smoke/class/Steepfile +4 -0
  72. data/smoke/class/a.rb +1 -4
  73. data/smoke/class/a.rbs +24 -0
  74. data/smoke/class/h.rb +6 -2
  75. data/smoke/class/{h.rbi → h.rbs} +1 -2
  76. data/smoke/class/i.rb +1 -2
  77. data/smoke/class/i.rbs +9 -0
  78. data/smoke/const/Steepfile +4 -0
  79. data/smoke/dstr/Steepfile +4 -0
  80. data/smoke/ensure/Steepfile +4 -0
  81. data/smoke/ensure/a.rb +1 -1
  82. data/smoke/enumerator/Steepfile +4 -0
  83. data/smoke/enumerator/a.rb +7 -7
  84. data/smoke/enumerator/b.rb +6 -6
  85. data/smoke/extension/Steepfile +4 -0
  86. data/smoke/extension/{a.rbi → a.rbs} +2 -2
  87. data/smoke/extension/{e.rbi → e.rbs} +2 -2
  88. data/smoke/hash/Steepfile +4 -0
  89. data/smoke/hash/{a.rbi → a.rbs} +0 -0
  90. data/smoke/hash/b.rb +2 -2
  91. data/smoke/hash/c.rb +1 -1
  92. data/smoke/hash/e.rbs +3 -0
  93. data/smoke/hash/f.rb +1 -1
  94. data/smoke/hello/Steepfile +4 -0
  95. data/smoke/hello/hello.rbs +7 -0
  96. data/smoke/if/Steepfile +4 -0
  97. data/smoke/implements/Steepfile +4 -0
  98. data/smoke/implements/a.rbs +6 -0
  99. data/smoke/initialize/Steepfile +4 -0
  100. data/smoke/initialize/a.rbs +3 -0
  101. data/smoke/integer/Steepfile +4 -0
  102. data/smoke/integer/a.rb +5 -3
  103. data/smoke/interface/Steepfile +4 -0
  104. data/smoke/interface/{a.rbi → a.rbs} +0 -0
  105. data/smoke/kwbegin/Steepfile +4 -0
  106. data/smoke/lambda/Steepfile +4 -0
  107. data/smoke/lambda/a.rb +9 -2
  108. data/smoke/literal/Steepfile +4 -0
  109. data/smoke/literal/{literal_methods.rbi → literal_methods.rbs} +0 -0
  110. data/smoke/map/Steepfile +4 -0
  111. data/smoke/map/a.rb +1 -1
  112. data/smoke/method/Steepfile +4 -0
  113. data/smoke/method/{a.rbi → a.rbs} +0 -0
  114. data/smoke/method/b.rb +1 -4
  115. data/smoke/method/d.rb +1 -0
  116. data/smoke/method/d.rbs +3 -0
  117. data/smoke/module/Steepfile +4 -0
  118. data/smoke/module/a.rb +1 -1
  119. data/smoke/module/a.rbs +16 -0
  120. data/smoke/module/c.rb +1 -1
  121. data/smoke/regexp/Steepfile +4 -0
  122. data/smoke/regexp/a.rb +2 -2
  123. data/smoke/regexp/b.rb +16 -16
  124. data/smoke/regression/Steepfile +5 -0
  125. data/smoke/regression/array.rb +2 -2
  126. data/smoke/regression/hash.rb +2 -2
  127. data/smoke/regression/poly_new.rb +2 -0
  128. data/smoke/regression/poly_new.rbs +4 -0
  129. data/smoke/regression/set_divide.rb +2 -2
  130. data/smoke/rescue/Steepfile +4 -0
  131. data/smoke/rescue/a.rb +1 -1
  132. data/smoke/self/Steepfile +4 -0
  133. data/smoke/self/a.rbs +4 -0
  134. data/smoke/skip/Steepfile +4 -0
  135. data/smoke/stdout/Steepfile +4 -0
  136. data/smoke/stdout/{a.rbi → a.rbs} +1 -1
  137. data/smoke/super/Steepfile +4 -0
  138. data/smoke/super/a.rbs +10 -0
  139. data/smoke/type_case/Steepfile +4 -0
  140. data/smoke/type_case/a.rb +1 -1
  141. data/smoke/yield/Steepfile +4 -0
  142. data/smoke/yield/a.rb +2 -2
  143. data/steep.gemspec +14 -7
  144. data/vendor/ruby-signature/.github/workflows/ruby.yml +27 -0
  145. data/vendor/ruby-signature/.gitignore +12 -0
  146. data/vendor/ruby-signature/.rubocop.yml +15 -0
  147. data/vendor/ruby-signature/BSDL +22 -0
  148. data/vendor/ruby-signature/COPYING +56 -0
  149. data/vendor/ruby-signature/Gemfile +6 -0
  150. data/vendor/ruby-signature/README.md +93 -0
  151. data/vendor/ruby-signature/Rakefile +66 -0
  152. data/vendor/ruby-signature/bin/annotate-with-rdoc +156 -0
  153. data/vendor/ruby-signature/bin/console +14 -0
  154. data/vendor/ruby-signature/bin/query-rdoc +103 -0
  155. data/vendor/ruby-signature/bin/setup +10 -0
  156. data/vendor/ruby-signature/bin/sort +88 -0
  157. data/vendor/ruby-signature/bin/test_runner.rb +17 -0
  158. data/vendor/ruby-signature/docs/CONTRIBUTING.md +97 -0
  159. data/vendor/ruby-signature/docs/sigs.md +148 -0
  160. data/vendor/ruby-signature/docs/stdlib.md +152 -0
  161. data/vendor/ruby-signature/docs/syntax.md +528 -0
  162. data/vendor/ruby-signature/exe/rbs +3 -0
  163. data/vendor/ruby-signature/exe/ruby-signature +7 -0
  164. data/vendor/ruby-signature/lib/ruby/signature.rb +64 -0
  165. data/vendor/ruby-signature/lib/ruby/signature/ast/annotation.rb +29 -0
  166. data/vendor/ruby-signature/lib/ruby/signature/ast/comment.rb +29 -0
  167. data/vendor/ruby-signature/lib/ruby/signature/ast/declarations.rb +391 -0
  168. data/vendor/ruby-signature/lib/ruby/signature/ast/members.rb +364 -0
  169. data/vendor/ruby-signature/lib/ruby/signature/buffer.rb +52 -0
  170. data/vendor/ruby-signature/lib/ruby/signature/builtin_names.rb +54 -0
  171. data/vendor/ruby-signature/lib/ruby/signature/cli.rb +534 -0
  172. data/vendor/ruby-signature/lib/ruby/signature/constant.rb +28 -0
  173. data/vendor/ruby-signature/lib/ruby/signature/constant_table.rb +152 -0
  174. data/vendor/ruby-signature/lib/ruby/signature/definition.rb +172 -0
  175. data/vendor/ruby-signature/lib/ruby/signature/definition_builder.rb +921 -0
  176. data/vendor/ruby-signature/lib/ruby/signature/environment.rb +283 -0
  177. data/vendor/ruby-signature/lib/ruby/signature/environment_loader.rb +138 -0
  178. data/vendor/ruby-signature/lib/ruby/signature/environment_walker.rb +126 -0
  179. data/vendor/ruby-signature/lib/ruby/signature/errors.rb +189 -0
  180. data/vendor/ruby-signature/lib/ruby/signature/location.rb +104 -0
  181. data/vendor/ruby-signature/lib/ruby/signature/method_type.rb +125 -0
  182. data/vendor/ruby-signature/lib/ruby/signature/namespace.rb +93 -0
  183. data/vendor/ruby-signature/lib/ruby/signature/parser.y +1343 -0
  184. data/vendor/ruby-signature/lib/ruby/signature/prototype/rb.rb +441 -0
  185. data/vendor/ruby-signature/lib/ruby/signature/prototype/rbi.rb +579 -0
  186. data/vendor/ruby-signature/lib/ruby/signature/prototype/runtime.rb +383 -0
  187. data/vendor/ruby-signature/lib/ruby/signature/substitution.rb +48 -0
  188. data/vendor/ruby-signature/lib/ruby/signature/test.rb +28 -0
  189. data/vendor/ruby-signature/lib/ruby/signature/test/errors.rb +63 -0
  190. data/vendor/ruby-signature/lib/ruby/signature/test/hook.rb +290 -0
  191. data/vendor/ruby-signature/lib/ruby/signature/test/setup.rb +58 -0
  192. data/vendor/ruby-signature/lib/ruby/signature/test/spy.rb +324 -0
  193. data/vendor/ruby-signature/lib/ruby/signature/test/test_helper.rb +185 -0
  194. data/vendor/ruby-signature/lib/ruby/signature/test/type_check.rb +256 -0
  195. data/vendor/ruby-signature/lib/ruby/signature/type_name.rb +72 -0
  196. data/vendor/ruby-signature/lib/ruby/signature/types.rb +932 -0
  197. data/vendor/ruby-signature/lib/ruby/signature/variance_calculator.rb +140 -0
  198. data/vendor/ruby-signature/lib/ruby/signature/vendorer.rb +49 -0
  199. data/vendor/ruby-signature/lib/ruby/signature/version.rb +5 -0
  200. data/vendor/ruby-signature/lib/ruby/signature/writer.rb +271 -0
  201. data/vendor/ruby-signature/ruby-signature.gemspec +45 -0
  202. data/vendor/ruby-signature/stdlib/abbrev/abbrev.rbs +3 -0
  203. data/vendor/ruby-signature/stdlib/base64/base64.rbs +15 -0
  204. data/vendor/ruby-signature/stdlib/builtin/array.rbs +1997 -0
  205. data/vendor/ruby-signature/stdlib/builtin/basic_object.rbs +280 -0
  206. data/vendor/ruby-signature/stdlib/builtin/binding.rbs +177 -0
  207. data/vendor/ruby-signature/stdlib/builtin/builtin.rbs +35 -0
  208. data/vendor/ruby-signature/stdlib/builtin/class.rbs +145 -0
  209. data/vendor/ruby-signature/stdlib/builtin/comparable.rbs +116 -0
  210. data/vendor/ruby-signature/stdlib/builtin/complex.rbs +400 -0
  211. data/vendor/ruby-signature/stdlib/builtin/constants.rbs +37 -0
  212. data/vendor/ruby-signature/stdlib/builtin/data.rbs +5 -0
  213. data/vendor/ruby-signature/stdlib/builtin/deprecated.rbs +2 -0
  214. data/vendor/ruby-signature/stdlib/builtin/dir.rbs +419 -0
  215. data/vendor/ruby-signature/stdlib/builtin/encoding.rbs +606 -0
  216. data/vendor/ruby-signature/stdlib/builtin/enumerable.rbs +404 -0
  217. data/vendor/ruby-signature/stdlib/builtin/enumerator.rbs +260 -0
  218. data/vendor/ruby-signature/stdlib/builtin/errno.rbs +781 -0
  219. data/vendor/ruby-signature/stdlib/builtin/errors.rbs +582 -0
  220. data/vendor/ruby-signature/stdlib/builtin/exception.rbs +193 -0
  221. data/vendor/ruby-signature/stdlib/builtin/false_class.rbs +40 -0
  222. data/vendor/ruby-signature/stdlib/builtin/fiber.rbs +68 -0
  223. data/vendor/ruby-signature/stdlib/builtin/fiber_error.rbs +12 -0
  224. data/vendor/ruby-signature/stdlib/builtin/file.rbs +476 -0
  225. data/vendor/ruby-signature/stdlib/builtin/file_test.rbs +59 -0
  226. data/vendor/ruby-signature/stdlib/builtin/float.rbs +696 -0
  227. data/vendor/ruby-signature/stdlib/builtin/gc.rbs +121 -0
  228. data/vendor/ruby-signature/stdlib/builtin/hash.rbs +1029 -0
  229. data/vendor/ruby-signature/stdlib/builtin/integer.rbs +710 -0
  230. data/vendor/ruby-signature/stdlib/builtin/io.rbs +683 -0
  231. data/vendor/ruby-signature/stdlib/builtin/kernel.rbs +574 -0
  232. data/vendor/ruby-signature/stdlib/builtin/marshal.rbs +135 -0
  233. data/vendor/ruby-signature/stdlib/builtin/match_data.rbs +141 -0
  234. data/vendor/ruby-signature/stdlib/builtin/math.rbs +66 -0
  235. data/vendor/ruby-signature/stdlib/builtin/method.rbs +182 -0
  236. data/vendor/ruby-signature/stdlib/builtin/module.rbs +248 -0
  237. data/vendor/ruby-signature/stdlib/builtin/nil_class.rbs +82 -0
  238. data/vendor/ruby-signature/stdlib/builtin/numeric.rbs +409 -0
  239. data/vendor/ruby-signature/stdlib/builtin/object.rbs +824 -0
  240. data/vendor/ruby-signature/stdlib/builtin/proc.rbs +426 -0
  241. data/vendor/ruby-signature/stdlib/builtin/process.rbs +354 -0
  242. data/vendor/ruby-signature/stdlib/builtin/random.rbs +93 -0
  243. data/vendor/ruby-signature/stdlib/builtin/range.rbs +226 -0
  244. data/vendor/ruby-signature/stdlib/builtin/rational.rbs +424 -0
  245. data/vendor/ruby-signature/stdlib/builtin/rb_config.rbs +10 -0
  246. data/vendor/ruby-signature/stdlib/builtin/regexp.rbs +131 -0
  247. data/vendor/ruby-signature/stdlib/builtin/ruby_vm.rbs +14 -0
  248. data/vendor/ruby-signature/stdlib/builtin/signal.rbs +55 -0
  249. data/vendor/ruby-signature/stdlib/builtin/string.rbs +770 -0
  250. data/vendor/ruby-signature/stdlib/builtin/string_io.rbs +13 -0
  251. data/vendor/ruby-signature/stdlib/builtin/struct.rbs +40 -0
  252. data/vendor/ruby-signature/stdlib/builtin/symbol.rbs +230 -0
  253. data/vendor/ruby-signature/stdlib/builtin/thread.rbs +1112 -0
  254. data/vendor/ruby-signature/stdlib/builtin/thread_group.rbs +23 -0
  255. data/vendor/ruby-signature/stdlib/builtin/time.rbs +739 -0
  256. data/vendor/ruby-signature/stdlib/builtin/trace_point.rbs +91 -0
  257. data/vendor/ruby-signature/stdlib/builtin/true_class.rbs +46 -0
  258. data/vendor/ruby-signature/stdlib/builtin/unbound_method.rbs +159 -0
  259. data/vendor/ruby-signature/stdlib/builtin/warning.rbs +17 -0
  260. data/vendor/ruby-signature/stdlib/erb/erb.rbs +18 -0
  261. data/vendor/ruby-signature/stdlib/find/find.rbs +44 -0
  262. data/vendor/ruby-signature/stdlib/pathname/pathname.rbs +21 -0
  263. data/vendor/ruby-signature/stdlib/prime/integer-extension.rbs +23 -0
  264. data/vendor/ruby-signature/stdlib/prime/prime.rbs +188 -0
  265. data/vendor/ruby-signature/stdlib/securerandom/securerandom.rbs +9 -0
  266. data/vendor/ruby-signature/stdlib/set/set.rbs +77 -0
  267. data/vendor/ruby-signature/stdlib/tmpdir/tmpdir.rbs +53 -0
  268. metadata +244 -54
  269. data/.travis.yml +0 -7
  270. data/lib/steep/ast/signature/alias.rb +0 -19
  271. data/lib/steep/ast/signature/class.rb +0 -33
  272. data/lib/steep/ast/signature/const.rb +0 -17
  273. data/lib/steep/ast/signature/env.rb +0 -138
  274. data/lib/steep/ast/signature/extension.rb +0 -21
  275. data/lib/steep/ast/signature/gvar.rb +0 -17
  276. data/lib/steep/ast/signature/interface.rb +0 -31
  277. data/lib/steep/ast/signature/members.rb +0 -115
  278. data/lib/steep/ast/signature/module.rb +0 -21
  279. data/lib/steep/drivers/print_interface.rb +0 -94
  280. data/lib/steep/drivers/scaffold.rb +0 -321
  281. data/lib/steep/drivers/utils/each_signature.rb +0 -31
  282. data/lib/steep/interface/abstract.rb +0 -68
  283. data/lib/steep/interface/builder.rb +0 -637
  284. data/lib/steep/interface/instantiated.rb +0 -163
  285. data/lib/steep/interface/ivar_chain.rb +0 -26
  286. data/lib/steep/parser.y +0 -1278
  287. data/lib/steep/project/listener.rb +0 -53
  288. data/smoke/class/a.rbi +0 -24
  289. data/smoke/class/d.rb +0 -9
  290. data/smoke/class/e.rb +0 -12
  291. data/smoke/class/i.rbi +0 -9
  292. data/smoke/hash/e.rbi +0 -3
  293. data/smoke/hello/hello.rbi +0 -7
  294. data/smoke/implements/a.rbi +0 -6
  295. data/smoke/initialize/a.rbi +0 -3
  296. data/smoke/module/a.rbi +0 -16
  297. data/smoke/self/a.rbi +0 -4
  298. data/smoke/super/a.rbi +0 -10
  299. data/stdlib/builtin.rbi +0 -787
@@ -0,0 +1,193 @@
1
+ # Descendants of class [Exception](Exception) are used
2
+ # to communicate between
3
+ # [Kernel\#raise](https://ruby-doc.org/core-2.6.3/Kernel.html#method-i-raise)
4
+ # and `rescue` statements in `begin ... end` blocks.
5
+ # [Exception](Exception) objects carry information
6
+ # about the exception – its type (the exception’s class name), an optional
7
+ # descriptive string, and optional traceback information.
8
+ # [Exception](Exception) subclasses may add additional
9
+ # information like
10
+ # [NameError\#name](https://ruby-doc.org/core-2.6.3/NameError.html#method-i-name)
11
+ # .
12
+ #
13
+ # Programs may make subclasses of
14
+ # [Exception](Exception), typically of
15
+ # [StandardError](https://ruby-doc.org/core-2.6.3/StandardError.html) or
16
+ # [RuntimeError](https://ruby-doc.org/core-2.6.3/RuntimeError.html), to
17
+ # provide custom classes and add additional information. See the subclass
18
+ # list below for defaults for `raise` and `rescue` .
19
+ #
20
+ # When an exception has been raised but not yet handled (in `rescue`,
21
+ # `ensure`, `at_exit` and `END` blocks) the global variable `$!` will
22
+ # contain the current exception and `$@` contains the current exception’s
23
+ # backtrace.
24
+ #
25
+ # It is recommended that a library should have one subclass of
26
+ # [StandardError](https://ruby-doc.org/core-2.6.3/StandardError.html) or
27
+ # [RuntimeError](https://ruby-doc.org/core-2.6.3/RuntimeError.html) and
28
+ # have specific exception types inherit from it. This allows the user to
29
+ # rescue a generic exception type to catch all exceptions the library may
30
+ # raise even if future versions of the library add new exception
31
+ # subclasses.
32
+ #
33
+ # For example:
34
+ #
35
+ # ```ruby
36
+ # class MyLibrary
37
+ # class Error < RuntimeError
38
+ # end
39
+ #
40
+ # class WidgetError < Error
41
+ # end
42
+ #
43
+ # class FrobError < Error
44
+ # end
45
+ #
46
+ # end
47
+ # ```
48
+ #
49
+ # To handle both WidgetError and FrobError the library user can rescue
50
+ # MyLibrary::Error.
51
+ #
52
+ # The built-in subclasses of [Exception](Exception)
53
+ # are:
54
+ #
55
+ # - [NoMemoryError](https://ruby-doc.org/core-2.6.3/NoMemoryError.html)
56
+ #
57
+ # - [ScriptError](https://ruby-doc.org/core-2.6.3/ScriptError.html)
58
+ #
59
+ # - [LoadError](https://ruby-doc.org/core-2.6.3/LoadError.html)
60
+ #
61
+ # - [NotImplementedError](https://ruby-doc.org/core-2.6.3/NotImplementedError.html)
62
+ #
63
+ # - [SyntaxError](https://ruby-doc.org/core-2.6.3/SyntaxError.html)
64
+ #
65
+ # - [SecurityError](https://ruby-doc.org/core-2.6.3/SecurityError.html)
66
+ #
67
+ # - [SignalException](https://ruby-doc.org/core-2.6.3/SignalException.html)
68
+ #
69
+ # - [Interrupt](https://ruby-doc.org/core-2.6.3/Interrupt.html)
70
+ #
71
+ # - [StandardError](https://ruby-doc.org/core-2.6.3/StandardError.html)
72
+ # -- default for `rescue`
73
+ #
74
+ # - [ArgumentError](https://ruby-doc.org/core-2.6.3/ArgumentError.html)
75
+ #
76
+ # - [UncaughtThrowError](https://ruby-doc.org/core-2.6.3/UncaughtThrowError.html)
77
+ #
78
+ # - [EncodingError](https://ruby-doc.org/core-2.6.3/EncodingError.html)
79
+ #
80
+ # - [FiberError](https://ruby-doc.org/core-2.6.3/FiberError.html)
81
+ #
82
+ # - [IOError](https://ruby-doc.org/core-2.6.3/IOError.html)
83
+ #
84
+ # - [EOFError](https://ruby-doc.org/core-2.6.3/EOFError.html)
85
+ #
86
+ # - [IndexError](https://ruby-doc.org/core-2.6.3/IndexError.html)
87
+ #
88
+ # - [KeyError](https://ruby-doc.org/core-2.6.3/KeyError.html)
89
+ #
90
+ # - [StopIteration](https://ruby-doc.org/core-2.6.3/StopIteration.html)
91
+ #
92
+ # - [LocalJumpError](https://ruby-doc.org/core-2.6.3/LocalJumpError.html)
93
+ #
94
+ # - [NameError](https://ruby-doc.org/core-2.6.3/NameError.html)
95
+ #
96
+ # - [NoMethodError](https://ruby-doc.org/core-2.6.3/NoMethodError.html)
97
+ #
98
+ # - [RangeError](https://ruby-doc.org/core-2.6.3/RangeError.html)
99
+ #
100
+ # - [FloatDomainError](https://ruby-doc.org/core-2.6.3/FloatDomainError.html)
101
+ #
102
+ # - [RegexpError](https://ruby-doc.org/core-2.6.3/RegexpError.html)
103
+ #
104
+ # - [RuntimeError](https://ruby-doc.org/core-2.6.3/RuntimeError.html)
105
+ # -- default for `raise`
106
+ #
107
+ # - [FrozenError](https://ruby-doc.org/core-2.6.3/FrozenError.html)
108
+ #
109
+ # - [SystemCallError](https://ruby-doc.org/core-2.6.3/SystemCallError.html)
110
+ #
111
+ # - Errno::\*
112
+ #
113
+ # - [ThreadError](https://ruby-doc.org/core-2.6.3/ThreadError.html)
114
+ #
115
+ # - [TypeError](https://ruby-doc.org/core-2.6.3/TypeError.html)
116
+ #
117
+ # - [ZeroDivisionError](https://ruby-doc.org/core-2.6.3/ZeroDivisionError.html)
118
+ #
119
+ # - [SystemExit](https://ruby-doc.org/core-2.6.3/SystemExit.html)
120
+ #
121
+ # - [SystemStackError](https://ruby-doc.org/core-2.6.3/SystemStackError.html)
122
+ #
123
+ # - fatal – impossible to rescue
124
+ class Exception < Object
125
+ def self.to_tty?: () -> bool
126
+
127
+ def self.exception: (?String msg) -> self
128
+
129
+ def ==: (untyped arg0) -> bool
130
+
131
+ # Returns any backtrace associated with the exception. The backtrace is an
132
+ # array of strings, each containing either “filename:lineNo: in \`method”‘
133
+ # or “filename:lineNo.”
134
+ #
135
+ # ```ruby
136
+ # def a
137
+ # raise "boom"
138
+ # end
139
+ #
140
+ # def b
141
+ # a()
142
+ # end
143
+ #
144
+ # begin
145
+ # b()
146
+ # rescue => detail
147
+ # print detail.backtrace.join("\n")
148
+ # end
149
+ # ```
150
+ #
151
+ # *produces:*
152
+ #
153
+ # prog.rb:2:in `a'
154
+ # prog.rb:6:in `b'
155
+ # prog.rb:10
156
+ def backtrace: () -> ::Array[String]?
157
+
158
+ # Returns any backtrace associated with the exception. This method is
159
+ # similar to
160
+ # [\#backtrace](Exception.downloaded.ruby_doc#method-i-backtrace), but
161
+ # the backtrace is an array of
162
+ # [Thread::Backtrace::Location](https://ruby-doc.org/core-2.6.3/Thread/Backtrace/Location.html)
163
+ # .
164
+ #
165
+ # Now, this method is not affected by
166
+ # [\#set\_backtrace](Exception.downloaded.ruby_doc#method-i-set_backtrace)
167
+ # .
168
+ def backtrace_locations: () -> ::Array[Thread::Backtrace::Location]?
169
+
170
+ # Returns the previous exception ($\!) at the time this exception was
171
+ # raised. This is useful for wrapping exceptions and retaining the
172
+ # original exception information.
173
+ def cause: () -> Exception?
174
+
175
+ def exception: (?String arg0) -> Exception
176
+
177
+ def initialize: (?String arg0) -> void
178
+
179
+ # Return this exception’s class name and message.
180
+ def inspect: () -> String
181
+
182
+ # Returns the result of invoking `exception.to_s` . Normally this returns
183
+ # the exception’s message or name.
184
+ def message: () -> String
185
+
186
+ def set_backtrace: (String | ::Array[String] arg0) -> ::Array[String]
187
+
188
+ # Returns exception’s message (or the name of the exception if no message
189
+ # is set).
190
+ def to_s: () -> String
191
+
192
+ def full_message: (?highlight: bool, ?order: :top | :bottom) -> String
193
+ end
@@ -0,0 +1,40 @@
1
+ # The global value `false` is the only instance of class FalseClass and
2
+ # represents a logically false value in boolean expressions. The class provides
3
+ # operators allowing `false` to participate correctly in logical expressions.
4
+ #
5
+ class FalseClass
6
+ public
7
+
8
+ def !: () -> bool
9
+
10
+ # And---Returns `false`. *obj* is always evaluated as it is the argument to a
11
+ # method call---there is no short-circuit evaluation in this case.
12
+ #
13
+ def &: (untyped obj) -> bool
14
+
15
+ # Case Equality -- For class Object, effectively the same as calling `#==`, but
16
+ # typically overridden by descendants to provide meaningful semantics in `case`
17
+ # statements.
18
+ #
19
+ def ===: (false) -> true
20
+ | (untyped obj) -> bool
21
+
22
+ # Exclusive Or---If *obj* is `nil` or `false`, returns `false`; otherwise,
23
+ # returns `true`.
24
+ #
25
+ def ^: (nil) -> false
26
+ | (false) -> false
27
+ | (untyped obj) -> bool
28
+
29
+ alias inspect to_s
30
+
31
+ # The string representation of `false` is "false".
32
+ #
33
+ def to_s: () -> "false"
34
+
35
+ # Or---Returns `false` if *obj* is `nil` or `false`; `true` otherwise.
36
+ #
37
+ def |: (nil) -> false
38
+ | (false) -> false
39
+ | (untyped obj) -> bool
40
+ end
@@ -0,0 +1,68 @@
1
+ # Fibers are primitives for implementing light weight cooperative
2
+ # concurrency in Ruby. Basically they are a means of creating code blocks
3
+ # that can be paused and resumed, much like threads. The main difference
4
+ # is that they are never preempted and that the scheduling must be done by
5
+ # the programmer and not the VM.
6
+ #
7
+ # As opposed to other stackless light weight concurrency models, each
8
+ # fiber comes with a stack. This enables the fiber to be paused from
9
+ # deeply nested function calls within the fiber block. See the ruby(1)
10
+ # manpage to configure the size of the fiber stack(s).
11
+ #
12
+ # When a fiber is created it will not run automatically. Rather it must be
13
+ # explicitly asked to run using the `Fiber#resume` method. The code
14
+ # running inside the fiber can give up control by calling `Fiber.yield` in
15
+ # which case it yields control back to caller (the caller of the
16
+ # `Fiber#resume` ).
17
+ #
18
+ # Upon yielding or termination the [Fiber](Fiber)
19
+ # returns the value of the last executed expression
20
+ #
21
+ # For instance:
22
+ #
23
+ # ```ruby
24
+ # fiber = Fiber.new do
25
+ # Fiber.yield 1
26
+ # 2
27
+ # end
28
+ #
29
+ # puts fiber.resume
30
+ # puts fiber.resume
31
+ # puts fiber.resume
32
+ # ```
33
+ #
34
+ # *produces*
35
+ #
36
+ # 1
37
+ # 2
38
+ # FiberError: dead fiber called
39
+ #
40
+ # The `Fiber#resume` method accepts an arbitrary number of parameters, if
41
+ # it is the first call to `resume` then they will be passed as block
42
+ # arguments. Otherwise they will be the return value of the call to
43
+ # `Fiber.yield`
44
+ #
45
+ # Example:
46
+ #
47
+ # ```ruby
48
+ # fiber = Fiber.new do |first|
49
+ # second = Fiber.yield first + 2
50
+ # end
51
+ #
52
+ # puts fiber.resume 10
53
+ # puts fiber.resume 14
54
+ # puts fiber.resume 18
55
+ # ```
56
+ #
57
+ # *produces*
58
+ #
59
+ # 12
60
+ # 14
61
+ # FiberError: dead fiber called
62
+ class Fiber < Object
63
+ def self.yield: (*untyped args) -> untyped
64
+
65
+ def initialize: () { () -> void } -> Fiber
66
+
67
+ def resume: (*untyped args) -> untyped
68
+ end
@@ -0,0 +1,12 @@
1
+ # Raised when an invalid operation is attempted on a
2
+ # [Fiber](https://ruby-doc.org/core-2.6.3/Fiber.html), in particular when
3
+ # attempting to call/resume a dead fiber, attempting to yield from the
4
+ # root fiber, or calling a fiber across threads.
5
+ #
6
+ # ```ruby
7
+ # fiber = Fiber.new{}
8
+ # fiber.resume #=> nil
9
+ # fiber.resume #=> FiberError: dead fiber called
10
+ # ```
11
+ class FiberError < StandardError
12
+ end
@@ -0,0 +1,476 @@
1
+ # A `File` is an abstraction of any file object accessible by the program
2
+ # and is closely associated with class `IO` . `File` includes the methods
3
+ # of module `FileTest` as class methods, allowing you to write (for
4
+ # example) `File.exist?("foo")` .
5
+ #
6
+ # In the description of [File](File) methods,
7
+ # *permission bits* are a platform-specific set of bits that indicate
8
+ # permissions of a file. On Unix-based systems, permissions are viewed as
9
+ # a set of three octets, for the owner, the group, and the rest of the
10
+ # world. For each of these entities, permissions may be set to read,
11
+ # write, or execute the file:
12
+ #
13
+ # The permission bits `0644` (in octal) would thus be interpreted as
14
+ # read/write for owner, and read-only for group and other. Higher-order
15
+ # bits may also be used to indicate the type of file (plain, directory,
16
+ # pipe, socket, and so on) and various other special features. If the
17
+ # permissions are for a directory, the meaning of the execute bit changes;
18
+ # when set the directory can be searched.
19
+ #
20
+ # On non-Posix operating systems, there may be only the ability to make a
21
+ # file read-only or read-write. In this case, the remaining permission
22
+ # bits will be synthesized to resemble typical values. For instance, on
23
+ # Windows NT the default permission bits are `0644`, which means
24
+ # read/write for owner, read-only for all others. The only change that can
25
+ # be made is to make the file read-only, which is reported as `0444` .
26
+ #
27
+ # Various constants for the methods in [File](File)
28
+ # can be found in
29
+ # [File::Constants](https://ruby-doc.org/core-2.6.3/File/Constants.html).
30
+ class File < IO
31
+ def self.absolute_path: (String file, ?String dir) -> String
32
+
33
+ def self.atime: (untyped file) -> Time
34
+
35
+ def self.basename: (String file, ?String suffix) -> String
36
+
37
+ def self.binread: (String arg0) -> String
38
+ | (String arg0, ?Integer arg1) -> String
39
+ | (String arg0, ?Integer arg1, ?Integer arg2) -> String
40
+
41
+ def self.birthtime: (untyped file) -> Time
42
+
43
+ def self.blockdev?: (String | IO file) -> bool
44
+
45
+ def self.chardev?: (String | IO file) -> bool
46
+
47
+ def self.chmod: (Integer mode, *String files) -> Integer
48
+
49
+ def self.chown: (Integer owner, Integer group, *String files) -> Integer
50
+
51
+ def self.ctime: (untyped file) -> Time
52
+
53
+ def self.delete: (*String files) -> Integer
54
+
55
+ def self.directory?: (String | IO file) -> bool
56
+
57
+ def self.dirname: (String file) -> String
58
+
59
+ def self.executable?: (String file) -> bool
60
+
61
+ def self.executable_real?: (String file) -> bool
62
+
63
+ def self.exist?: (untyped file) -> bool
64
+
65
+ def self.expand_path: (untyped file, ?untyped dir) -> String
66
+
67
+ def self.extname: (String path) -> String
68
+
69
+ def self.file?: (String | IO file) -> bool
70
+
71
+ def self.fnmatch: (String pattern, String path, ?Integer flags) -> bool
72
+
73
+ def self.`ftype`: (String file) -> String
74
+
75
+ def self.grpowned?: (String | IO file) -> bool
76
+
77
+ def self.identical?: (String | IO file_1, String | IO file_2) -> bool
78
+
79
+ def self.join: (*untyped arg0) -> String
80
+
81
+ def self.lchmod: (Integer mode, *String files) -> Integer
82
+
83
+ def self.lchown: (Integer owner, Integer group, *String files) -> Integer
84
+
85
+ def self.link: (String old, String new) -> Integer
86
+
87
+ def self.lstat: (String file) -> File::Stat
88
+
89
+ def self.mtime: (untyped file) -> Time
90
+
91
+ def self.owned?: (String file) -> bool
92
+
93
+ def self.path: (String path) -> String
94
+
95
+ def self.pipe?: (String file) -> bool
96
+
97
+ def self.readable?: (String file) -> bool
98
+
99
+ def self.readable_real?: (String file) -> bool
100
+
101
+ def self.readlink: (String link) -> String
102
+
103
+ def self.realdirpath: (String pathname, ?String dir) -> String
104
+
105
+ def self.realpath: (String pathname, ?String dir) -> String
106
+
107
+ def self.rename: (String old, String new) -> Integer
108
+
109
+ def self.setgid?: (String file) -> bool
110
+
111
+ def self.setuid?: (String file) -> bool
112
+
113
+ def self.size: (String | IO file) -> Integer
114
+
115
+ def self.size?: (String | IO file) -> Integer?
116
+
117
+ def self.socket?: (String | IO file) -> bool
118
+
119
+ def self.split: (String file) -> [ String, String ]
120
+
121
+ def self.stat: (untyped file) -> File::Stat
122
+
123
+ def self.sticky?: (String file) -> bool
124
+
125
+ def self.symlink: (String old, String new) -> Integer
126
+
127
+ def self.symlink?: (String file) -> bool
128
+
129
+ def self.truncate: (String file, Integer arg0) -> Integer
130
+
131
+ def self.umask: (?Integer arg0) -> Integer
132
+
133
+ def self.utime: (Time atime, Time mtime, *String files) -> Integer
134
+
135
+ def self.world_readable?: (String | IO file) -> Integer?
136
+
137
+ def self.world_writable?: (String | IO file) -> Integer?
138
+
139
+ def self.writable?: (String file) -> Integer?
140
+
141
+ def self.writable_real?: (String file) -> Integer?
142
+
143
+ def self.zero?: (String | IO file) -> Integer?
144
+
145
+ # Returns the last access time (a `Time` object) for *file* , or epoch if
146
+ # *file* has not been accessed.
147
+ #
148
+ # ```ruby
149
+ # File.new("testfile").atime #=> Wed Dec 31 18:00:00 CST 1969
150
+ # ```
151
+ def atime: () -> Time
152
+
153
+ # Returns the birth time for *file* .
154
+ #
155
+ # ```ruby
156
+ # File.new("testfile").birthtime #=> Wed Apr 09 08:53:14 CDT 2003
157
+ # ```
158
+ #
159
+ # If the platform doesn’t have birthtime, raises
160
+ # [NotImplementedError](https://ruby-doc.org/core-2.6.3/NotImplementedError.html)
161
+ # .
162
+ def birthtime: () -> Time
163
+
164
+ def chmod: (Integer mode) -> Integer
165
+
166
+ def chown: (Integer owner, Integer group) -> Integer
167
+
168
+ # Returns the change time for *file* (that is, the time directory
169
+ # information about the file was changed, not the file itself).
170
+ #
171
+ # Note that on Windows (NTFS), returns creation time (birth time).
172
+ #
173
+ # ```ruby
174
+ # File.new("testfile").ctime #=> Wed Apr 09 08:53:14 CDT 2003
175
+ # ```
176
+ def ctime: () -> Time
177
+
178
+ def flock: (Integer arg0) -> (Integer | TrueClass | FalseClass)
179
+
180
+ def initialize: (String file, ?String mode, ?String perm, ?Integer opt) -> void
181
+
182
+ # Same as `IO#stat`, but does not follow the last symbolic link. Instead,
183
+ # reports on the link itself.
184
+ #
185
+ # ```ruby
186
+ # File.symlink("testfile", "link2test") #=> 0
187
+ # File.stat("testfile").size #=> 66
188
+ # f = File.new("link2test")
189
+ # f.lstat.size #=> 8
190
+ # f.stat.size #=> 66
191
+ # ```
192
+ def lstat: () -> File::Stat
193
+
194
+ # Returns the modification time for *file* .
195
+ #
196
+ # ```ruby
197
+ # File.new("testfile").mtime #=> Wed Apr 09 08:53:14 CDT 2003
198
+ # ```
199
+ def mtime: () -> Time
200
+
201
+ # Returns the pathname used to create *file* as a string. Does not
202
+ # normalize the name.
203
+ #
204
+ # The pathname may not point to the file corresponding to *file* . For
205
+ # instance, the pathname becomes void when the file has been moved or
206
+ # deleted.
207
+ #
208
+ # This method raises `IOError` for a *file* created using
209
+ # `File::Constants::TMPFILE` because they don’t have a pathname.
210
+ #
211
+ # ```ruby
212
+ # File.new("testfile").path #=> "testfile"
213
+ # File.new("/tmp/../tmp/xxx", "w").path #=> "/tmp/../tmp/xxx"
214
+ # ```
215
+ def path: () -> String
216
+
217
+ # Returns the size of *file* in bytes.
218
+ #
219
+ # ```ruby
220
+ # File.new("testfile").size #=> 66
221
+ # ```
222
+ def size: () -> Integer
223
+
224
+ def truncate: (Integer arg0) -> Integer
225
+
226
+ def self.fnmatch?: (String pattern, String path, ?Integer flags) -> bool
227
+
228
+ def self.unlink: (*String files) -> Integer
229
+
230
+ # Returns the pathname used to create *file* as a string. Does not
231
+ # normalize the name.
232
+ #
233
+ # The pathname may not point to the file corresponding to *file* . For
234
+ # instance, the pathname becomes void when the file has been moved or
235
+ # deleted.
236
+ #
237
+ # This method raises `IOError` for a *file* created using
238
+ # `File::Constants::TMPFILE` because they don’t have a pathname.
239
+ #
240
+ # ```ruby
241
+ # File.new("testfile").path #=> "testfile"
242
+ # File.new("/tmp/../tmp/xxx", "w").path #=> "/tmp/../tmp/xxx"
243
+ # ```
244
+ def to_path: () -> String
245
+ end
246
+
247
+ File::ALT_SEPARATOR: NilClass
248
+
249
+ File::APPEND: Integer
250
+
251
+ File::BINARY: Integer
252
+
253
+ File::CREAT: Integer
254
+
255
+ File::DIRECT: Integer
256
+
257
+ File::DSYNC: Integer
258
+
259
+ File::EXCL: Integer
260
+
261
+ File::FNM_CASEFOLD: Integer
262
+
263
+ File::FNM_DOTMATCH: Integer
264
+
265
+ File::FNM_EXTGLOB: Integer
266
+
267
+ File::FNM_NOESCAPE: Integer
268
+
269
+ File::FNM_PATHNAME: Integer
270
+
271
+ File::FNM_SHORTNAME: Integer
272
+
273
+ File::FNM_SYSCASE: Integer
274
+
275
+ File::LOCK_EX: Integer
276
+
277
+ File::LOCK_NB: Integer
278
+
279
+ File::LOCK_SH: Integer
280
+
281
+ File::LOCK_UN: Integer
282
+
283
+ File::NOATIME: Integer
284
+
285
+ File::NOCTTY: Integer
286
+
287
+ File::NOFOLLOW: Integer
288
+
289
+ File::NONBLOCK: Integer
290
+
291
+ File::NULL: String
292
+
293
+ File::PATH_SEPARATOR: String
294
+
295
+ File::RDONLY: Integer
296
+
297
+ File::RDWR: Integer
298
+
299
+ File::RSYNC: Integer
300
+
301
+ File::SEEK_CUR: Integer
302
+
303
+ File::SEEK_DATA: Integer
304
+
305
+ File::SEEK_END: Integer
306
+
307
+ File::SEEK_HOLE: Integer
308
+
309
+ File::SEEK_SET: Integer
310
+
311
+ File::SEPARATOR: String
312
+
313
+ File::SHARE_DELETE: Integer
314
+
315
+ File::SYNC: Integer
316
+
317
+ File::TMPFILE: Integer
318
+
319
+ File::TRUNC: Integer
320
+
321
+ File::WRONLY: Integer
322
+
323
+ module File::Constants
324
+ end
325
+
326
+ File::Constants::APPEND: Integer
327
+
328
+ File::Constants::BINARY: Integer
329
+
330
+ File::Constants::CREAT: Integer
331
+
332
+ File::Constants::DIRECT: Integer
333
+
334
+ File::Constants::DSYNC: Integer
335
+
336
+ File::Constants::EXCL: Integer
337
+
338
+ File::Constants::FNM_CASEFOLD: Integer
339
+
340
+ File::Constants::FNM_DOTMATCH: Integer
341
+
342
+ File::Constants::FNM_EXTGLOB: Integer
343
+
344
+ File::Constants::FNM_NOESCAPE: Integer
345
+
346
+ File::Constants::FNM_PATHNAME: Integer
347
+
348
+ File::Constants::FNM_SHORTNAME: Integer
349
+
350
+ File::Constants::FNM_SYSCASE: Integer
351
+
352
+ File::Constants::LOCK_EX: Integer
353
+
354
+ File::Constants::LOCK_NB: Integer
355
+
356
+ File::Constants::LOCK_SH: Integer
357
+
358
+ File::Constants::LOCK_UN: Integer
359
+
360
+ File::Constants::NOATIME: Integer
361
+
362
+ File::Constants::NOCTTY: Integer
363
+
364
+ File::Constants::NOFOLLOW: Integer
365
+
366
+ File::Constants::NONBLOCK: Integer
367
+
368
+ File::Constants::NULL: String
369
+
370
+ File::Constants::RDONLY: Integer
371
+
372
+ File::Constants::RDWR: Integer
373
+
374
+ File::Constants::RSYNC: Integer
375
+
376
+ File::Constants::SHARE_DELETE: Integer
377
+
378
+ File::Constants::SYNC: Integer
379
+
380
+ File::Constants::TMPFILE: Integer
381
+
382
+ File::Constants::TRUNC: Integer
383
+
384
+ File::Constants::WRONLY: Integer
385
+
386
+ class File::Stat < Object
387
+ include Comparable
388
+
389
+ def <=>: (File::Stat other) -> Integer?
390
+
391
+ def atime: () -> Time
392
+
393
+ def birthtime: () -> Time
394
+
395
+ def blksize: () -> Integer?
396
+
397
+ def blockdev?: () -> bool
398
+
399
+ def blocks: () -> Integer?
400
+
401
+ def chardev?: () -> bool
402
+
403
+ def ctime: () -> Time
404
+
405
+ def dev: () -> Integer
406
+
407
+ def dev_major: () -> Integer
408
+
409
+ def dev_minor: () -> Integer
410
+
411
+ def directory?: () -> bool
412
+
413
+ def executable?: () -> bool
414
+
415
+ def executable_real?: () -> bool
416
+
417
+ def file?: () -> bool
418
+
419
+ def `ftype`: () -> String
420
+
421
+ def gid: () -> Integer
422
+
423
+ def grpowned?: () -> bool
424
+
425
+ def initialize: (String file) -> Object
426
+
427
+ def ino: () -> Integer
428
+
429
+ def inspect: () -> String
430
+
431
+ def mode: () -> Integer
432
+
433
+ def mtime: () -> Time
434
+
435
+ def nlink: () -> Integer
436
+
437
+ def owned?: () -> bool
438
+
439
+ def pipe?: () -> bool
440
+
441
+ def rdev: () -> Integer?
442
+
443
+ def rdev_major: () -> Integer
444
+
445
+ def rdev_minor: () -> Integer
446
+
447
+ def read: (?Integer length, ?String outbuf) -> String
448
+
449
+ def readable?: () -> bool
450
+
451
+ def readable_real?: () -> bool
452
+
453
+ def setgid?: () -> bool
454
+
455
+ def setuid?: () -> bool
456
+
457
+ def size: () -> Integer
458
+
459
+ def socket?: () -> bool
460
+
461
+ def sticky?: () -> bool
462
+
463
+ def symlink?: () -> bool
464
+
465
+ def uid: () -> Integer
466
+
467
+ def world_readable?: () -> Integer?
468
+
469
+ def world_writable?: () -> Integer?
470
+
471
+ def writable?: () -> bool
472
+
473
+ def writable_real?: () -> bool
474
+
475
+ def zero?: () -> bool
476
+ end