From d9fe326075eb13f06c2754606bf9ac3ce362c927 Mon Sep 17 00:00:00 2001 From: mununki Date: Thu, 5 Oct 2023 11:17:36 +0900 Subject: [PATCH] make diff --- lib/parse.go | 2 +- lib/write.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/parse.go b/lib/parse.go index 3cda187..7731913 100644 --- a/lib/parse.go +++ b/lib/parse.go @@ -40,7 +40,7 @@ func (p *Parser) parseArgs() []*Arg { p.lex.consumeToken(tokLParen) for p.lex.peek() != ')' { arg := Arg{} - name, comments := p.lex.consumeIdent(tokType) + name, comments := p.lex.consumeIdent(tokInput, tokType) arg.Name = name.String() arg.Descriptions = comments p.lex.consumeToken(tokColon) diff --git a/lib/write.go b/lib/write.go index 27c3ab5..8d9b168 100644 --- a/lib/write.go +++ b/lib/write.go @@ -11,7 +11,7 @@ type MergedSchema struct { func (ms *MergedSchema) WriteSchema(s *Schema) string { ms.writeDescriptions(s.SchemaDefinitions[0].Descriptions, 0, true) - ms.buf.WriteString("schema {\n") + ms.buf.WriteString("schema! {\n") ms.addIndent(1) if s.SchemaDefinitions[0].Query != nil { ms.buf.WriteString("query: " + *s.SchemaDefinitions[0].Query + "\n")