Make #if conditions in PSM compliant with CPP#138
Conversation
|
Thank you for contributing. This change still needs test coverage. |
|
Sure. @nagisa what are you hoping to test exactly? |
|
Well, if there are conditions under which the build fails, then a test added here would have to be failing before this change and passing after it. This probably can be as simple as somehow forcing |
299ef97 to
cfe7a41
Compare
|
Done. First commit triggers the failure in the test and second commit fixes it. Unfortunately it only tests the failure is corrected in |
|
@nagisa anything else you need here? |
|
Just to find a little free time to work on this crate.
Would setting the |
|
Yeah, that's fine if you're okay with having a different environment by default when testing locally vs in CI |
d8873ce to
3a52fad
Compare
Change-Id: I558ac060a03eb96b63f5e1697d21263c6a6a6964
3a52fad to
3c1b6c1
Compare
|
@nagisa I changed the CI workflow to add those CFLAGS where appropriate |
|
Thanks! |
Not a problem when building with
cargoproper but when we are using rules_rust in bazel, it uses our C toolchain which we use with-Wundefand-Werror, causing a compilation failure. This fixes the issue by using thedefinedpreprocessor statement (https://gcc.gnu.org/onlinedocs/cpp/Defined.html)