go-lang-plugin-org/go-lang-idea-plugin

fallthrough statement out of place

elbaro opened this issue · 1 comments

  • Plugin version (or commit hash): v.172.3968.45
  • IDE name and version: IntelliJ 172.4155.36
  • Java version:
  • OS name and version:

The following code is from the official wiki: https://github.com/golang/go/wiki/Switch
It runs fine but the inspection thinks fallthrough statement out of place

switch {
case f():
	if g() {
		goto nextCase // Works now!
	}
	h()
    break
nextCase:
    fallthrough
default:
	error()
}