aboutsummaryrefslogtreecommitdiff
path: root/inline_parser.go
diff options
context:
space:
mode:
authorShulhan <ms@kilabit.info>2024-03-05 17:18:23 +0700
committerShulhan <ms@kilabit.info>2024-03-05 18:00:34 +0700
commit2a51183943b29f9011d2ffa439a1cce502ce36cb (patch)
treed66c54b6aff94431f51c03089bca15a302ca9d49 /inline_parser.go
parent346500242a3541bf9f7d8ce008dcf2ef6950e9a0 (diff)
downloadasciidoctor-go-2a51183943b29f9011d2ffa439a1cce502ce36cb.tar.xz
all: comply with linter recommendations
Diffstat (limited to 'inline_parser.go')
-rw-r--r--inline_parser.go12
1 files changed, 12 insertions, 0 deletions
diff --git a/inline_parser.go b/inline_parser.go
index 09aa5a1..2f18aaf 100644
--- a/inline_parser.go
+++ b/inline_parser.go
@@ -73,6 +73,12 @@ func (pi *inlineParser) do() {
pi.prev = pi.c
continue
}
+
+ // We use if-condition with "continue" to break and continue
+ // the for-loop, so it is not possible to use switch-case
+ // here.
+ //
+ //nolint:gocritic
if pi.c == '+' {
if pi.isEscaped {
pi.escape()
@@ -250,6 +256,12 @@ func (pi *inlineParser) do() {
pi.escape()
continue
}
+
+ // We use if-condition with "continue" to break and
+ // continue the for-loop, so it is not possible
+ // to use switch-case here.
+ //
+ //nolint:gocritic
if pi.nextc == '<' {
if pi.parseCrossRef() {
continue