We are evaluating 3.1.3 of the QM tool for CPP. The code generated is not working anymore for transitions with multiple signals on them. For the case in hand, it has about 10 signals with 15 to 20 character in each name. These are separated by space and commas [LONGISH_NAME, NEXT_LONGISH_NAME, etc.]
The generated code is now wrong with the comments getting in the way of the switch cases. Hopefully, you can recreate this the same as us.
We noticed two things: In short lists of two signals, this works fine. And if you remove all the spaces in the long list (and leave the commas), this also works but this is really ugly on the screen in the state machine.
So, we will not be using this version and wait for a hopeful fix in the next version.
This is not a problem in QM 3.0.1.
Anonymous
I can't reproduce the problem. The comma-separated lists of triggers generate correct code that compiles. The difference from QM 3.0.1 is that the model-reference-comments now are longer, because the whole list of triggers is included in the comment. This will be corrected in the next QM release to abbreviate the longer lists, but the code is correct.
Perhaps you could attach an example of a model that generates incorrect code. This would be very helpful.
--MMS
Yes, that is it. So what happens is that the "new" generated comments are not correctly commented out and cause compile issues. The defines in red below should be in comments.
I attached the model.
Fixed in QM 3.2.2.
--MMS