-
Notifications
You must be signed in to change notification settings - Fork 144
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 Wcast-qual warning. #241
Conversation
8219881
to
d47b123
Compare
d47b123
to
78af7ae
Compare
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.
LGTM, one suggestion for improvement.
Which compiler / compiler flags did you use to find these issues? Is this something we could have caught via CI?
gcc uses -Werror -Wcast-qual build fail: [haonanya]$ /usr/bin/gcc -DCL_ENABLE_LAYERS -DCL_NO_NON_ICD_DISPATCH_EXTENSION_PROTOTYPES -DCL_TARGET_OPENCL_VERSION=300 -DOPENCL_ICD_LOADER_VERSION_MAJOR=3 -DOPENCL_ICD_LOADER_VERSION_MINOR=0 -DOPENCL_ICD_LOADER_VERSION_REV=6 -DOpenCL_EXPORTS -I/export/users/haonanya/OpenCL-CTS/OpenCL-Headers -I/export/users/haonanya/OpenCL-CTS/OpenCL-ICD-Loader/build -I/export/users/haonanya/OpenCL-CTS/OpenCL-ICD-Loader/loader -fPIC -std=gnu99 -Werror -Wcast-qual -MD -MT CMakeFiles/OpenCL.dir/loader/linux/icd_linux.c.o -MF CMakeFiles/OpenCL.dir/loader/linux/icd_linux.c.o.d -o CMakeFiles/OpenCL.dir/loader/linux/icd_linux.c.o -c /export/users/haonanya/OpenCL-CTS/OpenCL-ICD-Loader/loader/linux/icd_linux.c |
@MathiasMagnus, can you please take a review? I don't know if 1 approval can land the PR, thanks very much. |
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.
LGTM.
I agree with @bashbaug, if we don't test for it, we will break it again. |
I created #242 so we don't lose track of the CI improvements. Merging. |
No description provided.