Skip to content

Commit 8d4efb9

Browse files
committed
fix(ruby): narrow context window for ruby
Attempt at fix #361
1 parent 64dd4cf commit 8d4efb9

1 file changed

Lines changed: 8 additions & 5 deletions

File tree

‎queries/ruby/context.scm‎

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,20 @@
11
(class
2-
(body_statement) @context.end) @context
2+
name: (constant) @context.end) @context
33

44
(singleton_class
5-
(body_statement) @context.end) @context
5+
value: (self) @context.end) @context
66

77
(module
8-
(body_statement) @context.end) @context
8+
name: (constant) @context.end) @context
99

1010
(method
11-
(body_statement) @context.end) @context
11+
name: (identifier)
12+
parameters: (method_parameters) @context.end) @context
1213

1314
(singleton_method
14-
(body_statement) @context.end) @context
15+
object: (self)
16+
name: (identifier)
17+
parameters: (method_parameters) @context.end) @context
1518

1619
(if
1720
(then) @context.end) @context

0 commit comments

Comments
 (0)