File tree 1 file changed +12
-0
lines changed
1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -180,6 +180,8 @@ func parseDocument(parser *Parser) (*ast.Document, error) {
180
180
allDefs := make (map [string ]ast.Definition )
181
181
for _ , def := range doc .Definitions {
182
182
switch v := def .(type ) {
183
+ case * ast.InterfaceDefinition :
184
+ allDefs [v .Name .Value ] = v
183
185
case * ast.TypeDefinition :
184
186
allDefs [v .Name .Value ] = v
185
187
case * ast.EnumDefinition :
@@ -204,6 +206,16 @@ func parseDocument(parser *Parser) (*ast.Document, error) {
204
206
name = n .Name
205
207
}
206
208
switch v := def .(type ) {
209
+ case * ast.InterfaceDefinition :
210
+ renamedType := ast .NewInterfaceDefinition (
211
+ name .Loc ,
212
+ name ,
213
+ v .Description ,
214
+ v .Annotations ,
215
+ v .Operations ,
216
+ )
217
+ nodes = append (nodes , renamedType )
218
+
207
219
case * ast.TypeDefinition :
208
220
renamedType := ast .NewTypeDefinition (
209
221
name .Loc ,
You can’t perform that action at this time.
0 commit comments