From c3b742e0904f3a4c5a5edd511cb414036445d027 Mon Sep 17 00:00:00 2001 From: Eric Vergnaud Date: Sun, 25 Jun 2017 14:49:21 +0800 Subject: [PATCH] also fix in go --- runtime/Go/antlr/atn_deserializer.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/runtime/Go/antlr/atn_deserializer.go b/runtime/Go/antlr/atn_deserializer.go index 2ac6953a3..884d39cf7 100644 --- a/runtime/Go/antlr/atn_deserializer.go +++ b/runtime/Go/antlr/atn_deserializer.go @@ -125,8 +125,10 @@ func (a *ATNDeserializer) reset(data []rune) { // Don't adjust the first value since that's the version number if i == 0 { temp[i] = c - } else { + } else if c > 1 { temp[i] = c - 2 + } else { + temp[i] = c + 65533 } }