Uh oh!
There was an error while loading. Please reload this page.
Fix #14334: Support more msbuild conditional constructs - #8039
Fix #14334: Support more msbuild conditional constructs#8039autoantwort wants to merge 1 commit into
Conversation
Uh oh!
There was an error while loading. Please reload this page.
firewave
commented
Dec 16, 2025
Thanks for your contribution. Please avoid adding test-only code in the production code. See e04019c for an approach. If you inherit from |
Uh oh!
There was an error while loading. Please reload this page.
| tokenlist.createAst(); | ||
| for (const Token *tok = tokenlist.front(); tok; tok = tok->next()) { | ||
| if (tok->str() == "(" && tok->astOperand1() && tok->astOperand2()) { | ||
| // TODO: this is wrong - it is Contains() not Equals() |
There was a problem hiding this comment.
We should have filed a ticket for this since fixing it is a behavior change. Are you able to do that or should I file one?
There was a problem hiding this comment.
Could you do that? :)
There was a problem hiding this comment.
Will do later. I want to have a reproducer first.
autoantwort
commented
Dec 17, 2025
Currently |
firewave
commented
Dec 17, 2025
Sorry that I missed that.
Let's get the CI to pass first and the other stuff addressed and then I will have another look. It won't be merged before we made the 2.19 release anyways. |
a327364 to
e674fb6Compare0818e64 to
f0810d5CompareUh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
c1c4c5e to
35be150CompareUh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
bf81c63 to
f9f9c64Compareautoantwort
commented
Jan 4, 2026
The selfcheck failure seems like an cppcheck error: without I get |
b4b0a1f to
738a14aCompareautoantwort
commented
Jan 8, 2026
I only rebased with main |
danmar
left a comment
There was a problem hiding this comment.
Why don't you tokenize as before? That would get rid of a lot of the string handling. And it is more flexible it will allow spaces between tokens. As far as I see your code requires for instance that there is no spaces in $(Configuration) .
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
autoantwort
commented
Jan 8, 2026
Because I only know that it didn't worked. Does the tokenizer know how to tokenize in strings? Feel free do create a PR at my feature branch :) |
451b62b to
16b0237Comparedanmar
commented
Jan 13, 2026
hmm.. I have tried to improve the existing functionality instead of rewriting it: |
autoantwort
commented
Jan 13, 2026
I fixed the first for to ASSERT_THROW_EQUALS_2(cppcheck::testing::evaluateVcxprojCondition("And", "", ""), std::runtime_error, "Invalid condition: 'And'");
ASSERT_THROW_EQUALS_2(cppcheck::testing::evaluateVcxprojCondition("Or", "", ""), std::runtime_error, "Invalid condition: 'Or'");
ASSERT_THROW_EQUALS_2(cppcheck::testing::evaluateVcxprojCondition("!", "", ""), std::runtime_error, "Invalid condition: '!'");
ASSERT_THROW_EQUALS_2(cppcheck::testing::evaluateVcxprojCondition("'' == '' And ", "", ""), std::runtime_error, "Missing operator");but after that the program simply crashes with a read access violation. |
Thanks! I have fixed that in my PR. I would say that my exception texts are not very good so please feel free to adjust and improve them. What the cppcheck output is.. that is something that should be tested in test/cli/.. If you are not good at pytest I can add a test for it but I would like that you create some minimal vcxproj file for me then that can be used in such test. |
0b2826a to
5cd4d50Compare5cd4d50 to
e24c10cComparedanmar
commented
Feb 10, 2026
it's not clear to me directly why we get those unmatchSuppression warnings in selfcheck but looks like it more or less works! |
danmar
commented
Apr 11, 2026
I merged #8258 that I guess provided the same code. So I close this PR. Feel free to reopen and cleanup if there is something important in this PR. |



No description provided.