-
Notifications
You must be signed in to change notification settings - Fork 42
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 NULL with nullptr #134
base: master
Are you sure you want to change the base?
Conversation
Thanks for the pull request but whole repository-wide search-and-replace of NULL with nullptr is not really the way to go nor do I see any reason to do this. Most of the affected files would be libraries anyway - mainly Box2D but I also saw SDL headers getting NULL replaced with nullptr which is not good as SDL is pure C lib (even if it's just in the comments). |
You're right, I'll rebase. |
"nor do I see any reason to do this."
|
OpenClaw/Engine/Resource/Miniz.h
Outdated
@@ -237,7 +237,7 @@ extern "C" { | |||
typedef uLong uLongf; | |||
typedef void *voidp; | |||
typedef void *const voidpc; | |||
#define Z_NULL 0 | |||
#define Z_nullptr 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is one of the reasons I don't like system/project wide search-and-replace in already working (and not maintained) codebase :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for long response time, it should be fixed now.
Yes I know the difference between NULL and nullptr ;) Any new code based on C++11/14/17 standard should use nullptr instead of NULL. Nonetheless, I really do not like the idea of even project-wide search-and-replace which in effect does not solve anything. Even more so when I do not work on this project anymore. |
Have to run in android too java runner. |
Some zeros have also been replaced.