aboutsummaryrefslogtreecommitdiff
path: root/grammar/semantic_error.go
diff options
context:
space:
mode:
authorRyo Nihei <nihei.dev@gmail.com>2022-04-14 02:11:06 +0900
committerRyo Nihei <nihei.dev@gmail.com>2022-04-15 21:27:19 +0900
commit97d36965cbb30108340727a982539e67dafea92d (patch)
tree8b08cfb995dc8eb219c1a8bdc753133113316b92 /grammar/semantic_error.go
parentMove compiler tests from driver package to grammar package (diff)
downloadcotia-97d36965cbb30108340727a982539e67dafea92d.tar.gz
cotia-97d36965cbb30108340727a982539e67dafea92d.tar.xz
Add tests for compiler
Diffstat (limited to 'grammar/semantic_error.go')
-rw-r--r--grammar/semantic_error.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/grammar/semantic_error.go b/grammar/semantic_error.go
index 04cc020..8e5b558 100644
--- a/grammar/semantic_error.go
+++ b/grammar/semantic_error.go
@@ -25,6 +25,7 @@ var (
semErrUndefinedSym = newSemanticError("undefined symbol")
semErrDuplicateProduction = newSemanticError("duplicate production")
semErrDuplicateTerminal = newSemanticError("duplicate terminal")
+ semErrDuplicateFragment = newSemanticError("duplicate fragment")
semErrDuplicateName = newSemanticError("duplicate names are not allowed between terminals and non-terminals")
semErrErrSymIsReserved = newSemanticError("symbol 'error' is reserved as a terminal symbol")
semErrDuplicateLabel = newSemanticError("a label must be unique in an alternative")