From 4c4edc0becc8f904a613878ed3e4f970f40a83ce Mon Sep 17 00:00:00 2001 From: Tamir Duberstein Date: Thu, 18 Aug 2016 12:32:25 -0400 Subject: [PATCH] cmd/goyacc: remove hardcoded NTYPES Updates #16144. Change-Id: I196dd4e871c88792ea95c02b31c54f269fdc505f Reviewed-on: https://go-review.googlesource.com/27350 Reviewed-by: Matthew Dempsky --- cmd/goyacc/yacc.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/cmd/goyacc/yacc.go b/cmd/goyacc/yacc.go index 1dcafacc9c..f319950b21 100644 --- a/cmd/goyacc/yacc.go +++ b/cmd/goyacc/yacc.go @@ -70,8 +70,6 @@ const ( WSETINC = 50 // increase for working sets wsets STATEINC = 200 // increase for states statemem - NTYPES = 63 - PRIVATE = 0xE000 // unicode private use // relationships which must hold: @@ -206,8 +204,8 @@ type Wset struct { } // storage of types -var ntypes int // number of types defined -var typeset [NTYPES]string // pointers to type tags +var ntypes int // number of types defined +var typeset = make(map[int]string) // pointers to type tags // token information