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

incrementing/decrement on const #72

Closed
ElianHugh opened this issue Sep 23, 2024 · 1 comment
Closed

incrementing/decrement on const #72

ElianHugh opened this issue Sep 23, 2024 · 1 comment
Assignees
Labels
bug Something isn't working critical Critical issue in-progress In progress

Comments

@ElianHugh
Copy link

ElianHugh commented Sep 23, 2024

The following works as expected, and vapour flags it as an error

const x: int = 1
x = x + 1 # `x` is a constant

However, the following compiles fine (when it shouldn't)

const x: int = 1
x += 1
@JohnCoene JohnCoene self-assigned this Sep 23, 2024
@JohnCoene JohnCoene added bug Something isn't working critical Critical issue labels Sep 23, 2024
@JohnCoene
Copy link
Contributor

Indeed, that's most definitely a bug, thank you for reporting it!

@JohnCoene JohnCoene added the in-progress In progress label Sep 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working critical Critical issue in-progress In progress
Projects
None yet
Development

No branches or pull requests

2 participants