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

fix _min and _max macros #6374

Merged
merged 3 commits into from
Aug 19, 2019
Merged

fix _min and _max macros #6374

merged 3 commits into from
Aug 19, 2019

Conversation

d-a-v
Copy link
Collaborator

@d-a-v d-a-v commented Aug 1, 2019

No description provided.

Copy link
Collaborator

@devyte devyte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This eliminates some side effects such as calling min(a++, b++) which gives an unexpected result.

@JAndrassy
Copy link
Contributor

here is some discussion above this kind of improvements of macros
https://groups.google.com/a/arduino.cc/forum/#!topic/developers/QRw4xJni75M

@d-a-v
Copy link
Collaborator Author

d-a-v commented Aug 19, 2019

I proposed there the same fixes with little echo.
This original definition hurts my eyes every time I see it.

@devyte devyte merged commit 55539ae into esp8266:master Aug 19, 2019
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

Successfully merging this pull request may close these issues.

4 participants