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

- fixed compiler warning: dead initialization (the values are never read) #332

Merged
merged 1 commit into from
Mar 6, 2016

Conversation

kratz00
Copy link
Contributor

@kratz00 kratz00 commented Mar 6, 2016

In order to not get compiler warnings about 'unused return values'
a void cast is used, which also makes it clear the the returned values
are ignored on purpose

…ead)

In order to not get compiler warnings about 'unused return values'
a void cast is used, which also makes it clear the the returned values
are ignored on purpose
@Benjamin-Dobell
Copy link
Owner

Which compilers have you tested this with?

Admittedly I don't know a lot about all the compilers out there, but a quick Google search tells me this will reintroduce the original warning I sort to avoid on GCC >= 4.6.

@kratz00
Copy link
Contributor Author

kratz00 commented Mar 6, 2016

I use gcc (GCC) 5.3.0 and I do not see the original warning.
I also tested it with clang 3.7.1 and also did not see the warning.
This project will not compile with GCC == 4.6 because of the -std=gnu++11 option.

@Benjamin-Dobell
Copy link
Owner

Alright, I'll take you word 😄

Benjamin-Dobell added a commit that referenced this pull request Mar 6, 2016
- fixed compiler warning: dead initialization (the values are never read)
@Benjamin-Dobell Benjamin-Dobell merged commit 86b7be8 into Benjamin-Dobell:master Mar 6, 2016
@kratz00 kratz00 deleted the unused_variables branch March 6, 2016 15:31
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.

2 participants