the symbol for nonExist in the GF runtime should be the last. this simplifies the binary search in the C runtime

This commit is contained in:
kr.angelov committed 2013-10-03 08:21:31 +00:00
1 parent bbf6bd52c0
commit 71868fa053
2 files changed
+4 -4

No files matched your search

+2 -2
View File
@@ -59,9 +59,9 @@ data Symbol
| SymLit {-# UNPACK #-} !Int {-# UNPACK #-} !LIndex
| SymVar {-# UNPACK #-} !Int {-# UNPACK #-} !Int
| SymKS Token
| SymNE -- non exist
| SymBIND -- the special BIND token
| SymKP [Symbol] [([Symbol],[String])]
| SymBIND -- the special BIND token
| SymNE -- non exist (this should be last constructor to simplify the binary search in the runtime)
deriving (Eq,Ord,Show)
data Production
= PApply {-# UNPACK #-} !FunId [PArg]