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

Error message for 1<<"12" #2091

Open
xushiwei opened this issue Feb 4, 2025 · 0 comments
Open

Error message for 1<<"12" #2091

xushiwei opened this issue Feb 4, 2025 · 0 comments
Labels

Comments

@xushiwei
Copy link
Member

xushiwei commented Feb 4, 2025

The following program sample.gop triggers an unexpected result

echo 1<<"12"

Expected result

sample.gop:1:1: cannot convert "12" (untyped string constant) to type uint

Got

sample.gop:1:1: compile `echo 1<<"12"`: constant value is overflow

Gop Version

v1.2.6

Additional Notes

No response

@xushiwei xushiwei added the bug label Feb 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant