Opened 10 years ago

Closed 2 years ago

#791 closed defect (fixed)

Type checks for inter-dependent array sizes

Reported by: Jesper Mattsson Owned by: Jesper Mattsson
Priority: major Milestone: Future
Component: Modelica/FrontEnd Version: trunk
Keywords: Cc:

Description

When the array sizes of inputs to a function depends on each other, check that these dependencies are fulfilled.

Example:

model A
 function f
  input Real a[:];
  input Real b[size(a,1)];
  output Real c := a * b;
 algorithm
 end f;

 Real x = f({1,2}, {3,4,5});
end A

Here the call to f should generate an error.

Change History (6)

comment:1 Changed 10 years ago by jakesson

Milestone: 1.3.x

comment:2 Changed 9 years ago by jakesson

Milestone: 1.3.x1.4.x
Owner: set to Jesper Mattsson
Status: newassigned

comment:3 Changed 9 years ago by Jesper Mattsson

Milestone: 1.4.x1.5.x

comment:4 Changed 9 years ago by Jesper Mattsson

Milestone: 1.5.xFuture

comment:5 Changed 8 years ago by Jesper Mattsson

See also test cases InputAsArraySize8 & InputAsArraySize10, committed in r2887.

comment:6 Changed 2 years ago by Jesper Mattsson

Resolution: fixed
Status: assignedclosed

Fixed in other tickets.

Note: See TracTickets for help on using tickets.