blob: b448be0cfce0203ab25f7a83985c75fd16b822a2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
@ ProgramNode (location: (0...37))
├── locals: []
└── statements:
@ StatementsNode (location: (0...37))
└── body: (length: 2)
├── @ DefNode (location: (0...15))
│ ├── name: :f
│ ├── name_loc: (4...5) = "f"
│ ├── receiver: ∅
│ ├── parameters:
│ │ @ ParametersNode (location: (6...9))
│ │ ├── requireds: (length: 1)
│ │ │ └── @ RequiredParameterNode (location: (6...9))
│ │ │ └── name: :foo
│ │ ├── optionals: (length: 0)
│ │ ├── posts: (length: 0)
│ │ ├── rest: ∅
│ │ ├── keywords: (length: 0)
│ │ ├── keyword_rest: ∅
│ │ └── block: ∅
│ ├── body: ∅
│ ├── locals: [:foo]
│ ├── def_keyword_loc: (0...3) = "def"
│ ├── operator_loc: ∅
│ ├── lparen_loc: (5...6) = "("
│ ├── rparen_loc: (9...10) = ")"
│ ├── equal_loc: ∅
│ └── end_keyword_loc: (12...15) = "end"
└── @ DefNode (location: (17...37))
├── name: :f
├── name_loc: (21...22) = "f"
├── receiver: ∅
├── parameters:
│ @ ParametersNode (location: (23...31))
│ ├── requireds: (length: 2)
│ │ ├── @ RequiredParameterNode (location: (23...26))
│ │ │ └── name: :foo
│ │ └── @ RequiredParameterNode (location: (28...31))
│ │ └── name: :bar
│ ├── optionals: (length: 0)
│ ├── posts: (length: 0)
│ ├── rest: ∅
│ ├── keywords: (length: 0)
│ ├── keyword_rest: ∅
│ └── block: ∅
├── body: ∅
├── locals: [:foo, :bar]
├── def_keyword_loc: (17...20) = "def"
├── operator_loc: ∅
├── lparen_loc: (22...23) = "("
├── rparen_loc: (31...32) = ")"
├── equal_loc: ∅
└── end_keyword_loc: (34...37) = "end"
|