cancel
Showing results for 
Search instead for 
Did you mean: 

STVD simulator and 'return' statement

Kmax18
Senior

I am testing the STM8 SPL with the STVD IDE and Cosmic compiler. The target is a NUCLEO-8S208RB board. During simulation of the SPL example 'UART_interrupt' the function Buffercmp() in the below screenshot behaved as follows.

Observation: the statement in line 230,

return FAILED;

does not exit the function. Instead, it jumps to the next return statement in line 237,

return PASSED;

As a result the comparison passed, regardless of the comparison outcome. This behavior is not consistent, and it seems to be a simulator issue.

Question: Is this a known issue? The returned TestStatus type is an enum variable, could that be an issue? Thank you! 

0693W00000Uo7iZQAR.png

0 REPLIES 0