Skip to content

Commit

Permalink
- Removed Absyn.CREF_INVALID, it's not been used for a while.
Browse files Browse the repository at this point in the history
- Updated bootstrapping tarball.


git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@18415 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
perost committed Dec 5, 2013
1 parent f43cca0 commit 4b6a5a2
Show file tree
Hide file tree
Showing 10 changed files with 0 additions and 79 deletions.
16 changes: 0 additions & 16 deletions Compiler/FrontEnd/Absyn.mo
Original file line number Diff line number Diff line change
Expand Up @@ -990,12 +990,6 @@ uniontype ComponentRef "A component reference is the fully or partially qualifie

record WILD end WILD;
record ALLWILD end ALLWILD;

record CREF_INVALID
"Used to indicate a cref that could not be found, which is legal as long as
it's not used."
ComponentRef componentRef;
end CREF_INVALID;
end ComponentRef;


Expand Down Expand Up @@ -2098,7 +2092,6 @@ algorithm

case (ALLWILD(), _) then (inCref, inTuple);
case (WILD(), _) then (inCref, inTuple);
case (CREF_INVALID(componentRef = _), _) then (inCref, inTuple);
end match;
end traverseExpBidirCref;

Expand Down Expand Up @@ -2599,8 +2592,6 @@ algorithm
then s1;
case (ALLWILD()) then "__";
case (WILD()) then "_";
case (CREF_INVALID(componentRef = child))
then printComponentRefStr(child);
end match;
end printComponentRefStr;

Expand Down Expand Up @@ -3457,7 +3448,6 @@ algorithm
case (BOOL(value = _),_,_) then {};
case (CREF(componentRef = ALLWILD()),_,_) then {};
case (CREF(componentRef = WILD()),_,_) then {};
case (CREF(componentRef = CREF_INVALID(componentRef = _)), _,_) then {};
case (CREF(componentRef = cr),false,_) then {cr};

case (CREF(componentRef = (cr)),true,_)
Expand Down Expand Up @@ -4871,7 +4861,6 @@ algorithm
case(id, CREF_FULLYQUALIFIED(cref)) then findIteratorInCRef(id,cref);
case (_,ALLWILD()) then {};
case (_,WILD()) then {};
case (_, CREF_INVALID(componentRef = _)) then {};
end match;
end findIteratorInCRef;

Expand Down Expand Up @@ -5418,11 +5407,6 @@ algorithm
cref2 = crefInsertSubscriptLstLst2(cref, subs);
then
crefMakeFullyQualified(cref2);
case (CREF_INVALID(componentRef = cref), subs)
equation
cref2 = crefInsertSubscriptLstLst2(cref, subs);
then
CREF_INVALID(cref2);
end matchcontinue;
end crefInsertSubscriptLstLst2;

Expand Down
16 changes: 0 additions & 16 deletions Compiler/FrontEnd/Dump.mo
Original file line number Diff line number Diff line change
Expand Up @@ -3436,13 +3436,6 @@ algorithm
then
();

case Absyn.CREF_INVALID(componentRef = cr)
equation
Print.printBuf("Absyn.CREF_INVALID(\"");
printComponentRef(cr);
Print.printBuf("\")");
then
();
end match;
end printComponentRef;

Expand Down Expand Up @@ -3507,8 +3500,6 @@ algorithm

case Absyn.WILD() then Util.if_(Config.acceptMetaModelicaGrammar(),"_","");

case Absyn.CREF_INVALID(componentRef = cr)
then printComponentRefStr(cr);
end match;
end printComponentRefStr;

Expand Down Expand Up @@ -5259,13 +5250,6 @@ algorithm
equation
Print.printBuf("record Absyn.WILD end Absyn.WILD;");
then ();
case Absyn.CREF_INVALID(componentRef = p)
equation
Print.printBuf("record Absyn.CREF_INVALID componentRef = ");
printComponentRefAsCorbaString(p);
Print.printBuf(" end Absyn.CREF_INVALID;");
then
();
end match;
end printComponentRefAsCorbaString;

Expand Down
3 changes: 0 additions & 3 deletions Compiler/FrontEnd/FGraphLookup.mo
Original file line number Diff line number Diff line change
Expand Up @@ -1319,9 +1319,6 @@ algorithm
then
cref;
// Otherwise, mark the cref as invalid, which is ok as long as it's not
// actually used anywhere.
//else then Absyn.CREF_INVALID(inCref);
else inCref;
end matchcontinue;
Expand Down
3 changes: 0 additions & 3 deletions Compiler/FrontEnd/NFSCodeLookup.mo
Original file line number Diff line number Diff line change
Expand Up @@ -1631,9 +1631,6 @@ algorithm
then
cref;

// Otherwise, mark the cref as invalid, which is ok as long as it's not
// actually used anywhere.
//else then Absyn.CREF_INVALID(inCref);
else inCref;

