Skip to content

Commit 6a14f70

Browse files
committed
Add IndexDefinition switch case to Node() in explain.go
The Index() helper function was already defined but wasn't being called from the Node() switch statement. This adds the missing case for *ast.IndexDefinition to properly output Index AST nodes.
1 parent 5d2f760 commit 6a14f70

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

internal/explain/explain.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,8 @@ func Node(sb *strings.Builder, node interface{}, depth int) {
157157
explainNameTypePair(sb, n, indent, depth)
158158
case *ast.Parameter:
159159
explainParameter(sb, n, indent)
160+
case *ast.IndexDefinition:
161+
Index(sb, n, depth)
160162

161163
// Dictionary types
162164
case *ast.DictionaryAttributeDeclaration:

0 commit comments

Comments
 (0)