Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fallthrough statement out of place #2903

Open
elbaro opened this issue Oct 2, 2017 · 1 comment
Open

fallthrough statement out of place #2903

elbaro opened this issue Oct 2, 2017 · 1 comment

Comments

@elbaro
Copy link

elbaro commented Oct 2, 2017

  • 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()
}
@zolotov
Copy link
Contributor

zolotov commented Oct 2, 2017

thanks, filed an issue here: https://youtrack.jetbrains.com/issue/GO-4547

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants