style: format code (#1322)

This commit is contained in:
Kevin Wan
2021-12-14 11:29:44 +08:00
committed by GitHub
parent 1b14de2ff9
commit 490ef13822
15 changed files with 798 additions and 1247 deletions

View File

@@ -10,14 +10,14 @@ import (
// The apiparser_parser.go file was split into multiple files because it
// was too large and caused a possible memory overflow during goctl installation.
func (p *ApiParserParser) Sempred(localctx antlr.RuleContext, ruleIndex, predIndex int) bool {
switch ruleIndex {
case 18:
var t *FieldContext = nil
if localctx != nil { t = localctx.(*FieldContext) }
return p.Field_Sempred(t, predIndex)
var t *FieldContext = nil
if localctx != nil {
t = localctx.(*FieldContext)
}
return p.Field_Sempred(t, predIndex)
default:
panic("No predicate with index: " + fmt.Sprint(ruleIndex))
@@ -27,11 +27,9 @@ func (p *ApiParserParser) Sempred(localctx antlr.RuleContext, ruleIndex, predInd
func (p *ApiParserParser) Field_Sempred(localctx antlr.RuleContext, predIndex int) bool {
switch predIndex {
case 0:
return isNormal(p)
return isNormal(p)
default:
panic("No predicate with index: " + fmt.Sprint(predIndex))
}
}