ruby-lsp 0.0.1 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. checksums.yaml +4 -4
  2. data/.github/dependabot.yml +7 -16
  3. data/.github/pull_request_template.md +15 -0
  4. data/.github/workflows/ci.yml +31 -0
  5. data/.github/workflows/publish_docs.yml +32 -0
  6. data/.gitignore +9 -12
  7. data/.rubocop.yml +20 -2
  8. data/.vscode/settings.json +5 -0
  9. data/CHANGELOG.md +29 -0
  10. data/Gemfile +8 -4
  11. data/Gemfile.lock +76 -14
  12. data/README.md +69 -2
  13. data/Rakefile +5 -0
  14. data/VERSION +1 -1
  15. data/bin/tapioca +29 -0
  16. data/bin/test +7 -1
  17. data/dev.yml +7 -7
  18. data/exe/ruby-lsp +19 -2
  19. data/lib/internal.rb +7 -0
  20. data/lib/ruby-lsp.rb +4 -1
  21. data/lib/ruby_lsp/cli.rb +88 -0
  22. data/lib/ruby_lsp/document.rb +113 -0
  23. data/lib/ruby_lsp/handler.rb +236 -0
  24. data/lib/ruby_lsp/requests/base_request.rb +33 -0
  25. data/lib/ruby_lsp/requests/code_actions.rb +37 -0
  26. data/lib/ruby_lsp/requests/diagnostics.rb +37 -0
  27. data/lib/ruby_lsp/requests/document_highlight.rb +96 -0
  28. data/lib/ruby_lsp/requests/document_symbol.rb +216 -0
  29. data/lib/ruby_lsp/requests/folding_ranges.rb +213 -0
  30. data/lib/ruby_lsp/requests/formatting.rb +52 -0
  31. data/lib/ruby_lsp/requests/rubocop_request.rb +50 -0
  32. data/lib/ruby_lsp/requests/selection_ranges.rb +103 -0
  33. data/lib/ruby_lsp/requests/semantic_highlighting.rb +112 -0
  34. data/lib/ruby_lsp/requests/support/rubocop_diagnostic.rb +88 -0
  35. data/lib/ruby_lsp/requests/support/selection_range.rb +17 -0
  36. data/lib/ruby_lsp/requests/support/semantic_token_encoder.rb +60 -0
  37. data/lib/ruby_lsp/requests/support/syntax_error_diagnostic.rb +27 -0
  38. data/lib/ruby_lsp/requests.rb +24 -0
  39. data/lib/ruby_lsp/store.rb +59 -0
  40. data/rakelib/check_docs.rake +56 -0
  41. data/ruby-lsp.gemspec +5 -1
  42. data/{shipit.yml → shipit.production.yml} +0 -0
  43. data/sorbet/config +4 -0
  44. data/sorbet/rbi/.rubocop.yml +8 -0
  45. data/sorbet/rbi/gems/ansi@1.5.0.rbi +338 -0
  46. data/sorbet/rbi/gems/ast@2.4.2.rbi +522 -0
  47. data/sorbet/rbi/gems/builder@3.2.4.rbi +418 -0
  48. data/sorbet/rbi/gems/coderay@1.1.3.rbi +8 -0
  49. data/sorbet/rbi/gems/debug@1.5.0.rbi +1273 -0
  50. data/sorbet/rbi/gems/diff-lcs@1.5.0.rbi +867 -0
  51. data/sorbet/rbi/gems/io-console@0.5.11.rbi +8 -0
  52. data/sorbet/rbi/gems/irb@1.4.1.rbi +376 -0
  53. data/sorbet/rbi/gems/language_server-protocol@3.16.0.3.rbi +7325 -0
  54. data/sorbet/rbi/gems/method_source@1.0.0.rbi +8 -0
  55. data/sorbet/rbi/gems/minitest-reporters@1.5.0.rbi +612 -0
  56. data/sorbet/rbi/gems/minitest@5.15.0.rbi +994 -0
  57. data/sorbet/rbi/gems/parallel@1.22.1.rbi +163 -0
  58. data/sorbet/rbi/gems/parser@3.1.2.0.rbi +3968 -0
  59. data/sorbet/rbi/gems/prettier_print@0.1.0.rbi +734 -0
  60. data/sorbet/rbi/gems/pry@0.14.1.rbi +8 -0
  61. data/sorbet/rbi/gems/rainbow@3.1.1.rbi +227 -0
  62. data/sorbet/rbi/gems/rake@13.0.6.rbi +1853 -0
  63. data/sorbet/rbi/gems/rbi@0.0.14.rbi +2337 -0
  64. data/sorbet/rbi/gems/regexp_parser@2.5.0.rbi +1854 -0
  65. data/sorbet/rbi/gems/reline@0.3.1.rbi +1274 -0
  66. data/sorbet/rbi/gems/rexml@3.2.5.rbi +3852 -0
  67. data/sorbet/rbi/gems/rubocop-ast@1.18.0.rbi +4180 -0
  68. data/sorbet/rbi/gems/rubocop-minitest@0.20.0.rbi +1369 -0
  69. data/sorbet/rbi/gems/rubocop-rake@0.6.0.rbi +246 -0
  70. data/sorbet/rbi/gems/rubocop-shopify@2.6.0.rbi +8 -0
  71. data/sorbet/rbi/gems/rubocop-sorbet@0.6.8.rbi +652 -0
  72. data/sorbet/rbi/gems/rubocop@1.30.0.rbi +36729 -0
  73. data/sorbet/rbi/gems/ruby-progressbar@1.11.0.rbi +732 -0
  74. data/sorbet/rbi/gems/spoom@1.1.11.rbi +1600 -0
  75. data/sorbet/rbi/gems/syntax_tree@2.7.1.rbi +6777 -0
  76. data/sorbet/rbi/gems/tapioca@0.8.1.rbi +1972 -0
  77. data/sorbet/rbi/gems/thor@1.2.1.rbi +2921 -0
  78. data/sorbet/rbi/gems/unicode-display_width@2.1.0.rbi +27 -0
  79. data/sorbet/rbi/gems/unparser@0.6.5.rbi +2789 -0
  80. data/sorbet/rbi/gems/webrick@1.7.0.rbi +1779 -0
  81. data/sorbet/rbi/gems/yard-sorbet@0.6.1.rbi +289 -0
  82. data/sorbet/rbi/gems/yard@0.9.27.rbi +13048 -0
  83. data/sorbet/rbi/shims/fiddle.rbi +4 -0
  84. data/sorbet/rbi/shims/hash.rbi +6 -0
  85. data/sorbet/rbi/shims/rdoc.rbi +4 -0
  86. data/sorbet/tapioca/config.yml +13 -0
  87. data/sorbet/tapioca/require.rb +7 -0
  88. metadata +119 -9
  89. data/.vscode/launch.json +0 -19
  90. data/bin/package_extension +0 -5
  91. data/bin/style +0 -10
  92. data/lib/ruby/lsp/cli.rb +0 -37
  93. data/lib/ruby/lsp.rb +0 -3
