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

cmd/go2go: += operation causes problems over string and int #39641

Closed
james-antill opened this issue Jun 17, 2020 · 2 comments
Closed

cmd/go2go: += operation causes problems over string and int #39641

james-antill opened this issue Jun 17, 2020 · 2 comments

Comments

@james-antill
Copy link

What version of Go are you using (go version)?

$ go version

https://go2goplay.golang.org/ as of 2020-06-17 06:53 UTC

What did you do?

https://go2goplay.golang.org/p/y9j7WlgNHWy

What did you expect to see?

If you change Adder to be just int or just string, then everything works, only when both are used at once does it fail.

What did you see instead?

invalid operation: operator + not defined for ret (variable of type T)

@mattn
Copy link
Member

mattn commented Jun 17, 2020

Same issue #39623 ?

@davecheney
Copy link
Contributor

Duplicate of #39623

@davecheney davecheney marked this as a duplicate of #39623 Jun 17, 2020
@golang golang locked and limited conversation to collaborators Jun 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants