From b24f61a465d21af404ed647a977160042017e601 Mon Sep 17 00:00:00 2001 From: Ryo Nihei Date: Sat, 5 Nov 2022 14:21:13 +0900 Subject: Remove alias system Remove unimportant features to tidy up the specification. --- spec/test/parser.go | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'spec/test/parser.go') diff --git a/spec/test/parser.go b/spec/test/parser.go index aa5d022..c30d45c 100644 --- a/spec/test/parser.go +++ b/spec/test/parser.go @@ -270,11 +270,7 @@ func formatSyntaxError(synErr *SyntaxError, gram Grammar, lineOffset int) []byte b.WriteString(fmt.Sprintf("'%v' ()", string(tok.Lexeme()))) default: if term := gram.Terminal(tok.TerminalID()); term != "" { - if alias := gram.TerminalAlias(tok.TerminalID()); alias != "" { - b.WriteString(fmt.Sprintf("'%v' (%v)", string(tok.Lexeme()), alias)) - } else { - b.WriteString(fmt.Sprintf("'%v' (%v)", string(tok.Lexeme()), term)) - } + b.WriteString(fmt.Sprintf("'%v' (%v)", string(tok.Lexeme()), term)) } else { b.WriteString(fmt.Sprintf("'%v'", string(tok.Lexeme()))) } -- cgit v1.2.3