diff --git a/runtime/Go/antlr/v4/lexer.go b/runtime/Go/antlr/v4/lexer.go index e5594b2168..c1faf81e4e 100644 --- a/runtime/Go/antlr/v4/lexer.go +++ b/runtime/Go/antlr/v4/lexer.go @@ -159,7 +159,7 @@ func (b *BaseLexer) GetTokenFactory() TokenFactory { return b.factory } -func (b *BaseLexer) setTokenFactory(f TokenFactory) { +func (b *BaseLexer) SetTokenFactory(f TokenFactory) { b.factory = f } diff --git a/runtime/Go/antlr/v4/parser.go b/runtime/Go/antlr/v4/parser.go index fb57ac15db..5ca4ac7e15 100644 --- a/runtime/Go/antlr/v4/parser.go +++ b/runtime/Go/antlr/v4/parser.go @@ -317,8 +317,8 @@ func (p *BaseParser) GetTokenFactory() TokenFactory { } // setTokenFactory is used to tell our token source and error strategy about a new way to create tokens. -func (p *BaseParser) setTokenFactory(factory TokenFactory) { - p.input.GetTokenSource().setTokenFactory(factory) +func (p *BaseParser) SetTokenFactory(factory TokenFactory) { + p.input.GetTokenSource().SetTokenFactory(factory) } // GetATNWithBypassAlts - the ATN with bypass alternatives is expensive to create, so we create it diff --git a/runtime/Go/antlr/v4/token_source.go b/runtime/Go/antlr/v4/token_source.go index a3f36eaa67..1040aa1bfc 100644 --- a/runtime/Go/antlr/v4/token_source.go +++ b/runtime/Go/antlr/v4/token_source.go @@ -12,6 +12,6 @@ type TokenSource interface { GetCharPositionInLine() int GetInputStream() CharStream GetSourceName() string - setTokenFactory(factory TokenFactory) + SetTokenFactory(factory TokenFactory) GetTokenFactory() TokenFactory }