roast-ai 1.0.2 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.claude/commands/docs/write-comments.md +1 -1
- data/.rubocop.yml +12 -1
- data/Gemfile +2 -2
- data/Gemfile.lock +149 -34
- data/README.md +56 -3
- data/examples/agent_with_multiple_prompts.rb +27 -0
- data/examples/custom_logging.rb +4 -2
- data/examples/demo/Gemfile.lock +49 -15
- data/examples/plugin-gem-example/Gemfile.lock +19 -15
- data/examples/simple_chat.rb +1 -1
- data/examples/simple_pi_agent.rb +18 -0
- data/internal/rubocop/cop/roast/no_test_class_nesting.rb +126 -0
- data/internal/rubocop/rubocop-roast.yml +6 -0
- data/internal/workflows/maintenance/branch_docs_impact.rb +97 -0
- data/internal/workflows/maintenance/deprecated_models_docs_updater.rb +78 -0
- data/lib/roast/cog/config.rb +1 -1
- data/lib/roast/cog/output.rb +2 -1
- data/lib/roast/cog/registry.rb +3 -3
- data/lib/roast/cog_input_manager.rb +28 -7
- data/lib/roast/cogs/agent/config.rb +2 -2
- data/lib/roast/cogs/agent/input.rb +20 -22
- data/lib/roast/cogs/agent/providers/claude/claude_invocation.rb +13 -5
- data/lib/roast/cogs/agent/providers/claude/messages/result_message.rb +1 -1
- data/lib/roast/cogs/agent/providers/claude/tool_result.rb +344 -4
- data/lib/roast/cogs/agent/providers/claude/tool_use.rb +356 -1
- data/lib/roast/cogs/agent/providers/claude.rb +16 -3
- data/lib/roast/cogs/agent/providers/pi/messages/tool_call_message.rb +60 -0
- data/lib/roast/cogs/agent/providers/pi/messages/tool_result_message.rb +57 -0
- data/lib/roast/cogs/agent/providers/pi/pi_invocation.rb +352 -0
- data/lib/roast/cogs/agent/providers/pi.rb +41 -0
- data/lib/roast/cogs/agent/stats.rb +29 -0
- data/lib/roast/cogs/agent/usage.rb +22 -0
- data/lib/roast/cogs/agent.rb +5 -6
- data/lib/roast/cogs/chat/config.rb +28 -2
- data/lib/roast/cogs/chat.rb +82 -10
- data/lib/roast/event.rb +1 -0
- data/lib/roast/event_monitor.rb +35 -3
- data/lib/roast/log.rb +21 -0
- data/lib/roast/log_formatter.rb +9 -7
- data/lib/roast/version.rb +1 -1
- data/lib/roast.rb +1 -3
- data/roast-ai.gemspec +2 -1
- data/sorbet/rbi/gems/activesupport@8.0.2.rbi +549 -383
- data/sorbet/rbi/gems/addressable@2.8.7.rbi +46 -44
- data/sorbet/rbi/gems/ast@2.4.3.rbi +7 -6
- data/sorbet/rbi/gems/async@2.34.0.rbi +21 -3
- data/sorbet/rbi/gems/benchmark@0.4.1.rbi +7 -7
- data/sorbet/rbi/gems/bigdecimal@3.2.2.rbi +198 -1
- data/sorbet/rbi/gems/concurrent-ruby@1.3.5.rbi +405 -328
- data/sorbet/rbi/gems/console@1.34.2.rbi +2 -2
- data/sorbet/rbi/gems/docile@1.4.1.rbi +30 -30
- data/sorbet/rbi/gems/drb@2.2.3.rbi +25 -25
- data/sorbet/rbi/gems/erubi@1.13.1.rbi +2 -0
- data/sorbet/rbi/gems/faraday-net_http@3.4.2.rbi +2 -77
- data/sorbet/rbi/gems/faraday-retry@2.3.2.rbi +2 -57
- data/sorbet/rbi/gems/faraday@2.14.1.rbi +382 -75
- data/sorbet/rbi/gems/guard-compat@1.2.1.rbi +1 -110
- data/sorbet/rbi/gems/guard-minitest@2.4.6.rbi +0 -139
- data/sorbet/rbi/gems/guard@2.19.1.rbi +38 -38
- data/sorbet/rbi/gems/hashdiff@1.2.0.rbi +3 -3
- data/sorbet/rbi/gems/i18n@1.14.7.rbi +53 -29
- data/sorbet/rbi/gems/io-event@1.14.0.rbi +67 -10
- data/sorbet/rbi/gems/json@2.18.1.rbi +227 -5
- data/sorbet/rbi/gems/lint_roller@1.1.0.rbi +83 -0
- data/sorbet/rbi/gems/listen@3.9.0.rbi +7 -7
- data/sorbet/rbi/gems/logger@1.7.0.rbi +3 -3
- data/sorbet/rbi/gems/lumberjack@1.2.10.rbi +21 -21
- data/sorbet/rbi/gems/marcel@1.1.0.rbi +1 -1
- data/sorbet/rbi/gems/minitest-rg@5.3.0.rbi +0 -96
- data/sorbet/rbi/gems/minitest@5.25.5.rbi +1 -16
- data/sorbet/rbi/gems/net-http@0.9.1.rbi +27 -19
- data/sorbet/rbi/gems/netrc@0.11.0.rbi +18 -0
- data/sorbet/rbi/gems/notiffany@0.1.3.rbi +20 -20
- data/sorbet/rbi/gems/ostruct@0.6.2.rbi +149 -15
- data/sorbet/rbi/gems/parser@3.3.8.0.rbi +141 -139
- data/sorbet/rbi/gems/prism@1.4.0.rbi +922 -864
- data/sorbet/rbi/gems/public_suffix@6.0.2.rbi +56 -35
- data/sorbet/rbi/gems/racc@1.8.1.rbi +10 -2
- data/sorbet/rbi/gems/rainbow@3.1.1.rbi +12 -12
- data/sorbet/rbi/gems/rake@13.3.0.rbi +219 -318
- data/sorbet/rbi/gems/{rbi@0.3.6.rbi → rbi@0.3.9.rbi} +612 -2267
- data/sorbet/rbi/gems/{rbs@3.9.4.rbi → rbs@4.0.0.dev.5.rbi} +2013 -680
- data/sorbet/rbi/gems/regexp_parser@2.10.0.rbi +151 -113
- data/sorbet/rbi/gems/require-hooks@0.2.3.rbi +110 -0
- data/sorbet/rbi/gems/rexml@3.4.2.rbi +24 -51
- data/sorbet/rbi/gems/rubocop-ast@1.45.1.rbi +506 -815
- data/sorbet/rbi/gems/rubocop-sorbet@0.10.5.rbi +16 -16
- data/sorbet/rbi/gems/rubocop@1.77.0.rbi +2692 -2327
- data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +8 -8
- data/sorbet/rbi/gems/ruby_llm@1.8.2.rbi +38 -23
- data/sorbet/rbi/gems/securerandom@0.4.1.rbi +1 -1
- data/sorbet/rbi/gems/simplecov-html@0.13.2.rbi +2 -131
- data/sorbet/rbi/gems/simplecov@0.22.0.rbi +28 -127
- data/sorbet/rbi/gems/{spoom@1.6.3.rbi → spoom@1.7.11.rbi} +1139 -2246
- data/sorbet/rbi/gems/sqlite3@2.9.0.rbi +91 -1
- data/sorbet/rbi/gems/{tapioca@0.16.11.rbi → tapioca@0.17.10.rbi} +721 -835
- data/sorbet/rbi/gems/thor@1.4.0.rbi +53 -53
- data/sorbet/rbi/gems/tsort@0.2.0.rbi +393 -0
- data/sorbet/rbi/gems/type_toolkit@0.0.5.rbi +49 -0
- data/sorbet/rbi/gems/tzinfo@2.0.6.rbi +144 -143
- data/sorbet/rbi/gems/uri@1.1.1.rbi +7 -7
- data/sorbet/rbi/gems/vcr@6.3.1.rbi +53 -36
- data/sorbet/rbi/gems/webmock@3.25.1.rbi +38 -13
- data/sorbet/rbi/gems/zeitwerk@2.7.3.rbi +39 -272
- data/sorbet/rbi/shims/lib/roast/execution_context.rbi +3 -3
- data/tutorial/01_your_first_workflow/README.md +9 -5
- data/tutorial/01_your_first_workflow/configured_chat.rb +1 -1
- data/tutorial/02_chaining_cogs/README.md +2 -2
- data/tutorial/02_chaining_cogs/code_review.rb +1 -1
- data/tutorial/02_chaining_cogs/session_resumption.rb +1 -1
- data/tutorial/03_targets_and_params/README.md +1 -1
- data/tutorial/04_configuration_options/README.md +2 -2
- data/tutorial/08_iterative_workflows/README.md +1 -1
- data/tutorial/README.md +1 -1
- metadata +39 -17
- data/docs/AGENT_STEPS.md +0 -288
- data/docs/INSTRUMENTATION.md +0 -243
- data/docs/ITERATION_SYNTAX.md +0 -147
- data/docs/VALIDATION.md +0 -178
- data/lib/roast/nil_assertions.rb +0 -23
- /data/internal/documentation/{architectural-notes.md → comments/architectural-notes.md} +0 -0
- /data/internal/documentation/{doc-comments-external.md → comments/doc-comments-external.md} +0 -0
- /data/internal/documentation/{doc-comments-internal.md → comments/doc-comments-internal.md} +0 -0
- /data/internal/documentation/{doc-comments.md → comments/doc-comments.md} +0 -0
|
@@ -38,7 +38,7 @@ class Parser::AST::Node < ::AST::Node
|
|
|
38
38
|
# @api public
|
|
39
39
|
# @return [Parser::Source::Map]
|
|
40
40
|
#
|
|
41
|
-
# source://parser//lib/parser/ast/node.rb#
|
|
41
|
+
# source://parser//lib/parser/ast/node.rb#20
|
|
42
42
|
def loc; end
|
|
43
43
|
|
|
44
44
|
# Source map for this Node.
|
|
@@ -58,33 +58,33 @@ class Parser::AST::Processor
|
|
|
58
58
|
|
|
59
59
|
# @api public
|
|
60
60
|
#
|
|
61
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
61
|
+
# source://parser//lib/parser/ast/processor.rb#179
|
|
62
62
|
def on_alias(node); end
|
|
63
63
|
|
|
64
64
|
# @api public
|
|
65
65
|
#
|
|
66
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
66
|
+
# source://parser//lib/parser/ast/processor.rb#222
|
|
67
67
|
def on_and(node); end
|
|
68
68
|
|
|
69
69
|
# @api public
|
|
70
70
|
#
|
|
71
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
71
|
+
# source://parser//lib/parser/ast/processor.rb#67
|
|
72
72
|
def on_and_asgn(node); end
|
|
73
73
|
|
|
74
74
|
# @api public
|
|
75
75
|
# @private
|
|
76
76
|
#
|
|
77
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
77
|
+
# source://parser//lib/parser/ast/processor.rb#122
|
|
78
78
|
def on_arg(node); end
|
|
79
79
|
|
|
80
80
|
# @api public
|
|
81
81
|
#
|
|
82
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
82
|
+
# source://parser//lib/parser/ast/processor.rb#148
|
|
83
83
|
def on_arg_expr(node); end
|
|
84
84
|
|
|
85
85
|
# @api public
|
|
86
86
|
#
|
|
87
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
87
|
+
# source://parser//lib/parser/ast/processor.rb#103
|
|
88
88
|
def on_args(node); end
|
|
89
89
|
|
|
90
90
|
# @api public
|
|
@@ -94,64 +94,64 @@ class Parser::AST::Processor
|
|
|
94
94
|
|
|
95
95
|
# @api public
|
|
96
96
|
#
|
|
97
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
97
|
+
# source://parser//lib/parser/ast/processor.rb#22
|
|
98
98
|
def on_array(node); end
|
|
99
99
|
|
|
100
100
|
# @api public
|
|
101
101
|
#
|
|
102
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
102
|
+
# source://parser//lib/parser/ast/processor.rb#258
|
|
103
103
|
def on_array_pattern(node); end
|
|
104
104
|
|
|
105
105
|
# @api public
|
|
106
106
|
#
|
|
107
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
107
|
+
# source://parser//lib/parser/ast/processor.rb#259
|
|
108
108
|
def on_array_pattern_with_tail(node); end
|
|
109
109
|
|
|
110
110
|
# @api public
|
|
111
111
|
# @private
|
|
112
112
|
#
|
|
113
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
113
|
+
# source://parser//lib/parser/ast/processor.rb#42
|
|
114
114
|
def on_back_ref(node); end
|
|
115
115
|
|
|
116
116
|
# @api public
|
|
117
117
|
#
|
|
118
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
118
|
+
# source://parser//lib/parser/ast/processor.rb#240
|
|
119
119
|
def on_begin(node); end
|
|
120
120
|
|
|
121
121
|
# @api public
|
|
122
122
|
#
|
|
123
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
123
|
+
# source://parser//lib/parser/ast/processor.rb#195
|
|
124
124
|
def on_block(node); end
|
|
125
125
|
|
|
126
126
|
# @api public
|
|
127
127
|
#
|
|
128
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
128
|
+
# source://parser//lib/parser/ast/processor.rb#151
|
|
129
129
|
def on_block_pass(node); end
|
|
130
130
|
|
|
131
131
|
# @api public
|
|
132
132
|
# @private
|
|
133
133
|
#
|
|
134
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
134
|
+
# source://parser//lib/parser/ast/processor.rb#125
|
|
135
135
|
def on_blockarg(node); end
|
|
136
136
|
|
|
137
137
|
# @api public
|
|
138
138
|
#
|
|
139
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
139
|
+
# source://parser//lib/parser/ast/processor.rb#150
|
|
140
140
|
def on_blockarg_expr(node); end
|
|
141
141
|
|
|
142
142
|
# @api public
|
|
143
143
|
#
|
|
144
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
144
|
+
# source://parser//lib/parser/ast/processor.rb#213
|
|
145
145
|
def on_break(node); end
|
|
146
146
|
|
|
147
147
|
# @api public
|
|
148
148
|
#
|
|
149
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
149
|
+
# source://parser//lib/parser/ast/processor.rb#228
|
|
150
150
|
def on_case(node); end
|
|
151
151
|
|
|
152
152
|
# @api public
|
|
153
153
|
#
|
|
154
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
154
|
+
# source://parser//lib/parser/ast/processor.rb#246
|
|
155
155
|
def on_case_match(node); end
|
|
156
156
|
|
|
157
157
|
# @api public
|
|
@@ -161,7 +161,7 @@ class Parser::AST::Processor
|
|
|
161
161
|
|
|
162
162
|
# @api public
|
|
163
163
|
#
|
|
164
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
164
|
+
# source://parser//lib/parser/ast/processor.rb#157
|
|
165
165
|
def on_class(node); end
|
|
166
166
|
|
|
167
167
|
# @api public
|
|
@@ -171,24 +171,24 @@ class Parser::AST::Processor
|
|
|
171
171
|
|
|
172
172
|
# @api public
|
|
173
173
|
#
|
|
174
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
174
|
+
# source://parser//lib/parser/ast/processor.rb#261
|
|
175
175
|
def on_const_pattern(node); end
|
|
176
176
|
|
|
177
177
|
# @api public
|
|
178
178
|
#
|
|
179
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
179
|
+
# source://parser//lib/parser/ast/processor.rb#190
|
|
180
180
|
def on_csend(node); end
|
|
181
181
|
|
|
182
182
|
# @api public
|
|
183
183
|
# @private
|
|
184
184
|
#
|
|
185
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
185
|
+
# source://parser//lib/parser/ast/processor.rb#41
|
|
186
186
|
def on_cvar(node); end
|
|
187
187
|
|
|
188
188
|
# @api public
|
|
189
189
|
# @private
|
|
190
190
|
#
|
|
191
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
191
|
+
# source://parser//lib/parser/ast/processor.rb#65
|
|
192
192
|
def on_cvasgn(node); end
|
|
193
193
|
|
|
194
194
|
# @api public
|
|
@@ -198,7 +198,7 @@ class Parser::AST::Processor
|
|
|
198
198
|
|
|
199
199
|
# @api public
|
|
200
200
|
#
|
|
201
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
201
|
+
# source://parser//lib/parser/ast/processor.rb#219
|
|
202
202
|
def on_defined?(node); end
|
|
203
203
|
|
|
204
204
|
# @api public
|
|
@@ -208,17 +208,17 @@ class Parser::AST::Processor
|
|
|
208
208
|
|
|
209
209
|
# @api public
|
|
210
210
|
#
|
|
211
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
211
|
+
# source://parser//lib/parser/ast/processor.rb#16
|
|
212
212
|
def on_dstr(node); end
|
|
213
213
|
|
|
214
214
|
# @api public
|
|
215
215
|
#
|
|
216
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
216
|
+
# source://parser//lib/parser/ast/processor.rb#17
|
|
217
217
|
def on_dsym(node); end
|
|
218
218
|
|
|
219
219
|
# @api public
|
|
220
220
|
#
|
|
221
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
221
|
+
# source://parser//lib/parser/ast/processor.rb#231
|
|
222
222
|
def on_eflipflop(node); end
|
|
223
223
|
|
|
224
224
|
# @api public
|
|
@@ -228,234 +228,234 @@ class Parser::AST::Processor
|
|
|
228
228
|
|
|
229
229
|
# @api public
|
|
230
230
|
#
|
|
231
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
231
|
+
# source://parser//lib/parser/ast/processor.rb#238
|
|
232
232
|
def on_ensure(node); end
|
|
233
233
|
|
|
234
234
|
# @api public
|
|
235
235
|
#
|
|
236
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
236
|
+
# source://parser//lib/parser/ast/processor.rb#27
|
|
237
237
|
def on_erange(node); end
|
|
238
238
|
|
|
239
239
|
# @api public
|
|
240
240
|
#
|
|
241
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
241
|
+
# source://parser//lib/parser/ast/processor.rb#262
|
|
242
242
|
def on_find_pattern(node); end
|
|
243
243
|
|
|
244
244
|
# @api public
|
|
245
245
|
#
|
|
246
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
246
|
+
# source://parser//lib/parser/ast/processor.rb#210
|
|
247
247
|
def on_for(node); end
|
|
248
248
|
|
|
249
249
|
# @api public
|
|
250
250
|
# @private
|
|
251
251
|
#
|
|
252
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
252
|
+
# source://parser//lib/parser/ast/processor.rb#130
|
|
253
253
|
def on_forward_arg(node); end
|
|
254
254
|
|
|
255
255
|
# @api public
|
|
256
256
|
#
|
|
257
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
257
|
+
# source://parser//lib/parser/ast/processor.rb#154
|
|
258
258
|
def on_forwarded_kwrestarg(node); end
|
|
259
259
|
|
|
260
260
|
# @api public
|
|
261
261
|
#
|
|
262
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
262
|
+
# source://parser//lib/parser/ast/processor.rb#153
|
|
263
263
|
def on_forwarded_restarg(node); end
|
|
264
264
|
|
|
265
265
|
# @api public
|
|
266
266
|
# @private
|
|
267
267
|
#
|
|
268
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
268
|
+
# source://parser//lib/parser/ast/processor.rb#40
|
|
269
269
|
def on_gvar(node); end
|
|
270
270
|
|
|
271
271
|
# @api public
|
|
272
272
|
# @private
|
|
273
273
|
#
|
|
274
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
274
|
+
# source://parser//lib/parser/ast/processor.rb#64
|
|
275
275
|
def on_gvasgn(node); end
|
|
276
276
|
|
|
277
277
|
# @api public
|
|
278
278
|
#
|
|
279
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
279
|
+
# source://parser//lib/parser/ast/processor.rb#24
|
|
280
280
|
def on_hash(node); end
|
|
281
281
|
|
|
282
282
|
# @api public
|
|
283
283
|
#
|
|
284
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
284
|
+
# source://parser//lib/parser/ast/processor.rb#260
|
|
285
285
|
def on_hash_pattern(node); end
|
|
286
286
|
|
|
287
287
|
# @api public
|
|
288
288
|
#
|
|
289
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
289
|
+
# source://parser//lib/parser/ast/processor.rb#225
|
|
290
290
|
def on_if(node); end
|
|
291
291
|
|
|
292
292
|
# @api public
|
|
293
293
|
#
|
|
294
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
294
|
+
# source://parser//lib/parser/ast/processor.rb#251
|
|
295
295
|
def on_if_guard(node); end
|
|
296
296
|
|
|
297
297
|
# @api public
|
|
298
298
|
#
|
|
299
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
299
|
+
# source://parser//lib/parser/ast/processor.rb#230
|
|
300
300
|
def on_iflipflop(node); end
|
|
301
301
|
|
|
302
302
|
# @api public
|
|
303
303
|
#
|
|
304
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
304
|
+
# source://parser//lib/parser/ast/processor.rb#247
|
|
305
305
|
def on_in_match(node); end
|
|
306
306
|
|
|
307
307
|
# @api public
|
|
308
308
|
#
|
|
309
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
309
|
+
# source://parser//lib/parser/ast/processor.rb#250
|
|
310
310
|
def on_in_pattern(node); end
|
|
311
311
|
|
|
312
312
|
# @api public
|
|
313
313
|
#
|
|
314
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
314
|
+
# source://parser//lib/parser/ast/processor.rb#192
|
|
315
315
|
def on_index(node); end
|
|
316
316
|
|
|
317
317
|
# @api public
|
|
318
318
|
#
|
|
319
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
319
|
+
# source://parser//lib/parser/ast/processor.rb#193
|
|
320
320
|
def on_indexasgn(node); end
|
|
321
321
|
|
|
322
322
|
# @api public
|
|
323
323
|
#
|
|
324
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
324
|
+
# source://parser//lib/parser/ast/processor.rb#26
|
|
325
325
|
def on_irange(node); end
|
|
326
326
|
|
|
327
327
|
# @api public
|
|
328
328
|
# @private
|
|
329
329
|
#
|
|
330
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
330
|
+
# source://parser//lib/parser/ast/processor.rb#39
|
|
331
331
|
def on_ivar(node); end
|
|
332
332
|
|
|
333
333
|
# @api public
|
|
334
334
|
# @private
|
|
335
335
|
#
|
|
336
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
336
|
+
# source://parser//lib/parser/ast/processor.rb#63
|
|
337
337
|
def on_ivasgn(node); end
|
|
338
338
|
|
|
339
339
|
# @api public
|
|
340
340
|
# @private
|
|
341
341
|
#
|
|
342
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
342
|
+
# source://parser//lib/parser/ast/processor.rb#127
|
|
343
343
|
def on_kwarg(node); end
|
|
344
344
|
|
|
345
345
|
# @api public
|
|
346
346
|
#
|
|
347
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
347
|
+
# source://parser//lib/parser/ast/processor.rb#25
|
|
348
348
|
def on_kwargs(node); end
|
|
349
349
|
|
|
350
350
|
# @api public
|
|
351
351
|
#
|
|
352
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
352
|
+
# source://parser//lib/parser/ast/processor.rb#241
|
|
353
353
|
def on_kwbegin(node); end
|
|
354
354
|
|
|
355
355
|
# @api public
|
|
356
356
|
# @private
|
|
357
357
|
#
|
|
358
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
358
|
+
# source://parser//lib/parser/ast/processor.rb#128
|
|
359
359
|
def on_kwoptarg(node); end
|
|
360
360
|
|
|
361
361
|
# @api public
|
|
362
362
|
# @private
|
|
363
363
|
#
|
|
364
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
364
|
+
# source://parser//lib/parser/ast/processor.rb#129
|
|
365
365
|
def on_kwrestarg(node); end
|
|
366
366
|
|
|
367
367
|
# @api public
|
|
368
368
|
#
|
|
369
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
369
|
+
# source://parser//lib/parser/ast/processor.rb#21
|
|
370
370
|
def on_kwsplat(node); end
|
|
371
371
|
|
|
372
372
|
# @api public
|
|
373
373
|
#
|
|
374
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
374
|
+
# source://parser//lib/parser/ast/processor.rb#196
|
|
375
375
|
def on_lambda(node); end
|
|
376
376
|
|
|
377
377
|
# @api public
|
|
378
378
|
# @private
|
|
379
379
|
#
|
|
380
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
380
|
+
# source://parser//lib/parser/ast/processor.rb#38
|
|
381
381
|
def on_lvar(node); end
|
|
382
382
|
|
|
383
383
|
# @api public
|
|
384
384
|
# @private
|
|
385
385
|
#
|
|
386
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
386
|
+
# source://parser//lib/parser/ast/processor.rb#62
|
|
387
387
|
def on_lvasgn(node); end
|
|
388
388
|
|
|
389
389
|
# @api public
|
|
390
390
|
#
|
|
391
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
391
|
+
# source://parser//lib/parser/ast/processor.rb#79
|
|
392
392
|
def on_masgn(node); end
|
|
393
393
|
|
|
394
394
|
# @api public
|
|
395
395
|
#
|
|
396
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
396
|
+
# source://parser//lib/parser/ast/processor.rb#256
|
|
397
397
|
def on_match_alt(node); end
|
|
398
398
|
|
|
399
399
|
# @api public
|
|
400
400
|
#
|
|
401
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
401
|
+
# source://parser//lib/parser/ast/processor.rb#257
|
|
402
402
|
def on_match_as(node); end
|
|
403
403
|
|
|
404
404
|
# @api public
|
|
405
405
|
#
|
|
406
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
406
|
+
# source://parser//lib/parser/ast/processor.rb#233
|
|
407
407
|
def on_match_current_line(node); end
|
|
408
408
|
|
|
409
409
|
# @api public
|
|
410
410
|
#
|
|
411
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
411
|
+
# source://parser//lib/parser/ast/processor.rb#248
|
|
412
412
|
def on_match_pattern(node); end
|
|
413
413
|
|
|
414
414
|
# @api public
|
|
415
415
|
#
|
|
416
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
416
|
+
# source://parser//lib/parser/ast/processor.rb#249
|
|
417
417
|
def on_match_pattern_p(node); end
|
|
418
418
|
|
|
419
419
|
# @api public
|
|
420
420
|
#
|
|
421
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
421
|
+
# source://parser//lib/parser/ast/processor.rb#254
|
|
422
422
|
def on_match_rest(node); end
|
|
423
423
|
|
|
424
424
|
# @api public
|
|
425
425
|
# @private
|
|
426
426
|
#
|
|
427
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
427
|
+
# source://parser//lib/parser/ast/processor.rb#253
|
|
428
428
|
def on_match_var(node); end
|
|
429
429
|
|
|
430
430
|
# @api public
|
|
431
431
|
#
|
|
432
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
432
|
+
# source://parser//lib/parser/ast/processor.rb#234
|
|
433
433
|
def on_match_with_lvasgn(node); end
|
|
434
434
|
|
|
435
435
|
# @api public
|
|
436
436
|
#
|
|
437
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
437
|
+
# source://parser//lib/parser/ast/processor.rb#78
|
|
438
438
|
def on_mlhs(node); end
|
|
439
439
|
|
|
440
440
|
# @api public
|
|
441
441
|
#
|
|
442
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
442
|
+
# source://parser//lib/parser/ast/processor.rb#156
|
|
443
443
|
def on_module(node); end
|
|
444
444
|
|
|
445
445
|
# @api public
|
|
446
446
|
#
|
|
447
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
447
|
+
# source://parser//lib/parser/ast/processor.rb#214
|
|
448
448
|
def on_next(node); end
|
|
449
449
|
|
|
450
450
|
# @api public
|
|
451
451
|
#
|
|
452
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
452
|
+
# source://parser//lib/parser/ast/processor.rb#221
|
|
453
453
|
def on_not(node); end
|
|
454
454
|
|
|
455
455
|
# @api public
|
|
456
456
|
# @private
|
|
457
457
|
#
|
|
458
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
458
|
+
# source://parser//lib/parser/ast/processor.rb#43
|
|
459
459
|
def on_nth_ref(node); end
|
|
460
460
|
|
|
461
461
|
# @api public
|
|
@@ -471,37 +471,37 @@ class Parser::AST::Processor
|
|
|
471
471
|
# @api public
|
|
472
472
|
# @private
|
|
473
473
|
#
|
|
474
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
474
|
+
# source://parser//lib/parser/ast/processor.rb#123
|
|
475
475
|
def on_optarg(node); end
|
|
476
476
|
|
|
477
477
|
# @api public
|
|
478
478
|
#
|
|
479
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
479
|
+
# source://parser//lib/parser/ast/processor.rb#223
|
|
480
480
|
def on_or(node); end
|
|
481
481
|
|
|
482
482
|
# @api public
|
|
483
483
|
#
|
|
484
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
484
|
+
# source://parser//lib/parser/ast/processor.rb#68
|
|
485
485
|
def on_or_asgn(node); end
|
|
486
486
|
|
|
487
487
|
# @api public
|
|
488
488
|
#
|
|
489
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
489
|
+
# source://parser//lib/parser/ast/processor.rb#23
|
|
490
490
|
def on_pair(node); end
|
|
491
491
|
|
|
492
492
|
# @api public
|
|
493
493
|
#
|
|
494
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
494
|
+
# source://parser//lib/parser/ast/processor.rb#255
|
|
495
495
|
def on_pin(node); end
|
|
496
496
|
|
|
497
497
|
# @api public
|
|
498
498
|
#
|
|
499
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
499
|
+
# source://parser//lib/parser/ast/processor.rb#244
|
|
500
500
|
def on_postexe(node); end
|
|
501
501
|
|
|
502
502
|
# @api public
|
|
503
503
|
#
|
|
504
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
504
|
+
# source://parser//lib/parser/ast/processor.rb#243
|
|
505
505
|
def on_preexe(node); end
|
|
506
506
|
|
|
507
507
|
# @api public
|
|
@@ -511,48 +511,48 @@ class Parser::AST::Processor
|
|
|
511
511
|
|
|
512
512
|
# @api public
|
|
513
513
|
#
|
|
514
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
514
|
+
# source://parser//lib/parser/ast/processor.rb#215
|
|
515
515
|
def on_redo(node); end
|
|
516
516
|
|
|
517
517
|
# @api public
|
|
518
518
|
#
|
|
519
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
519
|
+
# source://parser//lib/parser/ast/processor.rb#18
|
|
520
520
|
def on_regexp(node); end
|
|
521
521
|
|
|
522
522
|
# @api public
|
|
523
523
|
#
|
|
524
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
524
|
+
# source://parser//lib/parser/ast/processor.rb#236
|
|
525
525
|
def on_resbody(node); end
|
|
526
526
|
|
|
527
527
|
# @api public
|
|
528
528
|
#
|
|
529
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
529
|
+
# source://parser//lib/parser/ast/processor.rb#237
|
|
530
530
|
def on_rescue(node); end
|
|
531
531
|
|
|
532
532
|
# @api public
|
|
533
533
|
# @private
|
|
534
534
|
#
|
|
535
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
535
|
+
# source://parser//lib/parser/ast/processor.rb#124
|
|
536
536
|
def on_restarg(node); end
|
|
537
537
|
|
|
538
538
|
# @api public
|
|
539
539
|
#
|
|
540
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
540
|
+
# source://parser//lib/parser/ast/processor.rb#149
|
|
541
541
|
def on_restarg_expr(node); end
|
|
542
542
|
|
|
543
543
|
# @api public
|
|
544
544
|
#
|
|
545
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
545
|
+
# source://parser//lib/parser/ast/processor.rb#216
|
|
546
546
|
def on_retry(node); end
|
|
547
547
|
|
|
548
548
|
# @api public
|
|
549
549
|
#
|
|
550
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
550
|
+
# source://parser//lib/parser/ast/processor.rb#212
|
|
551
551
|
def on_return(node); end
|
|
552
552
|
|
|
553
553
|
# @api public
|
|
554
554
|
#
|
|
555
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
555
|
+
# source://parser//lib/parser/ast/processor.rb#158
|
|
556
556
|
def on_sclass(node); end
|
|
557
557
|
|
|
558
558
|
# @api public
|
|
@@ -563,37 +563,37 @@ class Parser::AST::Processor
|
|
|
563
563
|
# @api public
|
|
564
564
|
# @private
|
|
565
565
|
#
|
|
566
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
566
|
+
# source://parser//lib/parser/ast/processor.rb#126
|
|
567
567
|
def on_shadowarg(node); end
|
|
568
568
|
|
|
569
569
|
# @api public
|
|
570
570
|
#
|
|
571
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
571
|
+
# source://parser//lib/parser/ast/processor.rb#20
|
|
572
572
|
def on_splat(node); end
|
|
573
573
|
|
|
574
574
|
# @api public
|
|
575
575
|
#
|
|
576
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
576
|
+
# source://parser//lib/parser/ast/processor.rb#217
|
|
577
577
|
def on_super(node); end
|
|
578
578
|
|
|
579
579
|
# @api public
|
|
580
580
|
#
|
|
581
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
581
|
+
# source://parser//lib/parser/ast/processor.rb#178
|
|
582
582
|
def on_undef(node); end
|
|
583
583
|
|
|
584
584
|
# @api public
|
|
585
585
|
#
|
|
586
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
586
|
+
# source://parser//lib/parser/ast/processor.rb#252
|
|
587
587
|
def on_unless_guard(node); end
|
|
588
588
|
|
|
589
589
|
# @api public
|
|
590
590
|
#
|
|
591
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
591
|
+
# source://parser//lib/parser/ast/processor.rb#208
|
|
592
592
|
def on_until(node); end
|
|
593
593
|
|
|
594
594
|
# @api public
|
|
595
595
|
#
|
|
596
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
596
|
+
# source://parser//lib/parser/ast/processor.rb#209
|
|
597
597
|
def on_until_post(node); end
|
|
598
598
|
|
|
599
599
|
# @api public
|
|
@@ -608,33 +608,33 @@ class Parser::AST::Processor
|
|
|
608
608
|
|
|
609
609
|
# @api public
|
|
610
610
|
#
|
|
611
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
611
|
+
# source://parser//lib/parser/ast/processor.rb#227
|
|
612
612
|
def on_when(node); end
|
|
613
613
|
|
|
614
614
|
# @api public
|
|
615
615
|
#
|
|
616
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
616
|
+
# source://parser//lib/parser/ast/processor.rb#206
|
|
617
617
|
def on_while(node); end
|
|
618
618
|
|
|
619
619
|
# @api public
|
|
620
620
|
#
|
|
621
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
621
|
+
# source://parser//lib/parser/ast/processor.rb#207
|
|
622
622
|
def on_while_post(node); end
|
|
623
623
|
|
|
624
624
|
# @api public
|
|
625
625
|
#
|
|
626
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
626
|
+
# source://parser//lib/parser/ast/processor.rb#19
|
|
627
627
|
def on_xstr(node); end
|
|
628
628
|
|
|
629
629
|
# @api public
|
|
630
630
|
#
|
|
631
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
631
|
+
# source://parser//lib/parser/ast/processor.rb#218
|
|
632
632
|
def on_yield(node); end
|
|
633
633
|
|
|
634
634
|
# @api public
|
|
635
635
|
# @private
|
|
636
636
|
#
|
|
637
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
637
|
+
# source://parser//lib/parser/ast/processor.rb#118
|
|
638
638
|
def process_argument_node(node); end
|
|
639
639
|
|
|
640
640
|
# @api public
|
|
@@ -645,13 +645,13 @@ class Parser::AST::Processor
|
|
|
645
645
|
# @api public
|
|
646
646
|
# @private
|
|
647
647
|
#
|
|
648
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
648
|
+
# source://parser//lib/parser/ast/processor.rb#58
|
|
649
649
|
def process_var_asgn_node(node); end
|
|
650
650
|
|
|
651
651
|
# @api public
|
|
652
652
|
# @private
|
|
653
653
|
#
|
|
654
|
-
# source://parser//lib/parser/ast/processor.rb#
|
|
654
|
+
# source://parser//lib/parser/ast/processor.rb#34
|
|
655
655
|
def process_variable_node(node); end
|
|
656
656
|
end
|
|
657
657
|
|
|
@@ -763,8 +763,8 @@ class Parser::Base < ::Racc::Parser
|
|
|
763
763
|
# `:tSTRING "foo"`; such details must not be relied upon.
|
|
764
764
|
#
|
|
765
765
|
# @api public
|
|
766
|
-
# @param source_buffer [Parser::Source::Buffer]
|
|
767
766
|
# @param recover [Boolean] If true, recover from syntax errors. False by default.
|
|
767
|
+
# @param source_buffer [Parser::Source::Buffer]
|
|
768
768
|
# @return [Array]
|
|
769
769
|
#
|
|
770
770
|
# source://parser//lib/parser/base.rb#236
|
|
@@ -806,9 +806,9 @@ class Parser::Base < ::Racc::Parser
|
|
|
806
806
|
# @api public
|
|
807
807
|
# @example
|
|
808
808
|
# Parser::Base.parse('puts "hello"')
|
|
809
|
-
# @param string [String] The block of code to parse.
|
|
810
809
|
# @param file [String] The name of the file the code originated from.
|
|
811
810
|
# @param line [Numeric] The initial line number.
|
|
811
|
+
# @param string [String] The block of code to parse.
|
|
812
812
|
# @return [Parser::AST::Node]
|
|
813
813
|
#
|
|
814
814
|
# source://parser//lib/parser/base.rb#33
|
|
@@ -845,9 +845,9 @@ class Parser::Base < ::Racc::Parser
|
|
|
845
845
|
# @api public
|
|
846
846
|
# @example
|
|
847
847
|
# Parser::Base.parse_with_comments('puts "hello"')
|
|
848
|
-
# @param string [String] The block of code to parse.
|
|
849
848
|
# @param file [String] The name of the file the code originated from.
|
|
850
849
|
# @param line [Numeric] The initial line number.
|
|
850
|
+
# @param string [String] The block of code to parse.
|
|
851
851
|
# @return [Array]
|
|
852
852
|
#
|
|
853
853
|
# source://parser//lib/parser/base.rb#52
|
|
@@ -1693,11 +1693,11 @@ end
|
|
|
1693
1693
|
# source://parser//lib/parser/diagnostic.rb#31
|
|
1694
1694
|
class Parser::Diagnostic
|
|
1695
1695
|
# @api public
|
|
1696
|
-
# @param level [Symbol]
|
|
1697
|
-
# @param reason [Symbol]
|
|
1698
1696
|
# @param arguments [Hash]
|
|
1699
|
-
# @param location [Parser::Source::Range]
|
|
1700
1697
|
# @param highlights [Array<Parser::Source::Range>]
|
|
1698
|
+
# @param level [Symbol]
|
|
1699
|
+
# @param location [Parser::Source::Range]
|
|
1700
|
+
# @param reason [Symbol]
|
|
1701
1701
|
# @return [Diagnostic] a new instance of Diagnostic
|
|
1702
1702
|
#
|
|
1703
1703
|
# source://parser//lib/parser/diagnostic.rb#49
|
|
@@ -2639,7 +2639,7 @@ class Parser::Lexer::StackState
|
|
|
2639
2639
|
# source://parser//lib/parser/lexer/stack_state.rb#38
|
|
2640
2640
|
def empty?; end
|
|
2641
2641
|
|
|
2642
|
-
# source://parser//lib/parser/lexer/stack_state.rb#
|
|
2642
|
+
# source://parser//lib/parser/lexer/stack_state.rb#46
|
|
2643
2643
|
def inspect; end
|
|
2644
2644
|
|
|
2645
2645
|
# source://parser//lib/parser/lexer/stack_state.rb#29
|
|
@@ -3272,8 +3272,8 @@ class Parser::Rewriter < ::Parser::AST::Processor
|
|
|
3272
3272
|
# Inserts new code after the given source range.
|
|
3273
3273
|
#
|
|
3274
3274
|
# @api public
|
|
3275
|
-
# @param range [Parser::Source::Range]
|
|
3276
3275
|
# @param content [String]
|
|
3276
|
+
# @param range [Parser::Source::Range]
|
|
3277
3277
|
#
|
|
3278
3278
|
# source://parser//lib/parser/rewriter.rb#77
|
|
3279
3279
|
def insert_after(range, content); end
|
|
@@ -3281,8 +3281,8 @@ class Parser::Rewriter < ::Parser::AST::Processor
|
|
|
3281
3281
|
# Inserts new code before the given source range.
|
|
3282
3282
|
#
|
|
3283
3283
|
# @api public
|
|
3284
|
-
# @param range [Parser::Source::Range]
|
|
3285
3284
|
# @param content [String]
|
|
3285
|
+
# @param range [Parser::Source::Range]
|
|
3286
3286
|
#
|
|
3287
3287
|
# source://parser//lib/parser/rewriter.rb#67
|
|
3288
3288
|
def insert_before(range, content); end
|
|
@@ -3298,8 +3298,8 @@ class Parser::Rewriter < ::Parser::AST::Processor
|
|
|
3298
3298
|
# Replaces the code of the source range `range` with `content`.
|
|
3299
3299
|
#
|
|
3300
3300
|
# @api public
|
|
3301
|
-
# @param range [Parser::Source::Range]
|
|
3302
3301
|
# @param content [String]
|
|
3302
|
+
# @param range [Parser::Source::Range]
|
|
3303
3303
|
#
|
|
3304
3304
|
# source://parser//lib/parser/rewriter.rb#87
|
|
3305
3305
|
def replace(range, content); end
|
|
@@ -3308,8 +3308,8 @@ class Parser::Rewriter < ::Parser::AST::Processor
|
|
|
3308
3308
|
# version.
|
|
3309
3309
|
#
|
|
3310
3310
|
# @api public
|
|
3311
|
-
# @param source_buffer [Parser::Source::Buffer]
|
|
3312
3311
|
# @param ast [Parser::AST::Node]
|
|
3312
|
+
# @param source_buffer [Parser::Source::Buffer]
|
|
3313
3313
|
# @return [String]
|
|
3314
3314
|
#
|
|
3315
3315
|
# source://parser//lib/parser/rewriter.rb#23
|
|
@@ -3318,8 +3318,8 @@ class Parser::Rewriter < ::Parser::AST::Processor
|
|
|
3318
3318
|
# Wraps the given source range with the given values.
|
|
3319
3319
|
#
|
|
3320
3320
|
# @api public
|
|
3321
|
-
# @param range [Parser::Source::Range]
|
|
3322
3321
|
# @param content [String]
|
|
3322
|
+
# @param range [Parser::Source::Range]
|
|
3323
3323
|
#
|
|
3324
3324
|
# source://parser//lib/parser/rewriter.rb#57
|
|
3325
3325
|
def wrap(range, before, after); end
|
|
@@ -3594,7 +3594,7 @@ class Parser::Source::Comment
|
|
|
3594
3594
|
# @api public
|
|
3595
3595
|
# @return [Parser::Source::Range]
|
|
3596
3596
|
#
|
|
3597
|
-
# source://parser//lib/parser/source/comment.rb#
|
|
3597
|
+
# source://parser//lib/parser/source/comment.rb#21
|
|
3598
3598
|
def loc; end
|
|
3599
3599
|
|
|
3600
3600
|
# @api public
|
|
@@ -3818,7 +3818,7 @@ class Parser::Source::Map
|
|
|
3818
3818
|
# @api public
|
|
3819
3819
|
# @return [Integer]
|
|
3820
3820
|
#
|
|
3821
|
-
# source://parser//lib/parser/source/map.rb#
|
|
3821
|
+
# source://parser//lib/parser/source/map.rb#103
|
|
3822
3822
|
def first_line; end
|
|
3823
3823
|
|
|
3824
3824
|
# A shortcut for `self.expression.last_column`.
|
|
@@ -4178,9 +4178,9 @@ class Parser::Source::Range
|
|
|
4178
4178
|
include ::Comparable
|
|
4179
4179
|
|
|
4180
4180
|
# @api public
|
|
4181
|
-
# @param source_buffer [Buffer]
|
|
4182
4181
|
# @param begin_pos [Integer]
|
|
4183
4182
|
# @param end_pos [Integer]
|
|
4183
|
+
# @param source_buffer [Buffer]
|
|
4184
4184
|
# @return [Range] a new instance of Range
|
|
4185
4185
|
#
|
|
4186
4186
|
# source://parser//lib/parser/source/range.rb#37
|
|
@@ -4294,6 +4294,8 @@ class Parser::Source::Range
|
|
|
4294
4294
|
def end_pos; end
|
|
4295
4295
|
|
|
4296
4296
|
# @api public
|
|
4297
|
+
#
|
|
4298
|
+
# source://parser//lib/parser/source/range.rb#308
|
|
4297
4299
|
def eql?(_arg0); end
|
|
4298
4300
|
|
|
4299
4301
|
# Line number of the beginning of this range. By default, the first line
|
|
@@ -4303,7 +4305,7 @@ class Parser::Source::Range
|
|
|
4303
4305
|
# @return [Integer] line number of the beginning of this range.
|
|
4304
4306
|
# @see Buffer
|
|
4305
4307
|
#
|
|
4306
|
-
# source://parser//lib/parser/source/range.rb#
|
|
4308
|
+
# source://parser//lib/parser/source/range.rb#87
|
|
4307
4309
|
def first_line; end
|
|
4308
4310
|
|
|
4309
4311
|
# Support for Ranges be used in as Hash indices and in Sets.
|
|
@@ -4359,7 +4361,7 @@ class Parser::Source::Range
|
|
|
4359
4361
|
# @api public
|
|
4360
4362
|
# @return [Integer] amount of characters included in this range.
|
|
4361
4363
|
#
|
|
4362
|
-
# source://parser//lib/parser/source/range.rb#
|
|
4364
|
+
# source://parser//lib/parser/source/range.rb#74
|
|
4363
4365
|
def length; end
|
|
4364
4366
|
|
|
4365
4367
|
# Line number of the beginning of this range. By default, the first line
|
|
@@ -4491,8 +4493,8 @@ class Parser::Source::Rewriter
|
|
|
4491
4493
|
#
|
|
4492
4494
|
# @api public
|
|
4493
4495
|
# @deprecated Use {TreeRewriter#insert_after}
|
|
4494
|
-
# @param range [Range]
|
|
4495
4496
|
# @param content [String]
|
|
4497
|
+
# @param range [Range]
|
|
4496
4498
|
# @raise [ClobberingError] when clobbering is detected
|
|
4497
4499
|
# @return [Rewriter] self
|
|
4498
4500
|
#
|
|
@@ -4511,8 +4513,8 @@ class Parser::Source::Rewriter
|
|
|
4511
4513
|
# insert_after_multi(range, ')').
|
|
4512
4514
|
# insert_after_multi(range, ']').
|
|
4513
4515
|
# process
|
|
4514
|
-
# @param range [Range]
|
|
4515
4516
|
# @param content [String]
|
|
4517
|
+
# @param range [Range]
|
|
4516
4518
|
# @raise [ClobberingError] when clobbering is detected
|
|
4517
4519
|
# @return [Rewriter] self
|
|
4518
4520
|
#
|
|
@@ -4523,8 +4525,8 @@ class Parser::Source::Rewriter
|
|
|
4523
4525
|
#
|
|
4524
4526
|
# @api public
|
|
4525
4527
|
# @deprecated Use {TreeRewriter#insert_before}
|
|
4526
|
-
# @param range [Range]
|
|
4527
4528
|
# @param content [String]
|
|
4529
|
+
# @param range [Range]
|
|
4528
4530
|
# @raise [ClobberingError] when clobbering is detected
|
|
4529
4531
|
# @return [Rewriter] self
|
|
4530
4532
|
#
|
|
@@ -4543,8 +4545,8 @@ class Parser::Source::Rewriter
|
|
|
4543
4545
|
# insert_before_multi(range, '(').
|
|
4544
4546
|
# insert_before_multi(range, '[').
|
|
4545
4547
|
# process
|
|
4546
|
-
# @param range [Range]
|
|
4547
4548
|
# @param content [String]
|
|
4549
|
+
# @param range [Range]
|
|
4548
4550
|
# @raise [ClobberingError] when clobbering is detected
|
|
4549
4551
|
# @return [Rewriter] self
|
|
4550
4552
|
#
|
|
@@ -4576,8 +4578,8 @@ class Parser::Source::Rewriter
|
|
|
4576
4578
|
#
|
|
4577
4579
|
# @api public
|
|
4578
4580
|
# @deprecated Use {TreeRewriter#replace}
|
|
4579
|
-
# @param range [Range]
|
|
4580
4581
|
# @param content [String]
|
|
4582
|
+
# @param range [Range]
|
|
4581
4583
|
# @raise [ClobberingError] when clobbering is detected
|
|
4582
4584
|
# @return [Rewriter] self
|
|
4583
4585
|
#
|
|
@@ -4614,9 +4616,9 @@ class Parser::Source::Rewriter
|
|
|
4614
4616
|
#
|
|
4615
4617
|
# @api public
|
|
4616
4618
|
# @deprecated Use {TreeRewriter#wrap}
|
|
4617
|
-
# @param range [Range]
|
|
4618
|
-
# @param before [String]
|
|
4619
4619
|
# @param after [String]
|
|
4620
|
+
# @param before [String]
|
|
4621
|
+
# @param range [Range]
|
|
4620
4622
|
# @raise [ClobberingError] when clobbering is detected
|
|
4621
4623
|
# @return [Rewriter] self
|
|
4622
4624
|
#
|
|
@@ -4798,7 +4800,7 @@ class Parser::Source::Rewriter::Action
|
|
|
4798
4800
|
# source://parser//lib/parser/source/rewriter/action.rb#12
|
|
4799
4801
|
def allow_multiple_insertions; end
|
|
4800
4802
|
|
|
4801
|
-
# source://parser//lib/parser/source/rewriter/action.rb#
|
|
4803
|
+
# source://parser//lib/parser/source/rewriter/action.rb#13
|
|
4802
4804
|
def allow_multiple_insertions?; end
|
|
4803
4805
|
|
|
4804
4806
|
# source://parser//lib/parser/source/rewriter/action.rb#12
|
|
@@ -4962,8 +4964,8 @@ class Parser::Source::TreeRewriter
|
|
|
4962
4964
|
# or that needs to be offset. Policies of the receiver are used.
|
|
4963
4965
|
#
|
|
4964
4966
|
# @api public
|
|
4965
|
-
# @param rewriter [TreeRewriter] from different source_buffer
|
|
4966
4967
|
# @param offset [Integer]
|
|
4968
|
+
# @param rewriter [TreeRewriter] from different source_buffer
|
|
4967
4969
|
# @raise [IndexError] if action ranges (once offset) don't fit the current buffer
|
|
4968
4970
|
# @return [Rewriter] self
|
|
4969
4971
|
#
|
|
@@ -4979,8 +4981,8 @@ class Parser::Source::TreeRewriter
|
|
|
4979
4981
|
# Shortcut for `wrap(range, nil, content)`
|
|
4980
4982
|
#
|
|
4981
4983
|
# @api public
|
|
4982
|
-
# @param range [Range]
|
|
4983
4984
|
# @param content [String]
|
|
4985
|
+
# @param range [Range]
|
|
4984
4986
|
# @raise [ClobberingError] when clobbering is detected
|
|
4985
4987
|
# @return [Rewriter] self
|
|
4986
4988
|
#
|
|
@@ -4996,8 +4998,8 @@ class Parser::Source::TreeRewriter
|
|
|
4996
4998
|
# Shortcut for `wrap(range, content, nil)`
|
|
4997
4999
|
#
|
|
4998
5000
|
# @api public
|
|
4999
|
-
# @param range [Range]
|
|
5000
5001
|
# @param content [String]
|
|
5002
|
+
# @param range [Range]
|
|
5001
5003
|
# @raise [ClobberingError] when clobbering is detected
|
|
5002
5004
|
# @return [Rewriter] self
|
|
5003
5005
|
#
|
|
@@ -5061,8 +5063,8 @@ class Parser::Source::TreeRewriter
|
|
|
5061
5063
|
# Replaces the code of the source range `range` with `content`.
|
|
5062
5064
|
#
|
|
5063
5065
|
# @api public
|
|
5064
|
-
# @param range [Range]
|
|
5065
5066
|
# @param content [String]
|
|
5067
|
+
# @param range [Range]
|
|
5066
5068
|
# @raise [ClobberingError] when clobbering is detected
|
|
5067
5069
|
# @return [Rewriter] self
|
|
5068
5070
|
#
|
|
@@ -5088,9 +5090,9 @@ class Parser::Source::TreeRewriter
|
|
|
5088
5090
|
# Inserts the given strings before and after the given range.
|
|
5089
5091
|
#
|
|
5090
5092
|
# @api public
|
|
5091
|
-
# @param range [Range]
|
|
5092
|
-
# @param insert_before [String, nil]
|
|
5093
5093
|
# @param insert_after [String, nil]
|
|
5094
|
+
# @param insert_before [String, nil]
|
|
5095
|
+
# @param range [Range]
|
|
5094
5096
|
# @raise [ClobberingError] when clobbering is detected
|
|
5095
5097
|
# @return [Rewriter] self
|
|
5096
5098
|
#
|
|
@@ -5435,8 +5437,8 @@ class Parser::TreeRewriter < ::Parser::AST::Processor
|
|
|
5435
5437
|
# Inserts new code after the given source range.
|
|
5436
5438
|
#
|
|
5437
5439
|
# @api public
|
|
5438
|
-
# @param range [Parser::Source::Range]
|
|
5439
5440
|
# @param content [String]
|
|
5441
|
+
# @param range [Parser::Source::Range]
|
|
5440
5442
|
#
|
|
5441
5443
|
# source://parser//lib/parser/tree_rewriter.rb#118
|
|
5442
5444
|
def insert_after(range, content); end
|
|
@@ -5444,8 +5446,8 @@ class Parser::TreeRewriter < ::Parser::AST::Processor
|
|
|
5444
5446
|
# Inserts new code before the given source range.
|
|
5445
5447
|
#
|
|
5446
5448
|
# @api public
|
|
5447
|
-
# @param range [Parser::Source::Range]
|
|
5448
5449
|
# @param content [String]
|
|
5450
|
+
# @param range [Parser::Source::Range]
|
|
5449
5451
|
#
|
|
5450
5452
|
# source://parser//lib/parser/tree_rewriter.rb#108
|
|
5451
5453
|
def insert_before(range, content); end
|
|
@@ -5461,8 +5463,8 @@ class Parser::TreeRewriter < ::Parser::AST::Processor
|
|
|
5461
5463
|
# Replaces the code of the source range `range` with `content`.
|
|
5462
5464
|
#
|
|
5463
5465
|
# @api public
|
|
5464
|
-
# @param range [Parser::Source::Range]
|
|
5465
5466
|
# @param content [String]
|
|
5467
|
+
# @param range [Parser::Source::Range]
|
|
5466
5468
|
#
|
|
5467
5469
|
# source://parser//lib/parser/tree_rewriter.rb#128
|
|
5468
5470
|
def replace(range, content); end
|
|
@@ -5471,10 +5473,10 @@ class Parser::TreeRewriter < ::Parser::AST::Processor
|
|
|
5471
5473
|
# version.
|
|
5472
5474
|
#
|
|
5473
5475
|
# @api public
|
|
5474
|
-
# @param source_buffer [Parser::Source::Buffer]
|
|
5475
5476
|
# @param ast [Parser::AST::Node]
|
|
5476
5477
|
# @param crossing_deletions:, [Symbol] different_replacements:, swallowed_insertions:
|
|
5477
5478
|
# policy arguments for TreeRewriter (optional)
|
|
5479
|
+
# @param source_buffer [Parser::Source::Buffer]
|
|
5478
5480
|
# @return [String]
|
|
5479
5481
|
#
|
|
5480
5482
|
# source://parser//lib/parser/tree_rewriter.rb#62
|
|
@@ -5483,8 +5485,8 @@ class Parser::TreeRewriter < ::Parser::AST::Processor
|
|
|
5483
5485
|
# Wraps the given source range with the given values.
|
|
5484
5486
|
#
|
|
5485
5487
|
# @api public
|
|
5486
|
-
# @param range [Parser::Source::Range]
|
|
5487
5488
|
# @param content [String]
|
|
5489
|
+
# @param range [Parser::Source::Range]
|
|
5488
5490
|
#
|
|
5489
5491
|
# source://parser//lib/parser/tree_rewriter.rb#98
|
|
5490
5492
|
def wrap(range, before, after); end
|