end matchcontinue;
Expand Down
9 changes: 0 additions & 9 deletions Compiler/FrontEnd/Static.mo
Original file line number Diff line number Diff line change
Expand Up @@ -6479,15 +6479,6 @@ algorithm
Error.addSourceMessage(Error.WRONG_TYPE_OR_NO_OF_ARGS, {s,prestr}, info);
then fail();

case (_, _, Absyn.CREF_INVALID(componentRef = fn), _, _, _, _, _, _, _)
equation
fnstr = Absyn.printComponentRefStr(fn);
env_str = Env.printEnvPathStr(inEnv);
Error.addSourceMessage(Error.LOOKUP_FUNCTION_ERROR,
{fnstr, env_str}, info);
then
fail();

/* Interactive mode */
case (cache,env,fn,args,nargs,(impl as true),st,pre,_,_)
equation
Expand Down
15 changes: 0 additions & 15 deletions Compiler/OpenModelicaBootstrappingHeader.h
Original file line number Diff line number Diff line change
Expand Up @@ -3597,21 +3597,6 @@ extern struct record_description Absyn_ComponentRef_ALLWILD__desc;
static const MMC_DEFSTRUCTLIT(Absyn__ALLWILD__struct,1,7) {&Absyn_ComponentRef_ALLWILD__desc}};
static void *Absyn__ALLWILD = MMC_REFSTRUCTLIT(Absyn__ALLWILD__struct);
#ifdef ADD_METARECORD_DEFINITIONS
#ifndef Absyn_ComponentRef_CREF__INVALID__desc_added
#define Absyn_ComponentRef_CREF__INVALID__desc_added
ADD_METARECORD_DEFINITIONS const char* Absyn_ComponentRef_CREF__INVALID__desc__fields[1] = {"componentRef"};
ADD_METARECORD_DEFINITIONS struct record_description Absyn_ComponentRef_CREF__INVALID__desc = {
"Absyn_ComponentRef_CREF__INVALID",
"Absyn.ComponentRef.CREF_INVALID",
Absyn_ComponentRef_CREF__INVALID__desc__fields
};
#endif
#else /* Only use the file as a header */
extern struct record_description Absyn_ComponentRef_CREF__INVALID__desc;
#endif
#define Absyn__CREF_5fINVALID_3dBOX1 8
#define Absyn__CREF_5fINVALID(componentRef) (mmc_mk_box2(8,&Absyn_ComponentRef_CREF__INVALID__desc,componentRef))
#ifdef ADD_METARECORD_DEFINITIONS
#ifndef Absyn_Path_QUALIFIED__desc_added
#define Absyn_Path_QUALIFIED__desc_added
ADD_METARECORD_DEFINITIONS const char* Absyn_Path_QUALIFIED__desc__fields[2] = {"name","path"};
Expand Down
4 changes: 0 additions & 4 deletions Compiler/Template/AbsynDumpTV.mo
Original file line number Diff line number Diff line change
Expand Up @@ -245,10 +245,6 @@ package Absyn

record WILD end WILD;
record ALLWILD end ALLWILD;

record CREF_INVALID
ComponentRef componentRef;
end CREF_INVALID;
end ComponentRef;

uniontype Path
Expand Down
8 changes: 0 additions & 8 deletions Compiler/Template/AbsynDumpTpl.mo
Original file line number Diff line number Diff line change
Expand Up @@ -983,7 +983,6 @@ algorithm
match(in_txt, in_a_cref)
local
Tpl.Text txt;
Absyn.ComponentRef i_cref;
Absyn.ComponentRef i_componentRef;
list<Absyn.Subscript> i_subscripts;
Absyn.Ident i_name;
Expand Down Expand Up @@ -1023,13 +1022,6 @@ algorithm
txt = Tpl.writeTok(txt, Tpl.ST_STRING("__"));
then txt;

case ( txt,
(i_cref as Absyn.CREF_INVALID(componentRef = _)) )
equation
txt = Tpl.writeTok(txt, Tpl.ST_STRING("INVALID("));
txt = dumpCref(txt, i_cref);
then txt;

case ( txt,
_ )
then txt;
Expand Down
1 change: 0 additions & 1 deletion Compiler/Template/AbsynDumpTpl.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,6 @@ match cref
case CREF_FULLYQUALIFIED(__) then '.<%dumpCref(componentRef)%>'
case WILD(__) then '/*_*/'
case ALLWILD(__) then '__'
case CREF_INVALID(__) then 'INVALID(<%dumpCref(cref)%>'
end dumpCref;

template dumpFunctionArgs(Absyn.FunctionArgs args)
Expand Down
4 changes: 0 additions & 4 deletions Compiler/Template/SCodeTV.mo
Original file line number Diff line number Diff line change
Expand Up @@ -250,10 +250,6 @@ package Absyn

record WILD end WILD;
record ALLWILD end ALLWILD;

record CREF_INVALID
ComponentRef componentRef;
end CREF_INVALID;
end ComponentRef;

uniontype Path
Expand Down

0 comments on commit 4b6a5a2

Please sign in to comment.