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

Post/Pre increment/decrement operator confusion #226

Open
zwimer opened this issue Sep 20, 2022 · 2 comments
Open

Post/Pre increment/decrement operator confusion #226

zwimer opened this issue Sep 20, 2022 · 2 comments

Comments

@zwimer
Copy link
Contributor

zwimer commented Sep 20, 2022

Both ++a and a++ map to plus_plus, though as one the differentiation between them still exists via different overrides.

That is ++a maps to plus_plus() and a++ to plus_plus(0); which makes sense given how the operators are defined in C++.

A feature add could be changing plus_plus to post_increment / pre_increment depending on which is detected. All of this is true with -- too.

@zwimer
Copy link
Contributor Author

zwimer commented Oct 12, 2022

This was documented via #229

The rest of this issue is just a feature request at this point.

@zwimer
Copy link
Contributor Author

zwimer commented Oct 12, 2022

Feature add PR: #238

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

1 participant