This issue tracker is closed. Please visit UPPAAL issue tracker at Github instead.

Bug 535

Summary: struct in function break assertion
Product: UPPAAL Reporter: Marius Mikučionis <marius>
Component: EngineAssignee: Alexandre David <adavid>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P2    
Version: unspecified   
Hardware: PC   
OS: All   
Architecture:

Description Marius Mikučionis 2012-03-20 16:48:41 CET
Suppose you have the following code:

typedef struct {
  int x, y;
} point_t;

int len = 0;
point_t list[5];

void hello(point_t i)
{
   list[len++] = i;
}


Uppaal dies with assertion in utap/type.cpp while parsing the struct arguments in function definition.
The problem is since revision 5006 where clock copying was introduced in verifier/Compiler.cpp:2282.
It seems that the code assumes that there can be only arrays of clocks, clocks cannot be in struct but then it chokes on struct of int.

The problem does not manifest in NDEBUG build, but I am not sure about the scope of the problem.
Comment 1 Marius Mikučionis 2012-03-20 17:40:07 CET
fixed in revision 5025