@@ -0,0 +1,1854 @@
1
+ # typed: true
2
+
3
+ # DO NOT EDIT MANUALLY
4
+ # This is an autogenerated file for types exported from the `regexp_parser` gem.
5
+ # Please instead update this file by running `bin/tapioca gem regexp_parser`.
6
+
7
+ module Regexp::Expression; end
8
+
9
+ class Regexp::Expression::Alternation < ::Regexp::Expression::SequenceOperation
10
+ def alternatives; end
11
+ def match_length; end
12
+ end
13
+
14
+ Regexp::Expression::Alternation::OPERAND = Regexp::Expression::Alternative
15
+
16
+ # A sequence of expressions, used by Alternation as one of its alternative.
17
+ class Regexp::Expression::Alternative < ::Regexp::Expression::Sequence; end
18
+
19
+ module Regexp::Expression::Anchor; end
20
+ Regexp::Expression::Anchor::BOL = Regexp::Expression::Anchor::BeginningOfLine
21
+ Regexp::Expression::Anchor::BOS = Regexp::Expression::Anchor::BeginningOfString
22
+
23
+ class Regexp::Expression::Anchor::Base < ::Regexp::Expression::Base
24
+ def match_length; end
25
+ end
26
+
27
+ class Regexp::Expression::Anchor::BeginningOfLine < ::Regexp::Expression::Anchor::Base; end
28
+ class Regexp::Expression::Anchor::BeginningOfString < ::Regexp::Expression::Anchor::Base; end
29
+ Regexp::Expression::Anchor::EOL = Regexp::Expression::Anchor::EndOfLine
30
+ Regexp::Expression::Anchor::EOS = Regexp::Expression::Anchor::EndOfString
31
+ Regexp::Expression::Anchor::EOSobEOL = Regexp::Expression::Anchor::EndOfStringOrBeforeEndOfLine
32
+ class Regexp::Expression::Anchor::EndOfLine < ::Regexp::Expression::Anchor::Base; end
33
+ class Regexp::Expression::Anchor::EndOfString < ::Regexp::Expression::Anchor::Base; end
34
+ class Regexp::Expression::Anchor::EndOfStringOrBeforeEndOfLine < ::Regexp::Expression::Anchor::Base; end
35
+ class Regexp::Expression::Anchor::MatchStart < ::Regexp::Expression::Anchor::Base; end
36
+ class Regexp::Expression::Anchor::NonWordBoundary < ::Regexp::Expression::Anchor::Base; end
37
+ class Regexp::Expression::Anchor::WordBoundary < ::Regexp::Expression::Anchor::Base; end
38
+ module Regexp::Expression::Assertion; end
39
+
40
+ class Regexp::Expression::Assertion::Base < ::Regexp::Expression::Group::Base
41
+ def match_length; end
42
+ end
43
+
44
+ class Regexp::Expression::Assertion::Lookahead < ::Regexp::Expression::Assertion::Base; end
45
+ class Regexp::Expression::Assertion::Lookbehind < ::Regexp::Expression::Assertion::Base; end
46
+ class Regexp::Expression::Assertion::NegativeLookahead < ::Regexp::Expression::Assertion::Base; end
47
+ class Regexp::Expression::Assertion::NegativeLookbehind < ::Regexp::Expression::Assertion::Base; end
48
+
49
+ # TODO: unify name with token :backref, one way or the other, in v3.0.0
50
+ module Regexp::Expression::Backreference; end
51
+
52
+ class Regexp::Expression::Backreference::Base < ::Regexp::Expression::Base
53
+ def match_length; end
54
+
55
+ # Returns the value of attribute referenced_expression.
56
+ def referenced_expression; end
57
+
58
+ # Sets the attribute referenced_expression
59
+ #
60
+ # @param value the value to set the attribute referenced_expression to.
61
+ def referenced_expression=(_arg0); end
62
+
63
+ private
64
+
65
+ def initialize_copy(orig); end
66
+ end
67
+
68
+ class Regexp::Expression::Backreference::Name < ::Regexp::Expression::Backreference::Base
69
+ # @return [Name] a new instance of Name
70
+ def initialize(token, options = T.unsafe(nil)); end
71
+
72
+ # Returns the value of attribute name.
73
+ def name; end
74
+
75
+ # Returns the value of attribute name.
76
+ def reference; end
77
+ end
78
+
79
+ class Regexp::Expression::Backreference::NameCall < ::Regexp::Expression::Backreference::Name; end
80
+
81
+ class Regexp::Expression::Backreference::NameRecursionLevel < ::Regexp::Expression::Backreference::Name
82
+ # @return [NameRecursionLevel] a new instance of NameRecursionLevel
83
+ def initialize(token, options = T.unsafe(nil)); end
84
+
85
+ # Returns the value of attribute recursion_level.
86
+ def recursion_level; end
87
+ end
88
+
89
+ class Regexp::Expression::Backreference::Number < ::Regexp::Expression::Backreference::Base
90
+ # @return [Number] a new instance of Number
91
+ def initialize(token, options = T.unsafe(nil)); end
92
+
93
+ # Returns the value of attribute number.
94
+ def number; end
95
+
96
+ # Returns the value of attribute number.
97
+ def reference; end
98
+ end
99
+
100
+ class Regexp::Expression::Backreference::NumberCall < ::Regexp::Expression::Backreference::Number; end
101
+ class Regexp::Expression::Backreference::NumberCallRelative < ::Regexp::Expression::Backreference::NumberRelative; end
102
+
103
+ class Regexp::Expression::Backreference::NumberRecursionLevel < ::Regexp::Expression::Backreference::Number
104
+ # @return [NumberRecursionLevel] a new instance of NumberRecursionLevel
105
+ def initialize(token, options = T.unsafe(nil)); end
106
+
107
+ # Returns the value of attribute recursion_level.
108
+ def recursion_level; end
109
+ end
110
+
111
+ class Regexp::Expression::Backreference::NumberRelative < ::Regexp::Expression::Backreference::Number
112
+ # Returns the value of attribute effective_number.
113
+ def effective_number; end
114
+
115
+ # Sets the attribute effective_number
116
+ #
117
+ # @param value the value to set the attribute effective_number to.
118
+ def effective_number=(_arg0); end
119
+
120
+ # Returns the value of attribute effective_number.
121
+ def reference; end
122
+ end
123
+
124
+ class Regexp::Expression::Base
125
+ include ::Regexp::Expression::Shared
126
+ include ::RuboCop::Ext::RegexpParser::Expression::Base
127
+ extend ::Regexp::Expression::Shared::ClassMethods
128
+
129
+ # @return [Base] a new instance of Base
130
+ def initialize(token, options = T.unsafe(nil)); end
131
+
132
+ def =~(string, offset = T.unsafe(nil)); end
133
+
134
+ # @return [Boolean]
135
+ def a?; end
136
+
137
+ # @return [Boolean]
138
+ def ascii_classes?; end
139
+
140
+ def attributes; end
141
+
142
+ # @return [Boolean]
143
+ def case_insensitive?; end
144
+
145
+ def conditional_level; end
146
+ def conditional_level=(_arg0); end
147
+
148
+ # @return [Boolean]
149
+ def d?; end
150
+
151
+ # @return [Boolean]
152
+ def default_classes?; end
153
+
154
+ # @return [Boolean]
155
+ def extended?; end
156
+
157
+ # @return [Boolean]
158
+ def free_spacing?; end
159
+
160
+ # @return [Boolean]
161
+ def greedy?; end
162
+
163
+ # @return [Boolean]
164
+ def i?; end
165
+
166
+ # @return [Boolean]
167
+ def ignore_case?; end
168
+
169
+ # @return [Boolean]
170
+ def lazy?; end
171
+
172
+ def level; end
173
+ def level=(_arg0); end
174
+
175
+ # @return [Boolean]
176
+ def m?; end
177
+
178
+ def match(string, offset = T.unsafe(nil)); end
179
+
180
+ # @return [Boolean]
181
+ def match?(string); end
182
+
183
+ # @return [Boolean]
184
+ def matches?(string); end
185
+
186
+ # @return [Boolean]
187
+ def multiline?; end
188
+
189
+ def nesting_level; end
190
+ def options; end
191
+ def options=(_arg0); end
192
+
193
+ # @return [Boolean]
194
+ def possessive?; end
195
+
196
+ def quantifier; end
197
+ def quantifier=(_arg0); end
198
+ def quantify(*args); end
199
+
200
+ # Deprecated. Prefer `#repetitions` which has a more uniform interface.
201
+ def quantity; end
202
+
203
+ # @return [Boolean]
204
+ def reluctant?; end
205
+
206
+ def repetitions; end
207
+ def set_level; end
208
+ def set_level=(_arg0); end
209
+
210
+ # %l Level (depth) of the expression. Returns 'root' for the root
211
+ # expression, returns zero or higher for all others.
212
+ #
213
+ # %> Indentation at expression's level.
214
+ #
215
+ # %x Index of the expression at its depth. Available when using
216
+ # the sprintf_tree method only.
217
+ #
218
+ # %s Start offset within the whole expression.
219
+ # %e End offset within the whole expression.
220
+ # %S Length of expression.
221
+ #
222
+ # %o Coded offset and length, same as '@%s+%S'
223
+ #
224
+ # %y Type of expression.
225
+ # %k Token of expression.
226
+ # %i ID, same as '%y:%k'
227
+ # %c Class name
228
+ #
229
+ # %q Quantifier info, as {m[,M]}
230
+ # %Q Quantifier text
231
+ #
232
+ # %z Quantifier min
233
+ # %Z Quantifier max
234
+ #
235
+ # %t Base text of the expression (excludes quantifier, if any)
236
+ # %~t Full text if the expression is terminal, otherwise %i
237
+ # %T Full text of the expression (includes quantifier, if any)
238
+ #
239
+ # %b Basic info, same as '%o %i'
240
+ # %m Most info, same as '%b %q'
241
+ # %a All info, same as '%m %t'
242
+ def strfre(format = T.unsafe(nil), indent_offset = T.unsafe(nil), index = T.unsafe(nil)); end
243
+
244
+ # %l Level (depth) of the expression. Returns 'root' for the root
245
+ # expression, returns zero or higher for all others.
246
+ #
247
+ # %> Indentation at expression's level.
248
+ #
249
+ # %x Index of the expression at its depth. Available when using
250
+ # the sprintf_tree method only.
251
+ #
252
+ # %s Start offset within the whole expression.
253
+ # %e End offset within the whole expression.
254
+ # %S Length of expression.
255
+ #
256
+ # %o Coded offset and length, same as '@%s+%S'
257
+ #
258
+ # %y Type of expression.
259
+ # %k Token of expression.
260
+ # %i ID, same as '%y:%k'
261
+ # %c Class name
262
+ #
263
+ # %q Quantifier info, as {m[,M]}
264
+ # %Q Quantifier text
265
+ #
266
+ # %z Quantifier min
267
+ # %Z Quantifier max
268
+ #
269
+ # %t Base text of the expression (excludes quantifier, if any)
270
+ # %~t Full text if the expression is terminal, otherwise %i
271
+ # %T Full text of the expression (includes quantifier, if any)
272
+ #
273
+ # %b Basic info, same as '%o %i'
274
+ # %m Most info, same as '%b %q'
275
+ # %a All info, same as '%m %t'
276
+ def strfregexp(format = T.unsafe(nil), indent_offset = T.unsafe(nil), index = T.unsafe(nil)); end
277
+
278
+ def te; end
279
+ def te=(_arg0); end
280
+ def text; end
281
+ def text=(_arg0); end
282
+ def to_h; end
283
+ def to_re(format = T.unsafe(nil)); end
284
+ def token; end
285
+ def token=(_arg0); end
286
+ def ts; end
287
+ def ts=(_arg0); end
288
+ def type; end
289
+ def type=(_arg0); end
290
+
291
+ # @return [Boolean]
292
+ def u?; end
293
+
294
+ # @return [Boolean]
295
+ def unicode_classes?; end
296
+
297
+ def unquantified_clone; end
298
+
299
+ # @return [Boolean]
300
+ def x?; end
301
+
302
+ private
303
+
304
+ def initialize_copy(orig); end
305
+ end
306
+
307
+ class Regexp::Expression::CharacterSet < ::Regexp::Expression::Subexpression
308
+ include ::RuboCop::Ext::RegexpParser::Expression::CharacterSet
309
+
310
+ # @return [CharacterSet] a new instance of CharacterSet
311
+ def initialize(token, options = T.unsafe(nil)); end
312
+
313
+ def close; end
314
+
315
+ # Returns the value of attribute closed.
316
+ def closed; end
317
+
318
+ # Sets the attribute closed
319
+ #
320
+ # @param value the value to set the attribute closed to.
321
+ def closed=(_arg0); end
322
+
323
+ # Returns the value of attribute closed.
324
+ def closed?; end
325
+
326
+ def match_length; end
327
+ def negate; end
328
+
329
+ # Returns the value of attribute negative.
330
+ def negated?; end
331
+
332
+ # Returns the value of attribute negative.
333
+ def negative; end
334
+
335
+ # Sets the attribute negative
336
+ #
337
+ # @param value the value to set the attribute negative to.
338
+ def negative=(_arg0); end
339
+
340
+ # Returns the value of attribute negative.
341
+ def negative?; end
342
+
343
+ def parts; end
344
+ end
345
+
346
+ class Regexp::Expression::CharacterSet::IntersectedSequence < ::Regexp::Expression::Sequence
347
+ def match_length; end
348
+ end
349
+
350
+ class Regexp::Expression::CharacterSet::Intersection < ::Regexp::Expression::SequenceOperation
351
+ def match_length; end
352
+ end
353
+
354
+ Regexp::Expression::CharacterSet::Intersection::OPERAND = Regexp::Expression::CharacterSet::IntersectedSequence
355
+
356
+ class Regexp::Expression::CharacterSet::Range < ::Regexp::Expression::Subexpression
357
+ def <<(exp); end
358
+
359
+ # @return [Boolean]
360
+ def complete?; end
361
+
362
+ def match_length; end
363
+ def parts; end
364
+ def starts_at; end
365
+ def ts; end
366
+ end
367
+
368
+ module Regexp::Expression::CharacterType; end
369
+ class Regexp::Expression::CharacterType::Any < ::Regexp::Expression::CharacterType::Base; end
370
+
371
+ class Regexp::Expression::CharacterType::Base < ::Regexp::Expression::Base
372
+ def match_length; end
373
+ end
374
+
375
+ class Regexp::Expression::CharacterType::Digit < ::Regexp::Expression::CharacterType::Base; end
376
+ class Regexp::Expression::CharacterType::ExtendedGrapheme < ::Regexp::Expression::CharacterType::Base; end
377
+ class Regexp::Expression::CharacterType::Hex < ::Regexp::Expression::CharacterType::Base; end
378
+ class Regexp::Expression::CharacterType::Linebreak < ::Regexp::Expression::CharacterType::Base; end
379
+ class Regexp::Expression::CharacterType::NonDigit < ::Regexp::Expression::CharacterType::Base; end
380
+ class Regexp::Expression::CharacterType::NonHex < ::Regexp::Expression::CharacterType::Base; end
381
+ class Regexp::Expression::CharacterType::NonSpace < ::Regexp::Expression::CharacterType::Base; end
382
+ class Regexp::Expression::CharacterType::NonWord < ::Regexp::Expression::CharacterType::Base; end
383
+ class Regexp::Expression::CharacterType::Space < ::Regexp::Expression::CharacterType::Base; end
384
+ class Regexp::Expression::CharacterType::Word < ::Regexp::Expression::CharacterType::Base; end
385
+ class Regexp::Expression::Comment < ::Regexp::Expression::FreeSpace; end
386
+ module Regexp::Expression::Conditional; end
387
+ class Regexp::Expression::Conditional::Branch < ::Regexp::Expression::Sequence; end
388
+
389
+ class Regexp::Expression::Conditional::Condition < ::Regexp::Expression::Base
390
+ def match_length; end
391
+
392
+ # Name or number of the referenced capturing group that determines state.
393
+ # Returns a String if reference is by name, Integer if by number.
394
+ def reference; end
395
+
396
+ # Returns the value of attribute referenced_expression.
397
+ def referenced_expression; end
398
+
399
+ # Sets the attribute referenced_expression
400
+ #
401
+ # @param value the value to set the attribute referenced_expression to.
402
+ def referenced_expression=(_arg0); end
403
+
404
+ private
405
+
406
+ def initialize_copy(orig); end
407
+ end
408
+
409
+ class Regexp::Expression::Conditional::Expression < ::Regexp::Expression::Subexpression
410
+ def <<(exp); end
411
+
412
+ # @raise [TooManyBranches]
413
+ def add_sequence(active_opts = T.unsafe(nil)); end
414
+
415
+ # @raise [TooManyBranches]
416
+ def branch(active_opts = T.unsafe(nil)); end
417
+
418
+ def branches; end
419
+ def condition; end
420
+ def condition=(exp); end
421
+ def match_length; end
422
+ def parts; end
423
+ def reference; end
424
+
425
+ # Returns the value of attribute referenced_expression.
426
+ def referenced_expression; end
427
+
428
+ # Sets the attribute referenced_expression
429
+ #
430
+ # @param value the value to set the attribute referenced_expression to.
431
+ def referenced_expression=(_arg0); end
432
+
433
+ private
434
+
435
+ def initialize_copy(orig); end
436
+ end
437
+
438
+ class Regexp::Expression::Conditional::TooManyBranches < ::Regexp::Parser::Error
439
+ # @return [TooManyBranches] a new instance of TooManyBranches
440
+ def initialize; end
441
+ end
442
+
443
+ # TODO: unify naming with Token::Escape, on way or the other, in v3.0.0
444
+ module Regexp::Expression::EscapeSequence; end
445
+
446
+ class Regexp::Expression::EscapeSequence::AbstractMetaControlSequence < ::Regexp::Expression::EscapeSequence::Base
447
+ def char; end
448
+
449
+ private
450
+
451
+ def control_sequence_to_s(control_sequence); end
452
+ def meta_char_to_codepoint(meta_char); end
453
+ end
454
+
455
+ class Regexp::Expression::EscapeSequence::AsciiEscape < ::Regexp::Expression::EscapeSequence::Base; end
456
+ class Regexp::Expression::EscapeSequence::Backspace < ::Regexp::Expression::EscapeSequence::Base; end
457
+
458
+ class Regexp::Expression::EscapeSequence::Base < ::Regexp::Expression::Base
459
+ def char; end
460
+ def codepoint; end
461
+ def match_length; end
462
+ end
463
+
464
+ class Regexp::Expression::EscapeSequence::Bell < ::Regexp::Expression::EscapeSequence::Base; end
465
+ class Regexp::Expression::EscapeSequence::Codepoint < ::Regexp::Expression::EscapeSequence::Base; end
466
+
467
+ class Regexp::Expression::EscapeSequence::CodepointList < ::Regexp::Expression::EscapeSequence::Base
468
+ # @raise [NoMethodError]
469
+ def char; end
470
+
471
+ def chars; end
472
+
473
+ # @raise [NoMethodError]
474
+ def codepoint; end
475
+
476
+ def codepoints; end
477
+ def match_length; end
478
+ end
479
+
480
+ class Regexp::Expression::EscapeSequence::Control < ::Regexp::Expression::EscapeSequence::AbstractMetaControlSequence
481
+ def codepoint; end
482
+ end
483
+
484
+ class Regexp::Expression::EscapeSequence::FormFeed < ::Regexp::Expression::EscapeSequence::Base; end
485
+ class Regexp::Expression::EscapeSequence::Hex < ::Regexp::Expression::EscapeSequence::Base; end
486
+
487
+ class Regexp::Expression::EscapeSequence::Literal < ::Regexp::Expression::EscapeSequence::Base
488
+ def char; end
489
+ end
490
+
491
+ class Regexp::Expression::EscapeSequence::Meta < ::Regexp::Expression::EscapeSequence::AbstractMetaControlSequence
492
+ def codepoint; end
493
+ end
494
+
495
+ class Regexp::Expression::EscapeSequence::MetaControl < ::Regexp::Expression::EscapeSequence::AbstractMetaControlSequence
496
+ def codepoint; end
497
+ end
498
+
499
+ class Regexp::Expression::EscapeSequence::Newline < ::Regexp::Expression::EscapeSequence::Base; end
500
+
501
+ class Regexp::Expression::EscapeSequence::Octal < ::Regexp::Expression::EscapeSequence::Base
502
+ def char; end
503
+ end
504
+
505
+ class Regexp::Expression::EscapeSequence::Return < ::Regexp::Expression::EscapeSequence::Base; end
506
+ class Regexp::Expression::EscapeSequence::Tab < ::Regexp::Expression::EscapeSequence::Base; end
507
+ class Regexp::Expression::EscapeSequence::VerticalTab < ::Regexp::Expression::EscapeSequence::Base; end
508
+
509
+ class Regexp::Expression::FreeSpace < ::Regexp::Expression::Base
510
+ def match_length; end
511
+
512
+ # @raise [Regexp::Parser::Error]
513
+ def quantify(*_args); end
514
+ end
515
+
516
+ module Regexp::Expression::Group; end
517
+
518
+ # Special case. Absence group can match 0.. chars, irrespective of content.
519
+ # TODO: in theory, they *can* exclude match lengths with `.`: `(?~.{3})`
520
+ class Regexp::Expression::Group::Absence < ::Regexp::Expression::Group::Base
521
+ def match_length; end
522
+ end
523
+
524
+ class Regexp::Expression::Group::Atomic < ::Regexp::Expression::Group::Base; end
525
+
526
+ class Regexp::Expression::Group::Base < ::Regexp::Expression::Subexpression
527
+ # @return [Boolean]
528
+ def capturing?; end
529
+
530
+ # @return [Boolean]
531
+ def comment?; end
532
+
533
+ def parts; end
534
+ end
535
+
536
+ class Regexp::Expression::Group::Capture < ::Regexp::Expression::Group::Base
537
+ # @return [Boolean]
538
+ def capturing?; end
539
+
540
+ # Returns the value of attribute number.
541
+ def identifier; end
542
+
543
+ # Returns the value of attribute number.
544
+ def number; end
545
+
546
+ # Sets the attribute number
547
+ #
548
+ # @param value the value to set the attribute number to.
549
+ def number=(_arg0); end
550
+
551
+ # Returns the value of attribute number_at_level.
552
+ def number_at_level; end
553
+
554
+ # Sets the attribute number_at_level
555
+ #
556
+ # @param value the value to set the attribute number_at_level to.
557
+ def number_at_level=(_arg0); end
558
+ end
559
+
560
+ class Regexp::Expression::Group::Comment < ::Regexp::Expression::Group::Base
561
+ # @return [Boolean]
562
+ def comment?; end
563
+
564
+ def parts; end
565
+ end
566
+
567
+ class Regexp::Expression::Group::Named < ::Regexp::Expression::Group::Capture
568
+ # @return [Named] a new instance of Named
569
+ def initialize(token, options = T.unsafe(nil)); end
570
+
571
+ # Returns the value of attribute name.
572
+ def identifier; end
573
+
574
+ # Returns the value of attribute name.
575
+ def name; end
576
+
577
+ private
578
+
579
+ def initialize_copy(orig); end
580
+ end
581
+
582
+ class Regexp::Expression::Group::Options < ::Regexp::Expression::Group::Base
583
+ # Returns the value of attribute option_changes.
584
+ def option_changes; end
585
+
586
+ # Sets the attribute option_changes
587
+ #
588
+ # @param value the value to set the attribute option_changes to.
589
+ def option_changes=(_arg0); end
590
+
591
+ private
592
+
593
+ def initialize_copy(orig); end
594
+ end
595
+
596
+ class Regexp::Expression::Group::Passive < ::Regexp::Expression::Group::Base
597
+ # @return [Passive] a new instance of Passive
598
+ def initialize(*_arg0); end
599
+
600
+ # Sets the attribute implicit
601
+ #
602
+ # @param value the value to set the attribute implicit to.
603
+ def implicit=(_arg0); end
604
+
605
+ # @return [Boolean]
606
+ def implicit?; end
607
+
608
+ def parts; end
609
+ end
610
+
611
+ module Regexp::Expression::Keep; end
612
+
613
+ # TOOD: in regexp_parser v3.0.0 this should possibly be a Subexpression
614
+ # that contains all expressions to its left.
615
+ class Regexp::Expression::Keep::Mark < ::Regexp::Expression::Base
616
+ def match_length; end
617
+ end
618
+
619
+ class Regexp::Expression::Literal < ::Regexp::Expression::Base
620
+ def match_length; end
621
+ end
622
+
623
+ Regexp::Expression::MatchLength = Regexp::MatchLength
624
+
625
+ class Regexp::Expression::PosixClass < ::Regexp::Expression::Base
626
+ def match_length; end
627
+ def name; end
628
+
629
+ # @return [Boolean]
630
+ def negative?; end
631
+ end
632
+
633
+ # TODO: in v3.0.0, maybe put Shared back into Base, and inherit from Base and
634
+ # call super in #initialize, but raise in #quantifier= and #quantify,
635
+ # or introduce an Expression::Quantifiable intermediate class.
636
+ # Or actually allow chaining as a more concise but tricky solution than PR#69.
637
+ class Regexp::Expression::Quantifier
638
+ include ::Regexp::Expression::Shared
639
+ extend ::Regexp::Expression::Shared::ClassMethods
640
+
641
+ # @return [Quantifier] a new instance of Quantifier
642
+ def initialize(*args); end
643
+
644
+ def conditional_level; end
645
+ def conditional_level=(_arg0); end
646
+ def greedy?; end
647
+ def lazy?; end
648
+ def level; end
649
+ def level=(_arg0); end
650
+
651
+ # Returns the value of attribute max.
652
+ def max; end
653
+
654
+ # Returns the value of attribute min.
655
+ def min; end
656
+
657
+ # Returns the value of attribute mode.
658
+ def mode; end
659
+
660
+ def nesting_level; end
661
+ def options; end
662
+ def options=(_arg0); end
663
+ def possessive?; end
664
+ def quantifier; end
665
+ def quantifier=(_arg0); end
666
+ def reluctant?; end
667
+ def set_level; end
668
+ def set_level=(_arg0); end
669
+ def te; end
670
+ def te=(_arg0); end
671
+ def text; end
672
+ def text=(_arg0); end
673
+ def to_h; end
674
+ def token; end
675
+ def token=(_arg0); end
676
+ def ts; end
677
+ def ts=(_arg0); end
678
+ def type; end
679
+ def type=(_arg0); end
680
+
681
+ private
682
+
683
+ def deprecated_old_init(token, text, min, max, mode = T.unsafe(nil)); end
684
+ def minmax; end
685
+ end
686
+
687
+ Regexp::Expression::Quantifier::MODES = T.let(T.unsafe(nil), Array)
688
+
689
+ class Regexp::Expression::Root < ::Regexp::Expression::Subexpression
690
+ class << self
691
+ def build(options = T.unsafe(nil)); end
692
+ end
693
+ end
694
+
695
+ # A sequence of expressions. Differs from a Subexpressions by how it handles
696
+ # quantifiers, as it applies them to its last element instead of itself as
697
+ # a whole subexpression.
698
+ #
699
+ # Used as the base class for the Alternation alternatives, Conditional
700
+ # branches, and CharacterSet::Intersection intersected sequences.
701
+ class Regexp::Expression::Sequence < ::Regexp::Expression::Subexpression
702
+ def quantify(*args); end
703
+ def starts_at; end
704
+ def ts; end
705
+
706
+ class << self
707
+ def add_to(exp, params = T.unsafe(nil), active_opts = T.unsafe(nil)); end
708
+ end
709
+ end
710
+
711
+ # abstract class
712
+ class Regexp::Expression::SequenceOperation < ::Regexp::Expression::Subexpression
713
+ def <<(exp); end
714
+ def add_sequence(active_opts = T.unsafe(nil)); end
715
+ def operands; end
716
+ def operator; end
717
+ def parts; end
718
+ def sequences; end
719
+ def starts_at; end
720
+ def ts; end
721
+ end
722
+
723
+ module Regexp::Expression::Shared
724
+ mixes_in_class_methods ::Regexp::Expression::Shared::ClassMethods
725
+
726
+ # Deep-compare two expressions for equality.
727
+ def ==(other); end
728
+
729
+ # Deep-compare two expressions for equality.
730
+ def ===(other); end
731
+
732
+ def base_length; end
733
+ def coded_offset; end
734
+
735
+ # Deep-compare two expressions for equality.
736
+ def eql?(other); end
737
+
738
+ def full_length; end
739
+
740
+ # Test if this expression has the given test_token, and optionally a given
741
+ # test_type.
742
+ #
743
+ # # Any expressions
744
+ # exp.is? :* # always returns true
745
+ #
746
+ # # is it a :capture
747
+ # exp.is? :capture
748
+ #
749
+ # # is it a :character and a :set
750
+ # exp.is? :character, :set
751
+ #
752
+ # # is it a :meta :dot
753
+ # exp.is? :dot, :meta
754
+ #
755
+ # # is it a :meta or :escape :dot
756
+ # exp.is? :dot, [:meta, :escape]
757
+ #
758
+ # @return [Boolean]
759
+ def is?(test_token, test_type = T.unsafe(nil)); end
760
+
761
+ def nesting_level=(lvl); end
762
+ def offset; end
763
+
764
+ # Test if this expression matches an entry in the given scope spec.
765
+ #
766
+ # A scope spec can be one of:
767
+ #
768
+ # . An array: Interpreted as a set of tokens, tested for inclusion
769
+ # of the expression's token.
770
+ #
771
+ # . A hash: Where the key is interpreted as the expression type
772
+ # and the value is either a symbol or an array. In this
773
+ # case, when the scope is a hash, one_of? calls itself to
774
+ # evaluate the key's value.
775
+ #
776
+ # . A symbol: matches the expression's token or type, depending on
777
+ # the level of the call. If one_of? is called directly with
778
+ # a symbol then it will always be checked against the
779
+ # type of the expression. If it's being called for a value
780
+ # from a hash, it will be checked against the token of the
781
+ # expression.
782
+ #
783
+ # # any expression
784
+ # exp.one_of?(:*) # always true
785
+ #
786
+ # # like exp.type?(:group)
787
+ # exp.one_of?(:group)
788
+ #
789
+ # # any expression of type meta
790
+ # exp.one_of?(:meta => :*)
791
+ #
792
+ # # meta dots and alternations
793
+ # exp.one_of?(:meta => [:dot, :alternation])
794
+ #
795
+ # # meta dots and any set tokens
796
+ # exp.one_of?({meta: [:dot], set: :*})
797
+ #
798
+ # @return [Boolean]
799
+ def one_of?(scope, top = T.unsafe(nil)); end
800
+
801
+ def parts; end
802
+
803
+ # @return [Boolean]
804
+ def quantified?; end
805
+
806
+ def quantifier_affix(expression_format); end
807
+ def starts_at; end
808
+
809
+ # @return [Boolean]
810
+ def terminal?; end
811
+
812
+ def to_s(format = T.unsafe(nil)); end
813
+ def to_str(format = T.unsafe(nil)); end
814
+ def token_class; end
815
+
816
+ # Test if this expression has the given test_type, which can be either
817
+ # a symbol or an array of symbols to check against the expression's type.
818
+ #
819
+ # # is it a :group expression
820
+ # exp.type? :group
821
+ #
822
+ # # is it a :set, or :meta
823
+ # exp.type? [:set, :meta]
824
+ #
825
+ # @return [Boolean]
826
+ def type?(test_type); end
827
+
828
+ private
829
+
830
+ def init_from_token_and_options(token, options = T.unsafe(nil)); end
831
+ def initialize_copy(orig); end
832
+
833
+ class << self
834
+ # @private
835
+ def included(mod); end
836
+ end
837
+ end
838
+
839
+ # filled in ./methods/*.rb
840
+ module Regexp::Expression::Shared::ClassMethods
841
+ # Convenience method to init a valid Expression without a Regexp::Token
842
+ #
843
+ # @raise [ArgumentError]
844
+ def construct(params = T.unsafe(nil)); end
845
+
846
+ def construct_defaults; end
847
+ def token_class; end
848
+ end
849
+
850
+ class Regexp::Expression::Subexpression < ::Regexp::Expression::Base
851
+ include ::Enumerable
852
+
853
+ # @return [Subexpression] a new instance of Subexpression
854
+ def initialize(token, options = T.unsafe(nil)); end
855
+
856
+ def <<(exp); end
857
+ def [](*args, &block); end
858
+ def at(*args, &block); end
859
+ def dig(*indices); end
860
+ def each(*args, &block); end
861
+
862
+ # Iterates over the expressions of this expression as an array, passing
863
+ # the expression and its index within its parent to the given block.
864
+ def each_expression(include_self = T.unsafe(nil)); end
865
+
866
+ def empty?(*args, &block); end
867
+
868
+ # Returns the value of attribute expressions.
869
+ def expressions; end
870
+
871
+ # Sets the attribute expressions
872
+ #
873
+ # @param value the value to set the attribute expressions to.
874
+ def expressions=(_arg0); end
875
+
876
+ def fetch(*args, &block); end
877
+
878
+ # Returns a new array with the results of calling the given block once
879
+ # for every expression. If a block is not given, returns an array with
880
+ # each expression and its level index as an array.
881
+ def flat_map(include_self = T.unsafe(nil)); end
882
+
883
+ def index(*args, &block); end
884
+ def inner_match_length; end
885
+ def join(*args, &block); end
886
+ def last(*args, &block); end
887
+ def length(*args, &block); end
888
+ def match_length; end
889
+ def parts; end
890
+ def strfre_tree(format = T.unsafe(nil), include_self = T.unsafe(nil), separator = T.unsafe(nil)); end
891
+ def strfregexp_tree(format = T.unsafe(nil), include_self = T.unsafe(nil), separator = T.unsafe(nil)); end
892
+ def te; end
893
+ def to_h; end
894
+
895
+ # Traverses the subexpression (depth-first, pre-order) and calls the given
896
+ # block for each expression with three arguments; the traversal event,
897
+ # the expression, and the index of the expression within its parent.
898
+ #
899
+ # The event argument is passed as follows:
900
+ #
901
+ # - For subexpressions, :enter upon entering the subexpression, and
902
+ # :exit upon exiting it.
903
+ #
904
+ # - For terminal expressions, :visit is called once.
905
+ #
906
+ # Returns self.
907
+ def traverse(include_self = T.unsafe(nil), &block); end
908
+
909
+ def values_at(*args, &block); end
910
+
911
+ # Traverses the subexpression (depth-first, pre-order) and calls the given
912
+ # block for each expression with three arguments; the traversal event,
913
+ # the expression, and the index of the expression within its parent.
914
+ #
915
+ # The event argument is passed as follows:
916
+ #
917
+ # - For subexpressions, :enter upon entering the subexpression, and
918
+ # :exit upon exiting it.
919
+ #
920
+ # - For terminal expressions, :visit is called once.
921
+ #
922
+ # Returns self.
923
+ def walk(include_self = T.unsafe(nil), &block); end
924
+
925
+ private
926
+
927
+ # Override base method to clone the expressions as well.
928
+ def initialize_copy(orig); end
929
+
930
+ def intersperse(expressions, separator); end
931
+ end
932
+
933
+ # TODO: unify name with token :property, on way or the other, in v3.0.0
934
+ module Regexp::Expression::UnicodeProperty; end
935
+
936
+ class Regexp::Expression::UnicodeProperty::Age < ::Regexp::Expression::UnicodeProperty::Base; end
937
+ class Regexp::Expression::UnicodeProperty::Alnum < ::Regexp::Expression::UnicodeProperty::Base; end
938
+ class Regexp::Expression::UnicodeProperty::Alpha < ::Regexp::Expression::UnicodeProperty::Base; end
939
+ class Regexp::Expression::UnicodeProperty::Any < ::Regexp::Expression::UnicodeProperty::Base; end
940
+ class Regexp::Expression::UnicodeProperty::Ascii < ::Regexp::Expression::UnicodeProperty::Base; end
941
+ class Regexp::Expression::UnicodeProperty::Assigned < ::Regexp::Expression::UnicodeProperty::Base; end
942
+
943
+ class Regexp::Expression::UnicodeProperty::Base < ::Regexp::Expression::Base
944
+ def match_length; end
945
+ def name; end
946
+
947
+ # @return [Boolean]
948
+ def negative?; end
949
+
950
+ def shortcut; end
951
+ end
952
+
953
+ class Regexp::Expression::UnicodeProperty::Blank < ::Regexp::Expression::UnicodeProperty::Base; end
954
+ class Regexp::Expression::UnicodeProperty::Block < ::Regexp::Expression::UnicodeProperty::Base; end
955
+ class Regexp::Expression::UnicodeProperty::Cntrl < ::Regexp::Expression::UnicodeProperty::Base; end
956
+ module Regexp::Expression::UnicodeProperty::Codepoint; end
957
+ class Regexp::Expression::UnicodeProperty::Codepoint::Any < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end
958
+ class Regexp::Expression::UnicodeProperty::Codepoint::Base < ::Regexp::Expression::UnicodeProperty::Base; end
959
+ class Regexp::Expression::UnicodeProperty::Codepoint::Control < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end
960
+ class Regexp::Expression::UnicodeProperty::Codepoint::Format < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end
961
+ class Regexp::Expression::UnicodeProperty::Codepoint::PrivateUse < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end
962
+ class Regexp::Expression::UnicodeProperty::Codepoint::Surrogate < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end
963
+ class Regexp::Expression::UnicodeProperty::Codepoint::Unassigned < ::Regexp::Expression::UnicodeProperty::Codepoint::Base; end
964
+ class Regexp::Expression::UnicodeProperty::Derived < ::Regexp::Expression::UnicodeProperty::Base; end
965
+ class Regexp::Expression::UnicodeProperty::Digit < ::Regexp::Expression::UnicodeProperty::Base; end
966
+ class Regexp::Expression::UnicodeProperty::Emoji < ::Regexp::Expression::UnicodeProperty::Base; end
967
+ class Regexp::Expression::UnicodeProperty::Graph < ::Regexp::Expression::UnicodeProperty::Base; end
968
+ module Regexp::Expression::UnicodeProperty::Letter; end
969
+ class Regexp::Expression::UnicodeProperty::Letter::Any < ::Regexp::Expression::UnicodeProperty::Letter::Base; end
970
+ class Regexp::Expression::UnicodeProperty::Letter::Base < ::Regexp::Expression::UnicodeProperty::Base; end
971
+ class Regexp::Expression::UnicodeProperty::Letter::Cased < ::Regexp::Expression::UnicodeProperty::Letter::Base; end
972
+ class Regexp::Expression::UnicodeProperty::Letter::Lowercase < ::Regexp::Expression::UnicodeProperty::Letter::Base; end
973
+ class Regexp::Expression::UnicodeProperty::Letter::Modifier < ::Regexp::Expression::UnicodeProperty::Letter::Base; end
974
+ class Regexp::Expression::UnicodeProperty::Letter::Other < ::Regexp::Expression::UnicodeProperty::Letter::Base; end
975
+ class Regexp::Expression::UnicodeProperty::Letter::Titlecase < ::Regexp::Expression::UnicodeProperty::Letter::Base; end
976
+ class Regexp::Expression::UnicodeProperty::Letter::Uppercase < ::Regexp::Expression::UnicodeProperty::Letter::Base; end
977
+ class Regexp::Expression::UnicodeProperty::Lower < ::Regexp::Expression::UnicodeProperty::Base; end
978
+ module Regexp::Expression::UnicodeProperty::Mark; end
979
+ class Regexp::Expression::UnicodeProperty::Mark::Any < ::Regexp::Expression::UnicodeProperty::Mark::Base; end
980
+ class Regexp::Expression::UnicodeProperty::Mark::Base < ::Regexp::Expression::UnicodeProperty::Base; end
981
+ class Regexp::Expression::UnicodeProperty::Mark::Combining < ::Regexp::Expression::UnicodeProperty::Mark::Base; end
982
+ class Regexp::Expression::UnicodeProperty::Mark::Enclosing < ::Regexp::Expression::UnicodeProperty::Mark::Base; end
983
+ class Regexp::Expression::UnicodeProperty::Mark::Nonspacing < ::Regexp::Expression::UnicodeProperty::Mark::Base; end
984
+ class Regexp::Expression::UnicodeProperty::Mark::Spacing < ::Regexp::Expression::UnicodeProperty::Mark::Base; end
985
+ class Regexp::Expression::UnicodeProperty::Newline < ::Regexp::Expression::UnicodeProperty::Base; end
986
+ module Regexp::Expression::UnicodeProperty::Number; end
987
+ class Regexp::Expression::UnicodeProperty::Number::Any < ::Regexp::Expression::UnicodeProperty::Number::Base; end
988
+ class Regexp::Expression::UnicodeProperty::Number::Base < ::Regexp::Expression::UnicodeProperty::Base; end
989
+ class Regexp::Expression::UnicodeProperty::Number::Decimal < ::Regexp::Expression::UnicodeProperty::Number::Base; end
990
+ class Regexp::Expression::UnicodeProperty::Number::Letter < ::Regexp::Expression::UnicodeProperty::Number::Base; end
991
+ class Regexp::Expression::UnicodeProperty::Number::Other < ::Regexp::Expression::UnicodeProperty::Number::Base; end
992
+ class Regexp::Expression::UnicodeProperty::Print < ::Regexp::Expression::UnicodeProperty::Base; end
993
+ class Regexp::Expression::UnicodeProperty::Punct < ::Regexp::Expression::UnicodeProperty::Base; end
994
+ module Regexp::Expression::UnicodeProperty::Punctuation; end
995
+ class Regexp::Expression::UnicodeProperty::Punctuation::Any < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end
996
+ class Regexp::Expression::UnicodeProperty::Punctuation::Base < ::Regexp::Expression::UnicodeProperty::Base; end
997
+ class Regexp::Expression::UnicodeProperty::Punctuation::Close < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end
998
+ class Regexp::Expression::UnicodeProperty::Punctuation::Connector < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end
999
+ class Regexp::Expression::UnicodeProperty::Punctuation::Dash < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end
1000
+ class Regexp::Expression::UnicodeProperty::Punctuation::Final < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end
1001
+ class Regexp::Expression::UnicodeProperty::Punctuation::Initial < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end
1002
+ class Regexp::Expression::UnicodeProperty::Punctuation::Open < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end
1003
+ class Regexp::Expression::UnicodeProperty::Punctuation::Other < ::Regexp::Expression::UnicodeProperty::Punctuation::Base; end
1004
+ class Regexp::Expression::UnicodeProperty::Script < ::Regexp::Expression::UnicodeProperty::Base; end
1005
+ module Regexp::Expression::UnicodeProperty::Separator; end
1006
+ class Regexp::Expression::UnicodeProperty::Separator::Any < ::Regexp::Expression::UnicodeProperty::Separator::Base; end
1007
+ class Regexp::Expression::UnicodeProperty::Separator::Base < ::Regexp::Expression::UnicodeProperty::Base; end
1008
+ class Regexp::Expression::UnicodeProperty::Separator::Line < ::Regexp::Expression::UnicodeProperty::Separator::Base; end
1009
+ class Regexp::Expression::UnicodeProperty::Separator::Paragraph < ::Regexp::Expression::UnicodeProperty::Separator::Base; end
1010
+ class Regexp::Expression::UnicodeProperty::Separator::Space < ::Regexp::Expression::UnicodeProperty::Separator::Base; end
1011
+ class Regexp::Expression::UnicodeProperty::Space < ::Regexp::Expression::UnicodeProperty::Base; end
1012
+ module Regexp::Expression::UnicodeProperty::Symbol; end
1013
+ class Regexp::Expression::UnicodeProperty::Symbol::Any < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end
1014
+ class Regexp::Expression::UnicodeProperty::Symbol::Base < ::Regexp::Expression::UnicodeProperty::Base; end
1015
+ class Regexp::Expression::UnicodeProperty::Symbol::Currency < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end
1016
+ class Regexp::Expression::UnicodeProperty::Symbol::Math < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end
1017
+ class Regexp::Expression::UnicodeProperty::Symbol::Modifier < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end
1018
+ class Regexp::Expression::UnicodeProperty::Symbol::Other < ::Regexp::Expression::UnicodeProperty::Symbol::Base; end
1019
+ class Regexp::Expression::UnicodeProperty::Upper < ::Regexp::Expression::UnicodeProperty::Base; end
1020
+ class Regexp::Expression::UnicodeProperty::Word < ::Regexp::Expression::UnicodeProperty::Base; end
1021
+ class Regexp::Expression::UnicodeProperty::XPosixPunct < ::Regexp::Expression::UnicodeProperty::Base; end
1022
+ class Regexp::Expression::UnicodeProperty::Xdigit < ::Regexp::Expression::UnicodeProperty::Base; end
1023
+
1024
+ class Regexp::Expression::WhiteSpace < ::Regexp::Expression::FreeSpace
1025
+ def merge(exp); end
1026
+ end
1027
+
1028
+ # A very thin wrapper around the scanner that breaks quantified literal runs,
1029
+ # collects emitted tokens into an array, calculates their nesting depth, and
1030
+ # normalizes tokens for the parser, and checks if they are implemented by the
1031
+ # given syntax flavor.
1032
+ class Regexp::Lexer
1033
+ def lex(input, syntax = T.unsafe(nil), options: T.unsafe(nil), &block); end
1034
+
1035
+ private
1036
+
1037
+ def ascend(type, token); end
1038
+ def break_codepoint_list(token); end
1039
+
1040
+ # called by scan to break a literal run that is longer than one character
1041
+ # into two separate tokens when it is followed by a quantifier
1042
+ def break_literal(token); end
1043
+
1044
+ # Returns the value of attribute conditional_nesting.
1045
+ def conditional_nesting; end
1046
+
1047
+ # Sets the attribute conditional_nesting
1048
+ #
1049
+ # @param value the value to set the attribute conditional_nesting to.
1050
+ def conditional_nesting=(_arg0); end
1051
+
1052
+ def descend(type, token); end
1053
+ def merge_condition(current); end
1054
+
1055
+ # Returns the value of attribute nesting.
1056
+ def nesting; end
1057
+
1058
+ # Sets the attribute nesting
1059
+ #
1060
+ # @param value the value to set the attribute nesting to.
1061
+ def nesting=(_arg0); end
1062
+
1063
+ # Returns the value of attribute set_nesting.
1064
+ def set_nesting; end
1065
+
1066
+ # Sets the attribute set_nesting
1067
+ #
1068
+ # @param value the value to set the attribute set_nesting to.
1069
+ def set_nesting=(_arg0); end
1070
+
1071
+ # Returns the value of attribute shift.
1072
+ def shift; end
1073
+
1074
+ # Sets the attribute shift
1075
+ #
1076
+ # @param value the value to set the attribute shift to.
1077
+ def shift=(_arg0); end
1078
+
1079
+ # Returns the value of attribute tokens.
1080
+ def tokens; end
1081
+
1082
+ # Sets the attribute tokens
1083
+ #
1084
+ # @param value the value to set the attribute tokens to.
1085
+ def tokens=(_arg0); end
1086
+
1087
+ class << self
1088
+ def lex(input, syntax = T.unsafe(nil), options: T.unsafe(nil), &block); end
1089
+ def scan(input, syntax = T.unsafe(nil), options: T.unsafe(nil), &block); end
1090
+ end
1091
+ end
1092
+
1093
+ Regexp::Lexer::CLOSING_TOKENS = T.let(T.unsafe(nil), Array)
1094
+ Regexp::Lexer::CONDITION_TOKENS = T.let(T.unsafe(nil), Array)
1095
+ Regexp::Lexer::OPENING_TOKENS = T.let(T.unsafe(nil), Array)
1096
+
1097
+ class Regexp::MatchLength
1098
+ include ::Enumerable
1099
+
1100
+ # @return [MatchLength] a new instance of MatchLength
1101
+ def initialize(exp, opts = T.unsafe(nil)); end
1102
+
1103
+ def each(opts = T.unsafe(nil)); end
1104
+ def endless_each; end
1105
+
1106
+ # @return [Boolean]
1107
+ def fixed?; end
1108
+
1109
+ # @return [Boolean]
1110
+ def include?(length); end
1111
+
1112
+ def inspect; end
1113
+ def max; end
1114
+ def min; end
1115
+ def minmax; end
1116
+ def to_re; end
1117
+
1118
+ private
1119
+
1120
+ # Returns the value of attribute base_max.
1121
+ def base_max; end
1122
+
1123
+ # Sets the attribute base_max
1124
+ #
1125
+ # @param value the value to set the attribute base_max to.
1126
+ def base_max=(_arg0); end
1127
+
1128
+ # Returns the value of attribute base_min.
1129
+ def base_min; end
1130
+
1131
+ # Sets the attribute base_min
1132
+ #
1133
+ # @param value the value to set the attribute base_min to.
1134
+ def base_min=(_arg0); end
1135
+
1136
+ # Returns the value of attribute exp_class.
1137
+ def exp_class; end
1138
+
1139
+ # Sets the attribute exp_class
1140
+ #
1141
+ # @param value the value to set the attribute exp_class to.
1142
+ def exp_class=(_arg0); end
1143
+
1144
+ # Returns the value of attribute max_rep.
1145
+ def max_rep; end
1146
+
1147
+ # Sets the attribute max_rep
1148
+ #
1149
+ # @param value the value to set the attribute max_rep to.
1150
+ def max_rep=(_arg0); end
1151
+
1152
+ # Returns the value of attribute min_rep.
1153
+ def min_rep; end
1154
+
1155
+ # Sets the attribute min_rep
1156
+ #
1157
+ # @param value the value to set the attribute min_rep to.
1158
+ def min_rep=(_arg0); end
1159
+
1160
+ # Returns the value of attribute reify.
1161
+ def reify; end
1162
+
1163
+ # Sets the attribute reify
1164
+ #
1165
+ # @param value the value to set the attribute reify to.
1166
+ def reify=(_arg0); end
1167
+
1168
+ def test_regexp; end
1169
+
1170
+ class << self
1171
+ def of(obj); end
1172
+ end
1173
+ end
1174
+
1175
+ class Regexp::Parser
1176
+ include ::Regexp::Expression
1177
+ include ::Regexp::Expression::UnicodeProperty
1178
+
1179
+ def parse(input, syntax = T.unsafe(nil), options: T.unsafe(nil), &block); end
1180
+
1181
+ private
1182
+
1183
+ def active_opts; end
1184
+ def anchor(token); end
1185
+ def assign_effective_number(exp); end
1186
+
1187
+ # Assigns referenced expressions to refering expressions, e.g. if there is
1188
+ # an instance of Backreference::Number, its #referenced_expression is set to
1189
+ # the instance of Group::Capture that it refers to via its number.
1190
+ def assign_referenced_expressions; end
1191
+
1192
+ def backref(token); end
1193
+ def captured_group_count_at_level; end
1194
+
1195
+ # Returns the value of attribute captured_group_counts.
1196
+ def captured_group_counts; end
1197
+
1198
+ # Sets the attribute captured_group_counts
1199
+ #
1200
+ # @param value the value to set the attribute captured_group_counts to.
1201
+ def captured_group_counts=(_arg0); end
1202
+
1203
+ def close_completed_character_set_range; end
1204
+ def close_group; end
1205
+ def close_set; end
1206
+ def conditional(token); end
1207
+
1208
+ # Returns the value of attribute conditional_nesting.
1209
+ def conditional_nesting; end
1210
+
1211
+ # Sets the attribute conditional_nesting
1212
+ #
1213
+ # @param value the value to set the attribute conditional_nesting to.
1214
+ def conditional_nesting=(_arg0); end
1215
+
1216
+ def count_captured_group; end
1217
+
1218
+ # @yield [node]
1219
+ def decrease_nesting; end
1220
+
1221
+ def escape(token); end
1222
+ def extract_options(input, options); end
1223
+ def free_space(token); end
1224
+ def group(token); end
1225
+ def increase_group_level(exp); end
1226
+ def intersection(token); end
1227
+ def keep(token); end
1228
+ def literal(token); end
1229
+ def meta(token); end
1230
+ def negate_set; end
1231
+ def nest(exp); end
1232
+ def nest_conditional(exp); end
1233
+
1234
+ # Returns the value of attribute nesting.
1235
+ def nesting; end
1236
+
1237
+ # Sets the attribute nesting
1238
+ #
1239
+ # @param value the value to set the attribute nesting to.
1240
+ def nesting=(_arg0); end
1241
+
1242
+ # Returns the value of attribute node.
1243
+ def node; end
1244
+
1245
+ # Sets the attribute node
1246
+ #
1247
+ # @param value the value to set the attribute node to.
1248
+ def node=(_arg0); end
1249
+
1250
+ def open_group(token); end
1251
+ def open_set(token); end
1252
+ def options_group(token); end
1253
+
1254
+ # Returns the value of attribute options_stack.
1255
+ def options_stack; end
1256
+
1257
+ # Sets the attribute options_stack
1258
+ #
1259
+ # @param value the value to set the attribute options_stack to.
1260
+ def options_stack=(_arg0); end
1261
+
1262
+ def parse_token(token); end
1263
+ def posixclass(token); end
1264
+ def property(token); end
1265
+ def quantifier(token); end
1266
+ def range(token); end
1267
+
1268
+ # Returns the value of attribute root.
1269
+ def root; end
1270
+
1271
+ # Sets the attribute root
1272
+ #
1273
+ # @param value the value to set the attribute root to.
1274
+ def root=(_arg0); end
1275
+
1276
+ def sequence_operation(klass, token); end
1277
+ def set(token); end
1278
+
1279
+ # Returns the value of attribute switching_options.
1280
+ def switching_options; end
1281
+
1282
+ # Sets the attribute switching_options
1283
+ #
1284
+ # @param value the value to set the attribute switching_options to.
1285
+ def switching_options=(_arg0); end
1286
+
1287
+ def total_captured_group_count; end
1288
+ def type(token); end
1289
+
1290
+ class << self
1291
+ def parse(input, syntax = T.unsafe(nil), options: T.unsafe(nil), &block); end
1292
+ end
1293
+ end
1294
+
1295
+ Regexp::Parser::ENC_FLAGS = T.let(T.unsafe(nil), Array)
1296
+
1297
+ # base class for all gem-specific errors
1298
+ class Regexp::Parser::Error < ::StandardError; end
1299
+
1300
+ Regexp::Parser::MOD_FLAGS = T.let(T.unsafe(nil), Array)
1301
+ class Regexp::Parser::ParserError < ::Regexp::Parser::Error; end
1302
+ Regexp::Parser::UPTokens = Regexp::Syntax::Token::UnicodeProperty
1303
+
1304
+ class Regexp::Parser::UnknownTokenError < ::Regexp::Parser::ParserError
1305
+ # @return [UnknownTokenError] a new instance of UnknownTokenError
1306
+ def initialize(type, token); end
1307
+ end
1308
+
1309
+ class Regexp::Parser::UnknownTokenTypeError < ::Regexp::Parser::ParserError
1310
+ # @return [UnknownTokenTypeError] a new instance of UnknownTokenTypeError
1311
+ def initialize(type, token); end
1312
+ end
1313
+
1314
+ Regexp::Parser::VERSION = T.let(T.unsafe(nil), String)
1315
+
1316
+ class Regexp::Scanner
1317
+ # Emits an array with the details of the scanned pattern
1318
+ def emit(type, token, text); end
1319
+
1320
+ # @raise [PrematureEndError]
1321
+ def scan(input_object, options: T.unsafe(nil), &block); end
1322
+
1323
+ private
1324
+
1325
+ # Appends one or more characters to the literal buffer, to be emitted later
1326
+ # by a call to emit_literal.
1327
+ def append_literal(data, ts, te); end
1328
+
1329
+ # Returns the value of attribute block.
1330
+ def block; end
1331
+
1332
+ # Sets the attribute block
1333
+ #
1334
+ # @param value the value to set the attribute block to.
1335
+ def block=(_arg0); end
1336
+
1337
+ # Returns the value of attribute char_pos.
1338
+ def char_pos; end
1339
+
1340
+ # Sets the attribute char_pos
1341
+ #
1342
+ # @param value the value to set the attribute char_pos to.
1343
+ def char_pos=(_arg0); end
1344
+
1345
+ # Returns the value of attribute conditional_stack.
1346
+ def conditional_stack; end
1347
+
1348
+ # Sets the attribute conditional_stack
1349
+ #
1350
+ # @param value the value to set the attribute conditional_stack to.
1351
+ def conditional_stack=(_arg0); end
1352
+
1353
+ # Copy from ts to te from data as text
1354
+ def copy(data, ts, te); end
1355
+
1356
+ # Emits the literal run collected by calls to the append_literal method.
1357
+ def emit_literal; end
1358
+
1359
+ def emit_meta_control_sequence(data, ts, te, token); end
1360
+ def emit_options(text); end
1361
+
1362
+ # Returns the value of attribute free_spacing.
1363
+ def free_spacing; end
1364
+
1365
+ # Sets the attribute free_spacing
1366
+ #
1367
+ # @param value the value to set the attribute free_spacing to.
1368
+ def free_spacing=(_arg0); end
1369
+
1370
+ # @return [Boolean]
1371
+ def free_spacing?(input_object, options); end
1372
+
1373
+ # Returns the value of attribute group_depth.
1374
+ def group_depth; end
1375
+
1376
+ # Sets the attribute group_depth
1377
+ #
1378
+ # @param value the value to set the attribute group_depth to.
1379
+ def group_depth=(_arg0); end
1380
+
1381
+ # @return [Boolean]
1382
+ def in_group?; end
1383
+
1384
+ # @return [Boolean]
1385
+ def in_set?; end
1386
+
1387
+ # Returns the value of attribute literal.
1388
+ def literal; end
1389
+
1390
+ # Sets the attribute literal
1391
+ #
1392
+ # @param value the value to set the attribute literal to.
1393
+ def literal=(_arg0); end
1394
+
1395
+ # Returns the value of attribute set_depth.
1396
+ def set_depth; end
1397
+
1398
+ # Sets the attribute set_depth
1399
+ #
1400
+ # @param value the value to set the attribute set_depth to.
1401
+ def set_depth=(_arg0); end
1402
+
1403
+ # Returns the value of attribute spacing_stack.
1404
+ def spacing_stack; end
1405
+
1406
+ # Sets the attribute spacing_stack
1407
+ #
1408
+ # @param value the value to set the attribute spacing_stack to.
1409
+ def spacing_stack=(_arg0); end
1410
+
1411
+ # Returns the value of attribute tokens.
1412
+ def tokens; end
1413
+
1414
+ # Sets the attribute tokens
1415
+ #
1416
+ # @param value the value to set the attribute tokens to.
1417
+ def tokens=(_arg0); end
1418
+
1419
+ # Centralizes and unifies the handling of validation related
1420
+ # errors.
1421
+ def validation_error(type, what, reason = T.unsafe(nil)); end
1422
+
1423
+ class << self
1424
+ def long_prop_map; end
1425
+ def parse_prop_map(name); end
1426
+ def posix_classes; end
1427
+
1428
+ # Scans the given regular expression text, or Regexp object and collects the
1429
+ # emitted token into an array that gets returned at the end. If a block is
1430
+ # given, it gets called for each emitted token.
1431
+ #
1432
+ # This method may raise errors if a syntax error is encountered.
1433
+ # --------------------------------------------------------------------------
1434
+ def scan(input_object, options: T.unsafe(nil), &block); end
1435
+
1436
+ # lazy-load property maps when first needed
1437
+ def short_prop_map; end
1438
+ end
1439
+ end
1440
+
1441
+ # Invalid back reference. Used for name a number refs/calls.
1442
+ class Regexp::Scanner::InvalidBackrefError < ::Regexp::Scanner::ValidationError
1443
+ # @return [InvalidBackrefError] a new instance of InvalidBackrefError
1444
+ def initialize(what, reason); end
1445
+ end
1446
+
1447
+ # Invalid group. Used for named groups.
1448
+ class Regexp::Scanner::InvalidGroupError < ::Regexp::Scanner::ValidationError
1449
+ # @return [InvalidGroupError] a new instance of InvalidGroupError
1450
+ def initialize(what, reason); end
1451
+ end
1452
+
1453
+ # Invalid groupOption. Used for inline options.
1454
+ # TODO: should become InvalidGroupOptionError in v3.0.0 for consistency
1455
+ class Regexp::Scanner::InvalidGroupOption < ::Regexp::Scanner::ValidationError
1456
+ # @return [InvalidGroupOption] a new instance of InvalidGroupOption
1457
+ def initialize(option, text); end
1458
+ end
1459
+
1460
+ # Invalid sequence format. Used for escape sequences, mainly.
1461
+ class Regexp::Scanner::InvalidSequenceError < ::Regexp::Scanner::ValidationError
1462
+ # @return [InvalidSequenceError] a new instance of InvalidSequenceError
1463
+ def initialize(what = T.unsafe(nil), where = T.unsafe(nil)); end
1464
+ end
1465
+
1466
+ # Unexpected end of pattern
1467
+ class Regexp::Scanner::PrematureEndError < ::Regexp::Scanner::ScannerError
1468
+ # @return [PrematureEndError] a new instance of PrematureEndError
1469
+ def initialize(where = T.unsafe(nil)); end
1470
+ end
1471
+
1472
+ # General scanner error (catch all)
1473
+ class Regexp::Scanner::ScannerError < ::Regexp::Parser::Error; end
1474
+
1475
+ # The POSIX class name was not recognized by the scanner.
1476
+ class Regexp::Scanner::UnknownPosixClassError < ::Regexp::Scanner::ValidationError
1477
+ # @return [UnknownPosixClassError] a new instance of UnknownPosixClassError
1478
+ def initialize(text); end
1479
+ end
1480
+
1481
+ # The property name was not recognized by the scanner.
1482
+ class Regexp::Scanner::UnknownUnicodePropertyError < ::Regexp::Scanner::ValidationError
1483
+ # @return [UnknownUnicodePropertyError] a new instance of UnknownUnicodePropertyError
1484
+ def initialize(name); end
1485
+ end
1486
+
1487
+ # Base for all scanner validation errors
1488
+ class Regexp::Scanner::ValidationError < ::Regexp::Parser::Error
1489
+ # @return [ValidationError] a new instance of ValidationError
1490
+ def initialize(reason); end
1491
+ end
1492
+
1493
+ # After loading all the tokens the map is full. Extract all tokens and types
1494
+ # into the All and Types constants.
1495
+ module Regexp::Syntax
1496
+ private
1497
+
1498
+ def comparable(name); end
1499
+ def const_missing(const_name); end
1500
+ def fallback_version_class(version); end
1501
+
1502
+ # Returns the syntax specification class for the given syntax
1503
+ # version name. The special names 'any' and '*' return Syntax::Any.
1504
+ def for(name); end
1505
+
1506
+ def new(name); end
1507
+ def specified_versions; end
1508
+ def supported?(name); end
1509
+ def version_class(version); end
1510
+ def warn_if_future_version(const_name); end
1511
+
1512
+ class << self
1513
+ def comparable(name); end
1514
+ def const_missing(const_name); end
1515
+ def fallback_version_class(version); end
1516
+
1517
+ # Returns the syntax specification class for the given syntax
1518
+ # version name. The special names 'any' and '*' return Syntax::Any.
1519
+ def for(name); end
1520
+
1521
+ def new(name); end
1522
+ def specified_versions; end
1523
+
1524
+ # @return [Boolean]
1525
+ def supported?(name); end
1526
+
1527
+ def version_class(version); end
1528
+ def warn_if_future_version(const_name); end
1529
+ end
1530
+ end
1531
+
1532
+ # A syntax that always returns true, passing all tokens as implemented. This
1533
+ # is useful during development, testing, and should be useful for some types
1534
+ # of transformations as well.
1535
+ class Regexp::Syntax::Any < ::Regexp::Syntax::Base
1536
+ class << self
1537
+ # @return [Boolean]
1538
+ def implements?(_type, _token); end
1539
+ end
1540
+ end
1541
+
1542
+ # A lookup map of supported types and tokens in a given syntax
1543
+ class Regexp::Syntax::Base
1544
+ include ::Regexp::Syntax::Token
1545
+
1546
+ # TODO: drop this backwards compatibility code in v3.0.0, do `private :new`
1547
+ #
1548
+ # @return [Base] a new instance of Base
1549
+ def initialize; end
1550
+
1551
+ def method_missing(name, *args); end
1552
+
1553
+ private
1554
+
1555
+ # @return [Boolean]
1556
+ def respond_to_missing?(name, include_private = T.unsafe(nil)); end
1557
+
1558
+ class << self
1559
+ def added_features; end
1560
+
1561
+ # @raise [NotImplementedError]
1562
+ def check!(type, token); end
1563
+
1564
+ # @return [Boolean]
1565
+ def check?(type, token); end
1566
+
1567
+ def excludes(type, tokens); end
1568
+
1569
+ # Returns the value of attribute features.
1570
+ def features; end
1571
+
1572
+ # Sets the attribute features
1573
+ #
1574
+ # @param value the value to set the attribute features to.
1575
+ def features=(_arg0); end
1576
+
1577
+ def implementations(type); end
1578
+ def implements(type, tokens); end
1579
+
1580
+ # @raise [NotImplementedError]
1581
+ def implements!(type, token); end
1582
+
1583
+ # @return [Boolean]
1584
+ def implements?(type, token); end
1585
+
1586
+ # automatically inherit features through the syntax class hierarchy
1587
+ def inherited(subclass); end
1588
+
1589
+ def normalize(type, token); end
1590
+ def normalize_backref(type, token); end
1591
+ def normalize_group(type, token); end
1592
+ def removed_features; end
1593
+ end
1594
+ end
1595
+
1596
+ class Regexp::Syntax::InvalidVersionNameError < ::Regexp::Syntax::SyntaxError
1597
+ # @return [InvalidVersionNameError] a new instance of InvalidVersionNameError
1598
+ def initialize(name); end
1599
+ end
1600
+
1601
+ class Regexp::Syntax::NotImplementedError < ::Regexp::Syntax::SyntaxError
1602
+ # @return [NotImplementedError] a new instance of NotImplementedError
1603
+ def initialize(syntax, type, token); end
1604
+ end
1605
+
1606
+ class Regexp::Syntax::SyntaxError < ::Regexp::Parser::Error; end
1607
+ module Regexp::Syntax::Token; end
1608
+ Regexp::Syntax::Token::All = T.let(T.unsafe(nil), Array)
1609
+ module Regexp::Syntax::Token::Anchor; end
1610
+ Regexp::Syntax::Token::Anchor::All = T.let(T.unsafe(nil), Array)
1611
+ Regexp::Syntax::Token::Anchor::Basic = T.let(T.unsafe(nil), Array)
1612
+ Regexp::Syntax::Token::Anchor::Extended = T.let(T.unsafe(nil), Array)
1613
+ Regexp::Syntax::Token::Anchor::MatchStart = T.let(T.unsafe(nil), Array)
1614
+ Regexp::Syntax::Token::Anchor::String = T.let(T.unsafe(nil), Array)
1615
+ Regexp::Syntax::Token::Anchor::Type = T.let(T.unsafe(nil), Symbol)
1616
+ module Regexp::Syntax::Token::Assertion; end
1617
+ Regexp::Syntax::Token::Assertion::All = T.let(T.unsafe(nil), Array)
1618
+ Regexp::Syntax::Token::Assertion::Lookahead = T.let(T.unsafe(nil), Array)
1619
+ Regexp::Syntax::Token::Assertion::Lookbehind = T.let(T.unsafe(nil), Array)
1620
+ Regexp::Syntax::Token::Assertion::Type = T.let(T.unsafe(nil), Symbol)
1621
+ module Regexp::Syntax::Token::Backreference; end
1622
+ Regexp::Syntax::Token::Backreference::All = T.let(T.unsafe(nil), Array)
1623
+ Regexp::Syntax::Token::Backreference::Name = T.let(T.unsafe(nil), Array)
1624
+ Regexp::Syntax::Token::Backreference::Number = T.let(T.unsafe(nil), Array)
1625
+ Regexp::Syntax::Token::Backreference::NumberRef = T.let(T.unsafe(nil), Array)
1626
+ Regexp::Syntax::Token::Backreference::Plain = T.let(T.unsafe(nil), Array)
1627
+ Regexp::Syntax::Token::Backreference::RecursionLevel = T.let(T.unsafe(nil), Array)
1628
+ Regexp::Syntax::Token::Backreference::Type = T.let(T.unsafe(nil), Symbol)
1629
+ Regexp::Syntax::Token::Backreference::V1_8_6 = T.let(T.unsafe(nil), Array)
1630
+ Regexp::Syntax::Token::Backreference::V1_9_1 = T.let(T.unsafe(nil), Array)
1631
+ module Regexp::Syntax::Token::CharacterSet; end
1632
+ Regexp::Syntax::Token::CharacterSet::All = T.let(T.unsafe(nil), Array)
1633
+ Regexp::Syntax::Token::CharacterSet::Basic = T.let(T.unsafe(nil), Array)
1634
+ Regexp::Syntax::Token::CharacterSet::Extended = T.let(T.unsafe(nil), Array)
1635
+ Regexp::Syntax::Token::CharacterSet::Type = T.let(T.unsafe(nil), Symbol)
1636
+ module Regexp::Syntax::Token::CharacterType; end
1637
+ Regexp::Syntax::Token::CharacterType::All = T.let(T.unsafe(nil), Array)
1638
+ Regexp::Syntax::Token::CharacterType::Basic = T.let(T.unsafe(nil), Array)
1639
+ Regexp::Syntax::Token::CharacterType::Clustered = T.let(T.unsafe(nil), Array)
1640
+ Regexp::Syntax::Token::CharacterType::Extended = T.let(T.unsafe(nil), Array)
1641
+ Regexp::Syntax::Token::CharacterType::Hex = T.let(T.unsafe(nil), Array)
1642
+ Regexp::Syntax::Token::CharacterType::Type = T.let(T.unsafe(nil), Symbol)
1643
+ module Regexp::Syntax::Token::Conditional; end
1644
+ Regexp::Syntax::Token::Conditional::All = T.let(T.unsafe(nil), Array)
1645
+ Regexp::Syntax::Token::Conditional::Condition = T.let(T.unsafe(nil), Array)
1646
+ Regexp::Syntax::Token::Conditional::Delimiters = T.let(T.unsafe(nil), Array)
1647
+ Regexp::Syntax::Token::Conditional::Separator = T.let(T.unsafe(nil), Array)
1648
+ Regexp::Syntax::Token::Conditional::Type = T.let(T.unsafe(nil), Symbol)
1649
+
1650
+ # TODO: unify naming with RE::EscapeSequence, one way or the other, in v3.0.0
1651
+ module Regexp::Syntax::Token::Escape; end
1652
+
1653
+ Regexp::Syntax::Token::Escape::ASCII = T.let(T.unsafe(nil), Array)
1654
+ Regexp::Syntax::Token::Escape::All = T.let(T.unsafe(nil), Array)
1655
+ Regexp::Syntax::Token::Escape::Basic = T.let(T.unsafe(nil), Array)
1656
+ Regexp::Syntax::Token::Escape::Control = T.let(T.unsafe(nil), Array)
1657
+ Regexp::Syntax::Token::Escape::Hex = T.let(T.unsafe(nil), Array)
1658
+ Regexp::Syntax::Token::Escape::Meta = T.let(T.unsafe(nil), Array)
1659
+ Regexp::Syntax::Token::Escape::Octal = T.let(T.unsafe(nil), Array)
1660
+ Regexp::Syntax::Token::Escape::Type = T.let(T.unsafe(nil), Symbol)
1661
+ Regexp::Syntax::Token::Escape::Unicode = T.let(T.unsafe(nil), Array)
1662
+ module Regexp::Syntax::Token::FreeSpace; end
1663
+ Regexp::Syntax::Token::FreeSpace::All = T.let(T.unsafe(nil), Array)
1664
+ Regexp::Syntax::Token::FreeSpace::Type = T.let(T.unsafe(nil), Symbol)
1665
+ module Regexp::Syntax::Token::Group; end
1666
+ Regexp::Syntax::Token::Group::All = T.let(T.unsafe(nil), Array)
1667
+ Regexp::Syntax::Token::Group::Atomic = T.let(T.unsafe(nil), Array)
1668
+ Regexp::Syntax::Token::Group::Basic = T.let(T.unsafe(nil), Array)
1669
+ Regexp::Syntax::Token::Group::Comment = T.let(T.unsafe(nil), Array)
1670
+ Regexp::Syntax::Token::Group::Extended = T.let(T.unsafe(nil), Array)
1671
+ Regexp::Syntax::Token::Group::Named = T.let(T.unsafe(nil), Array)
1672
+ Regexp::Syntax::Token::Group::Passive = T.let(T.unsafe(nil), Array)
1673
+ Regexp::Syntax::Token::Group::Type = T.let(T.unsafe(nil), Symbol)
1674
+ Regexp::Syntax::Token::Group::V1_8_6 = T.let(T.unsafe(nil), Array)
1675
+ Regexp::Syntax::Token::Group::V2_4_1 = T.let(T.unsafe(nil), Array)
1676
+ module Regexp::Syntax::Token::Keep; end
1677
+ Regexp::Syntax::Token::Keep::All = T.let(T.unsafe(nil), Array)
1678
+ Regexp::Syntax::Token::Keep::Mark = T.let(T.unsafe(nil), Array)
1679
+ Regexp::Syntax::Token::Keep::Type = T.let(T.unsafe(nil), Symbol)
1680
+ module Regexp::Syntax::Token::Literal; end
1681
+ Regexp::Syntax::Token::Literal::All = T.let(T.unsafe(nil), Array)
1682
+ Regexp::Syntax::Token::Literal::Type = T.let(T.unsafe(nil), Symbol)
1683
+ Regexp::Syntax::Token::Map = T.let(T.unsafe(nil), Hash)
1684
+ module Regexp::Syntax::Token::Meta; end
1685
+ Regexp::Syntax::Token::Meta::All = T.let(T.unsafe(nil), Array)
1686
+ Regexp::Syntax::Token::Meta::Basic = T.let(T.unsafe(nil), Array)
1687
+ Regexp::Syntax::Token::Meta::Extended = T.let(T.unsafe(nil), Array)
1688
+ Regexp::Syntax::Token::Meta::Type = T.let(T.unsafe(nil), Symbol)
1689
+ module Regexp::Syntax::Token::PosixClass; end
1690
+ Regexp::Syntax::Token::PosixClass::All = T.let(T.unsafe(nil), Array)
1691
+ Regexp::Syntax::Token::PosixClass::Extensions = T.let(T.unsafe(nil), Array)
1692
+ Regexp::Syntax::Token::PosixClass::NonType = T.let(T.unsafe(nil), Symbol)
1693
+ Regexp::Syntax::Token::PosixClass::Standard = T.let(T.unsafe(nil), Array)
1694
+ Regexp::Syntax::Token::PosixClass::Type = T.let(T.unsafe(nil), Symbol)
1695
+ module Regexp::Syntax::Token::Quantifier; end
1696
+ Regexp::Syntax::Token::Quantifier::All = T.let(T.unsafe(nil), Array)
1697
+ Regexp::Syntax::Token::Quantifier::Greedy = T.let(T.unsafe(nil), Array)
1698
+ Regexp::Syntax::Token::Quantifier::Interval = T.let(T.unsafe(nil), Array)
1699
+ Regexp::Syntax::Token::Quantifier::IntervalAll = T.let(T.unsafe(nil), Array)
1700
+ Regexp::Syntax::Token::Quantifier::IntervalPossessive = T.let(T.unsafe(nil), Array)
1701
+ Regexp::Syntax::Token::Quantifier::IntervalReluctant = T.let(T.unsafe(nil), Array)
1702
+ Regexp::Syntax::Token::Quantifier::Possessive = T.let(T.unsafe(nil), Array)
1703
+ Regexp::Syntax::Token::Quantifier::Reluctant = T.let(T.unsafe(nil), Array)
1704
+ Regexp::Syntax::Token::Quantifier::Type = T.let(T.unsafe(nil), Symbol)
1705
+ Regexp::Syntax::Token::Quantifier::V1_8_6 = T.let(T.unsafe(nil), Array)
1706
+
1707
+ # Type is the same as Backreference so keeping it here, for now.
1708
+ module Regexp::Syntax::Token::SubexpressionCall; end
1709
+
1710
+ Regexp::Syntax::Token::SubexpressionCall::All = T.let(T.unsafe(nil), Array)
1711
+ Regexp::Syntax::Token::SubexpressionCall::Name = T.let(T.unsafe(nil), Array)
1712
+ Regexp::Syntax::Token::SubexpressionCall::Number = T.let(T.unsafe(nil), Array)
1713
+ Regexp::Syntax::Token::Types = T.let(T.unsafe(nil), Array)
1714
+ module Regexp::Syntax::Token::UnicodeProperty; end
1715
+ Regexp::Syntax::Token::UnicodeProperty::Age = T.let(T.unsafe(nil), Array)
1716
+ Regexp::Syntax::Token::UnicodeProperty::Age_V1_9_3 = T.let(T.unsafe(nil), Array)
1717
+ Regexp::Syntax::Token::UnicodeProperty::Age_V2_0_0 = T.let(T.unsafe(nil), Array)
1718
+ Regexp::Syntax::Token::UnicodeProperty::Age_V2_2_0 = T.let(T.unsafe(nil), Array)
1719
+ Regexp::Syntax::Token::UnicodeProperty::Age_V2_3_0 = T.let(T.unsafe(nil), Array)
1720
+ Regexp::Syntax::Token::UnicodeProperty::Age_V2_4_0 = T.let(T.unsafe(nil), Array)
1721
+ Regexp::Syntax::Token::UnicodeProperty::Age_V2_5_0 = T.let(T.unsafe(nil), Array)
1722
+ Regexp::Syntax::Token::UnicodeProperty::Age_V2_6_0 = T.let(T.unsafe(nil), Array)
1723
+ Regexp::Syntax::Token::UnicodeProperty::Age_V2_6_2 = T.let(T.unsafe(nil), Array)
1724
+ Regexp::Syntax::Token::UnicodeProperty::Age_V2_6_3 = T.let(T.unsafe(nil), Array)
1725
+ Regexp::Syntax::Token::UnicodeProperty::Age_V3_1_0 = T.let(T.unsafe(nil), Array)
1726
+ Regexp::Syntax::Token::UnicodeProperty::Age_V3_2_0 = T.let(T.unsafe(nil), Array)
1727
+ Regexp::Syntax::Token::UnicodeProperty::All = T.let(T.unsafe(nil), Array)
1728
+ module Regexp::Syntax::Token::UnicodeProperty::Category; end
1729
+ Regexp::Syntax::Token::UnicodeProperty::Category::All = T.let(T.unsafe(nil), Array)
1730
+ Regexp::Syntax::Token::UnicodeProperty::Category::Codepoint = T.let(T.unsafe(nil), Array)
1731
+ Regexp::Syntax::Token::UnicodeProperty::Category::Letter = T.let(T.unsafe(nil), Array)
1732
+ Regexp::Syntax::Token::UnicodeProperty::Category::Mark = T.let(T.unsafe(nil), Array)
1733
+ Regexp::Syntax::Token::UnicodeProperty::Category::Number = T.let(T.unsafe(nil), Array)
1734
+ Regexp::Syntax::Token::UnicodeProperty::Category::Punctuation = T.let(T.unsafe(nil), Array)
1735
+ Regexp::Syntax::Token::UnicodeProperty::Category::Separator = T.let(T.unsafe(nil), Array)
1736
+ Regexp::Syntax::Token::UnicodeProperty::Category::Symbol = T.let(T.unsafe(nil), Array)
1737
+ Regexp::Syntax::Token::UnicodeProperty::CharType_V1_9_0 = T.let(T.unsafe(nil), Array)
1738
+ Regexp::Syntax::Token::UnicodeProperty::CharType_V2_5_0 = T.let(T.unsafe(nil), Array)
1739
+ Regexp::Syntax::Token::UnicodeProperty::Derived = T.let(T.unsafe(nil), Array)
1740
+ Regexp::Syntax::Token::UnicodeProperty::Derived_V1_9_0 = T.let(T.unsafe(nil), Array)
1741
+ Regexp::Syntax::Token::UnicodeProperty::Derived_V2_0_0 = T.let(T.unsafe(nil), Array)
1742
+ Regexp::Syntax::Token::UnicodeProperty::Derived_V2_4_0 = T.let(T.unsafe(nil), Array)
1743
+ Regexp::Syntax::Token::UnicodeProperty::Derived_V2_5_0 = T.let(T.unsafe(nil), Array)
1744
+ Regexp::Syntax::Token::UnicodeProperty::Emoji = T.let(T.unsafe(nil), Array)
1745
+ Regexp::Syntax::Token::UnicodeProperty::Emoji_V2_5_0 = T.let(T.unsafe(nil), Array)
1746
+ Regexp::Syntax::Token::UnicodeProperty::NonType = T.let(T.unsafe(nil), Symbol)
1747
+ Regexp::Syntax::Token::UnicodeProperty::POSIX = T.let(T.unsafe(nil), Array)
1748
+ Regexp::Syntax::Token::UnicodeProperty::Script = T.let(T.unsafe(nil), Array)
1749
+ Regexp::Syntax::Token::UnicodeProperty::Script_V1_9_0 = T.let(T.unsafe(nil), Array)
1750
+ Regexp::Syntax::Token::UnicodeProperty::Script_V1_9_3 = T.let(T.unsafe(nil), Array)
1751
+ Regexp::Syntax::Token::UnicodeProperty::Script_V2_0_0 = T.let(T.unsafe(nil), Array)
1752
+ Regexp::Syntax::Token::UnicodeProperty::Script_V2_2_0 = T.let(T.unsafe(nil), Array)
1753
+ Regexp::Syntax::Token::UnicodeProperty::Script_V2_3_0 = T.let(T.unsafe(nil), Array)
1754
+ Regexp::Syntax::Token::UnicodeProperty::Script_V2_4_0 = T.let(T.unsafe(nil), Array)
1755
+ Regexp::Syntax::Token::UnicodeProperty::Script_V2_5_0 = T.let(T.unsafe(nil), Array)
1756
+ Regexp::Syntax::Token::UnicodeProperty::Script_V2_6_0 = T.let(T.unsafe(nil), Array)
1757
+ Regexp::Syntax::Token::UnicodeProperty::Script_V2_6_2 = T.let(T.unsafe(nil), Array)
1758
+ Regexp::Syntax::Token::UnicodeProperty::Script_V3_1_0 = T.let(T.unsafe(nil), Array)
1759
+ Regexp::Syntax::Token::UnicodeProperty::Script_V3_2_0 = T.let(T.unsafe(nil), Array)
1760
+ Regexp::Syntax::Token::UnicodeProperty::Type = T.let(T.unsafe(nil), Symbol)
1761
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock = T.let(T.unsafe(nil), Array)
1762
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V1_9_0 = T.let(T.unsafe(nil), Array)
1763
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V2_0_0 = T.let(T.unsafe(nil), Array)
1764
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V2_2_0 = T.let(T.unsafe(nil), Array)
1765
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V2_3_0 = T.let(T.unsafe(nil), Array)
1766
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V2_4_0 = T.let(T.unsafe(nil), Array)
1767
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V2_5_0 = T.let(T.unsafe(nil), Array)
1768
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V2_6_0 = T.let(T.unsafe(nil), Array)
1769
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V2_6_2 = T.let(T.unsafe(nil), Array)
1770
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V3_1_0 = T.let(T.unsafe(nil), Array)
1771
+ Regexp::Syntax::Token::UnicodeProperty::UnicodeBlock_V3_2_0 = T.let(T.unsafe(nil), Array)
1772
+ Regexp::Syntax::Token::UnicodeProperty::V1_9_0 = T.let(T.unsafe(nil), Array)
1773
+ Regexp::Syntax::Token::UnicodeProperty::V1_9_3 = T.let(T.unsafe(nil), Array)
1774
+ Regexp::Syntax::Token::UnicodeProperty::V2_0_0 = T.let(T.unsafe(nil), Array)
1775
+ Regexp::Syntax::Token::UnicodeProperty::V2_2_0 = T.let(T.unsafe(nil), Array)
1776
+ Regexp::Syntax::Token::UnicodeProperty::V2_3_0 = T.let(T.unsafe(nil), Array)
1777
+ Regexp::Syntax::Token::UnicodeProperty::V2_4_0 = T.let(T.unsafe(nil), Array)
1778
+ Regexp::Syntax::Token::UnicodeProperty::V2_5_0 = T.let(T.unsafe(nil), Array)
1779
+ Regexp::Syntax::Token::UnicodeProperty::V2_6_0 = T.let(T.unsafe(nil), Array)
1780
+ Regexp::Syntax::Token::UnicodeProperty::V2_6_2 = T.let(T.unsafe(nil), Array)
1781
+ Regexp::Syntax::Token::UnicodeProperty::V2_6_3 = T.let(T.unsafe(nil), Array)
1782
+ Regexp::Syntax::Token::UnicodeProperty::V3_1_0 = T.let(T.unsafe(nil), Array)
1783
+ Regexp::Syntax::Token::UnicodeProperty::V3_2_0 = T.let(T.unsafe(nil), Array)
1784
+
1785
+ class Regexp::Syntax::UnknownSyntaxNameError < ::Regexp::Syntax::SyntaxError
1786
+ # @return [UnknownSyntaxNameError] a new instance of UnknownSyntaxNameError
1787
+ def initialize(name); end
1788
+ end
1789
+
1790
+ class Regexp::Syntax::V1_8_6 < ::Regexp::Syntax::Base; end
1791
+ class Regexp::Syntax::V1_9_1 < ::Regexp::Syntax::V1_8_6; end
1792
+ class Regexp::Syntax::V1_9_3 < ::Regexp::Syntax::V1_9_1; end
1793
+ class Regexp::Syntax::V2_0_0 < ::Regexp::Syntax::V1_9_3; end
1794
+ class Regexp::Syntax::V2_2_0 < ::Regexp::Syntax::V2_0_0; end
1795
+ class Regexp::Syntax::V2_3_0 < ::Regexp::Syntax::V2_2_0; end
1796
+ class Regexp::Syntax::V2_4_0 < ::Regexp::Syntax::V2_3_0; end
1797
+ class Regexp::Syntax::V2_4_1 < ::Regexp::Syntax::V2_4_0; end
1798
+ class Regexp::Syntax::V2_5_0 < ::Regexp::Syntax::V2_4_1; end
1799
+ class Regexp::Syntax::V2_6_0 < ::Regexp::Syntax::V2_5_0; end
1800
+ class Regexp::Syntax::V2_6_2 < ::Regexp::Syntax::V2_6_0; end
1801
+ class Regexp::Syntax::V2_6_3 < ::Regexp::Syntax::V2_6_2; end
1802
+ class Regexp::Syntax::V3_1_0 < ::Regexp::Syntax::V2_6_3; end
1803
+ class Regexp::Syntax::V3_2_0 < ::Regexp::Syntax::V3_1_0; end
1804
+ Regexp::Syntax::VERSION_CONST_REGEXP = T.let(T.unsafe(nil), Regexp)
1805
+ Regexp::Syntax::VERSION_FORMAT = T.let(T.unsafe(nil), String)
1806
+ Regexp::Syntax::VERSION_REGEXP = T.let(T.unsafe(nil), Regexp)
1807
+ Regexp::TOKEN_KEYS = T.let(T.unsafe(nil), Array)
1808
+
1809
+ class Regexp::Token < ::Struct
1810
+ def conditional_level; end
1811
+ def conditional_level=(_); end
1812
+ def length; end
1813
+ def level; end
1814
+ def level=(_); end
1815
+
1816
+ # Returns the value of attribute next.
1817
+ def next; end
1818
+
1819
+ # Sets the attribute next
1820
+ #
1821
+ # @param value the value to set the attribute next to.
1822
+ def next=(_arg0); end
1823
+
1824
+ def offset; end
1825
+
1826
+ # Returns the value of attribute previous.
1827
+ def previous; end
1828
+
1829
+ # Sets the attribute previous
1830
+ #
1831
+ # @param value the value to set the attribute previous to.
1832
+ def previous=(_arg0); end
1833
+
1834
+ def set_level; end
1835
+ def set_level=(_); end
1836
+ def te; end
1837
+ def te=(_); end
1838
+ def text; end
1839
+ def text=(_); end
1840
+ def token; end
1841
+ def token=(_); end
1842
+ def ts; end
1843
+ def ts=(_); end
1844
+ def type; end
1845
+ def type=(_); end
1846
+
1847
+ class << self
1848
+ def [](*_arg0); end
1849
+ def inspect; end
1850
+ def keyword_init?; end
1851
+ def members; end
1852
+ def new(*_arg0); end
1853
+ end
1854
+ end