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

using consts in the same line #39266

Closed
eliashanna78 opened this issue May 27, 2020 · 1 comment
Closed

using consts in the same line #39266

eliashanna78 opened this issue May 27, 2020 · 1 comment

Comments

@eliashanna78
Copy link

@eliashanna78 eliashanna78 commented May 27, 2020

Hi,
I don't know if this is intended, but using:
const x,y,z := 1,2,x+y doesn't compile, or at least in GoLand.
Is this an intended error? because before compiling I don't get any kind of warning.
and if I split this to two lines it will work.
Thanks,
Elias

@davecheney
Copy link
Contributor

@davecheney davecheney commented May 27, 2020

This is a syntax error

https://play.golang.org/p/v5G80Dgu-2c

Thank you for raising this issue. Unlike many projects on GitHub, the Go project does not use its bug tracker for general discussion or asking questions. We only use our bug tracker for tracking bugs and tracking proposals going through the Proposal Process.

Please see https://golang.org/wiki/Questions for good places to ask questions.

@davecheney davecheney closed this May 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.