- Index
- » Developer
- » OpenModelica development
- » OMEdit crashes: When set record...
OMEdit crashes: When set record parameter in Function
OMEdit crashes: When set record parameter in Function
Hello,
I already sent an email to Lennart's email, but I also put the bug report here.
OMEdit crashes when a record parameter is set in a function, it looks very similar to bug 3082 which is fixed.
PS I have difficulties uploading the .mo file so I pasted it below.
Regards, Arne
model TestRecord
function setRecordFunction
output Real[3] y;
protected
Rec[3] x;
algorithm
for i in 1:3 loop
x[i].r := i;
y[i] := x[i].r;
end for;
end setRecordFunction;
record Rec
Real r;
end Rec;
model CallRecordFunction
Real[3] y;
//Real[4] y2;
equation
y = setRecordFunction();
//y2 = setRecordFunction2(4);
end CallRecordFunction;
function setRecordFunction2
input Integer N;
output Real[N] y;
protected
Rec[N] x;
algorithm
for i in 1:N loop
x[i].r := i;
y[i] := x[i].r;
end for;
end setRecordFunction2;
end TestRecord;
Re: OMEdit crashes: When set record parameter in Function
- adeas
- 454 Posts
Re: OMEdit crashes: When set record parameter in Function
Okay added a new ticket.
https://trac.openmodelica.org/OpenModelica/ticket/3245
Actually this bug is preventing my model from running, say if I baked you guys a nice cake could you fix this one first .
- Index
- » Developer
- » OpenModelica development
- » OMEdit crashes: When set record...