-
Notifications
You must be signed in to change notification settings - Fork 72
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 build warnings #347
Comments
`c` is not initialized when we check it for a value and conditionally free a location in memory! That's undefined behavior, and could lead to a crash. Fixes this warning: Core\SoarKernel\src\parsing\parser.cpp(1241) : warning C4700: uninitialized local variable 'c' used Related to #347.
MSVC++ doesn't understand `\e` as an escape sequence, so use `\033` instead. Fixes this warning: warning C4129: 'e': unrecognized character escape sequence See #347.
Currently in the process of upgrading the warning levels to -Wall (/W4 on Windows). There are a good thousand warnings there. Starting with the low-hanging fruit, I'll delete the unused variables (~100). |
and enable constructor argument reordered warnings, as they are also easy to fix and quite numerous. Continues work on #347.
Work is proceeding by adding new warnings one-at-a-time here: https://github.com/SoarGroup/Soar/blob/development/SConstruct#L233. Next goal for Windows is |
Building with -Wall, outputting everything to
And for -Wextra:
After tackling these, we can set |
There are a lot of warnings during the build. Some of them might even be real problems. I imagine they are different on windows vs. linux vs. OS X, too.
Here are the warnings I get when building from Visual Studio 2019's developer command prompt:
Here's the complete output for context: build-output.txt
The text was updated successfully, but these errors were encountered: