You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Excellent project and just getting better. Every time I compile it, I get a lot of compile warnings which don't inspire confidence though. I just have to trust that everything works.
In particular, I see a lot of warn_unused_result warnings. Could these be cleaned up in the code so that they're not generated?
The text was updated successfully, but these errors were encountered:
What OS version and what compiler are you using?
I know that ubuntu has some stupid default compile flags that triggers all kind of non-warning. The code is compiled with -Wall and -Wextra -- that is largely enough already!
Fixing 'warn_unused_result' warning often involve adding a "fake" expression around it to trick the compiler. It doesn't help the 'safety' and it makes the code less readable.
Or add -Wno-warn-unused_result to the Makefile that will make them all disappear! :-)
(there is already a line with -Wno-unused-parameter -Wno-unused-function )
Fixing 'warn_unused_result' warning often involve adding a "fake" expression around it to trick the compiler. It doesn't help the 'safety' and it makes the code less readable.
I agree, I'm just wondering how to adjust the pragmas to make the noise go away.
I added -Wno-warn-unused-result and -Wno-unused-result to line 24 of Makefile, and I am still getting a spew of ‘warn_unused_result’ [-Wunused-result] warnings. Sorry, I'm not an expert in modern day C/C++ build scaffoldings.
I'm also getting this warnings at the start of the build telling me that it doesn't understand the directive:
libmish/src/minipt.h:28:32: warning: unknown option after ‘#pragma GCC diagnostic’ kind [-Wpragmas]
Excellent project and just getting better. Every time I compile it, I get a lot of compile warnings which don't inspire confidence though. I just have to trust that everything works.
In particular, I see a lot of warn_unused_result warnings. Could these be cleaned up in the code so that they're not generated?
The text was updated successfully, but these errors were encountered: