Skip to content

Commit

Permalink
- CheckModel.statementOutputs: add Case for DAE.STMT_BREAK
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@14172 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
Jens Frenkel committed Nov 30, 2012
1 parent 0ba3105 commit e253087
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions Compiler/FrontEnd/CheckModel.mo
Expand Up @@ -451,6 +451,7 @@ algorithm
then iht;
case(DAE.STMT_NORETCALL(exp = _),_) then iht;
case(DAE.STMT_RETURN(_),_) then iht;
case(DAE.STMT_BREAK(_),_) then iht;
// MetaModelica extension. KS
case(DAE.STMT_FAILURE(body = stmts),_)
equation
Expand Down
15 changes: 15 additions & 0 deletions Compiler/Util/Util.mo
Expand Up @@ -972,6 +972,21 @@ algorithm
out := arrayUpdate(arr,index,element::l);
end arrayCons;

public function arrayListAppend
"function for listAppend an list on an array of list"
input Integer index;
input list<Type_a> elements;
input array<list<Type_a>> arr;
output array<list<Type_a>> out;
replaceable type Type_a subtypeof Any;
protected
list<Type_a> l;
algorithm
l := arr[index];
l := listAppend(l,elements);
out := arrayUpdate(arr,index,l);
end arrayListAppend;

public function arrayCopy "function: arrayCopy
copies all values in src array into dest array.
The function fails if all elements can not be fit into dest array."
Expand Down

0 comments on commit e253087

Please sign in to comment.