fork of https://github.com/sourcegraph/zoekt
1SOME_CONSTANT = 2.718
2
3if true
4a = 1
5elsif false
6b = 2
7else
8c = 3
9end
10
11(1..5).each do |counter|
12z = 3
13end
14
15for counter in 1..5
16y = 10
17end
18
19counter = 1
20while counter <= 5 do
21no = true
22counter += 1
23end
24
25begin
26raise NoMemoryError, 'Z.'
27rescue NoMemoryError => exception_variable
28puts 'A', exception_variable
29rescue RuntimeError => other_exception_variable
30puts 'K'
31else
32puts 'L'
33ensure
34puts 'O'
35end
36
37grade = 42
38case grade
39when 0.100
40shouldntgetcaptured = true
41puts 'you got a grade i guess'
42end
43
44module MyModule
45def self.abc(base)
46end
47
48class MyClass
49def yay
50end
51
52def self.woo(base)
53end
54end
55end
56
57class Foo
58attr_accessor :bar
59attr_reader :baz
60attr_writer :qux
61end
62
63class Aliased
64def bar
65end
66
67alias_method :baz, :bar
68end
69
70class Parental
71def parental_func()
72end
73end
74
75class Composed
76include Parental
77end