Activity Chart Checks : (C3029) Subroutines that are used incorrectly

(C3029) Subroutines that are used incorrectly

Error In:
Correctness
Description:
User functions are used inconsistently in different expressions as in a different return type, parameter type, or number of parameters.
Note: When working with MicroC components, this test also reports situations where a subroutine is called with an actual ‘out’ parameter that is bound to an external symbol with get/set APIs.
Example:
A subroutine SUB_1 is defined as a function with two input parameters that returns an integer. An activity ACT_1 contains the following mini-spec, where Y is defined as an integer:

EV_1/Y=SUB_1(A1,B1)

 

 

A second activity on the same chart contains the following mini-spec, where Z is defined as a condition:

EV_2/Z=SUB_1(A2,B2)

 

 

The error is generated on the SUB_1 function because the return type is used as an integer in the first activity and as a condition in the second activity.
A third activity on the same chart contains the following mini-spec:

EV_3/W=SUB_1(A3,B3,C3)

The error is also generated in this case due to an inconsistent number of parameters.
Erroneous Elements:
Functions