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

Replace a few more deprecated pre-C++11 styles #1890

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

aroffringa
Copy link
Contributor

The functions std::binary_function and std::mem_fun have been deprecated in C++11, and are removed in C++20. This pull request replaces them with more modern code. Together with #1889 this removes all warnings on recent compilers. This one is fairly small.

Copy link
Member

@DaAwesomeP DaAwesomeP left a comment

Choose a reason for hiding this comment

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

I'm not really familiar with std::binary_function so I can't speak to those. I suppose we would see compile errors if it broke any typing.

Well I guess there isn't any more fun in the code! (sarcasm)

@kripton
Copy link
Member

kripton commented Feb 26, 2024

Wow, the syntax in StringUtils.cpp needs a bit getting used to. On the other hand, what we had before also was not that easy to read. I'd say: As long as this doesn't break stuff, reducing compiler warnings is a good thing!

The functions std::binary_function and std::mem_fun have been deprecated in C++11, and are removed in C++20. This pull request replaces them with more modern code. Together with OpenLightingProject#1889 this removes all warnings on recent compilers.
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.

3 participants