Skip to content

Commit

Permalink
Bugfix
Browse files Browse the repository at this point in the history
Tuple -> tuple
  • Loading branch information
Jan Šilar authored and OpenModelica-Hudson committed Feb 10, 2016
1 parent f7fe0d9 commit 9c66112
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 17 deletions.
12 changes: 6 additions & 6 deletions Compiler/FrontEnd/Inst.mo
Expand Up @@ -2039,9 +2039,9 @@ algorithm
list<DAE.ComponentRef> smInitialCrefs "state machine crefs of initial states";
FCore.Ref lastRef;
InstStateMachineUtil.SMNodeToFlatSMGroupTable smCompToFlatSM;
//List<Tuple<Absyn.ComponentRef,DAE.ComponentRef>> fieldDomLst;
//List<tuple<Absyn.ComponentRef,DAE.ComponentRef>> fieldDomLst;
InstUtil.DomainFieldsLst domainFieldsLst;
// list<Tuple<String,Integer>> domainNLst;
// list<tuple<String,Integer>> domainNLst;

/*// uncomment for debugging
case (cache,env,ih,store,mods,pre,csets,ci_state,className,inClassDef6,
Expand Down Expand Up @@ -3101,7 +3101,7 @@ public function instElementList
output ClassInf.State outState = inState;
output list<DAE.Var> outVars;
output ConnectionGraph.ConnectionGraph outGraph = inGraph;
//output List<Tuple<Absyn.ComponentRef,DAE.ComponentRef>> fieldDomLst = {};
//output List<tuple<Absyn.ComponentRef,DAE.ComponentRef>> fieldDomLst = {};
output InstUtil.DomainFieldsLst domainFieldsList = {};
protected
list<tuple<SCode.Element, DAE.Mod>> el;
Expand All @@ -3110,7 +3110,7 @@ protected
list<DAE.Element> dae;
list<list<DAE.Var>> varsl = {};
list<list<DAE.Element>> dael = {};
Option<Tuple<Absyn.ComponentRef,DAE.ComponentRef>> fieldDomOpt;
Option<tuple<Absyn.ComponentRef,DAE.ComponentRef>> fieldDomOpt;
list<Integer> element_order;
array<tuple<SCode.Element, DAE.Mod>> el_arr;
array<list<DAE.Var>> var_arr;
Expand Down Expand Up @@ -3228,7 +3228,7 @@ public function instElement2
output ClassInf.State outState = inState;
output list<DAE.Var> outVars = {};
output ConnectionGraph.ConnectionGraph outGraph = inGraph;
output Option<Tuple<Absyn.ComponentRef,DAE.ComponentRef>> outFieldDomOpt;
output Option<tuple<Absyn.ComponentRef,DAE.ComponentRef>> outFieldDomOpt;
protected
tuple<SCode.Element, DAE.Mod> elt;
Boolean is_deleted;
Expand Down Expand Up @@ -3343,7 +3343,7 @@ public function instElement "
output ClassInf.State outState;
output list<DAE.Var> outVars;
output ConnectionGraph.ConnectionGraph outGraph;
output Option<Tuple<Absyn.ComponentRef,DAE.ComponentRef>> outFieldDomOpt = NONE();
output Option<tuple<Absyn.ComponentRef,DAE.ComponentRef>> outFieldDomOpt = NONE();
algorithm
(outCache, outEnv, outIH, outUnitStore, outDae, outSets, outState, outVars, outGraph):=
matchcontinue (inCache, inEnv, inIH, inUnitStore, inMod, inPrefix, inState,
Expand Down
22 changes: 11 additions & 11 deletions Compiler/FrontEnd/InstUtil.mo
Expand Up @@ -8732,7 +8732,7 @@ end propagateModFinal;
//------ PDE extension: ------
//------------------------------

public type DomainFieldsLst = List<Tuple<DAE.ComponentRef,List<Absyn.ComponentRef>>>;
public type DomainFieldsLst = List<tuple<DAE.ComponentRef,List<Absyn.ComponentRef>>>;

public function elabField
//For field variables: finds the "domain" modifier,
Expand All @@ -8747,7 +8747,7 @@ public function elabField
input SourceInfo inInfo;
output DAE.Dimensions outDims;
output DAE.Mod outMod;
output Option<Tuple<Absyn.ComponentRef,DAE.ComponentRef>> outFieldDomOpt;
output Option<tuple<Absyn.ComponentRef,DAE.ComponentRef>> outFieldDomOpt;

algorithm
(outDims, outMod, outFieldDomOpt) := match(attr, inMod)
Expand Down Expand Up @@ -8869,7 +8869,7 @@ end addEach;

public function optAppendField
input DomainFieldsLst inDomFieldsLst;
input Option<Tuple<Absyn.ComponentRef,DAE.ComponentRef>> fieldDomOpt;
input Option<tuple<Absyn.ComponentRef,DAE.ComponentRef>> fieldDomOpt;
output DomainFieldsLst outDomFieldsLst;
algorithm
outDomFieldsLst := matchcontinue fieldDomOpt
Expand All @@ -8891,11 +8891,11 @@ algorithm
end optAppendField;

protected function optAppendFieldMapFun
input Tuple<DAE.ComponentRef,List<Absyn.ComponentRef>> inDomainFields;
input tuple<DAE.ComponentRef,List<Absyn.ComponentRef>> inDomainFields;
input DAE.ComponentRef domainCrToAdd;
input Absyn.ComponentRef fieldCrToAdd;
input Boolean inFound;
output Tuple<DAE.ComponentRef,List<Absyn.ComponentRef>> outDomainFields;
output tuple<DAE.ComponentRef,List<Absyn.ComponentRef>> outDomainFields;
output Boolean outFound;
algorithm
(outDomainFields, outFound) := matchcontinue (inDomainFields,inFound)
Expand All @@ -8918,7 +8918,7 @@ public function discretizePDE
//main discretization function, converts PDE into set of ODEs
input SCode.Equation inEQ;
input DomainFieldsLst inDomFieldLst;
// input list<Tuple<String,Integer>> domainNLst;
// input list<tuple<String,Integer>> domainNLst;
input List<SCode.Equation> inDiscretizedEQs;
output List<SCode.Equation> outDiscretizedEQs;
protected List<SCode.Equation> newDiscretizedEQs;
Expand Down Expand Up @@ -8992,9 +8992,9 @@ algorithm
end getDomNFields;

protected function domNFieldsFindFun
input Tuple<DAE.ComponentRef,List<Absyn.ComponentRef>> inDomFields;
input tuple<DAE.ComponentRef,List<Absyn.ComponentRef>> inDomFields;
input Absyn.ComponentRef inDomainCr;
output Option<Tuple<Integer,List<Absyn.ComponentRef>>> outOptNFields;
output Option<tuple<Integer,List<Absyn.ComponentRef>>> outOptNFields;
algorithm
outOptNFields := matchcontinue inDomFields
local
Expand Down Expand Up @@ -9127,7 +9127,7 @@ end newEQFun;
end discretizeTraverseFun;

protected function findDomF<T>
input Tuple<String,T> inTup;
input tuple<String,T> inTup;
input String name;
output Boolean found;
algorithm
Expand All @@ -9143,8 +9143,8 @@ end findDomF;
/*
public function findDomains
input SCode.Element el;
input list<Tuple<String,Integer>> domainLstIn;
output list<Tuple<String,Integer>> domainLstOut;
input list<tuple<String,Integer>> domainLstIn;
output list<tuple<String,Integer>> domainLstOut;
algorithm
//TODO: rewrite to use instantiated domain elements
domainLstOut := match el
Expand Down

0 comments on commit 9c66112

Please sign in to comment.