Skip to content

Commit

Permalink
- Removed erroneous check for non-replaceable class definitions in Inst.
Browse files Browse the repository at this point in the history
- Added test case redeclare/FinalRedeclareModifier2.


git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@8804 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
perost committed May 4, 2011
1 parent 89d3441 commit 376d175
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions Compiler/FrontEnd/Inst.mo
Expand Up @@ -6158,15 +6158,6 @@ algorithm
then
(cache,env_1,ih,store,dae,csets,ci_state,{},graph);

/* non replaceable class definition */
case (cache,env,ih,store,mods,pre,csets,ci_state,(SCode.CLASS(name = n,prefixes=SCode.PREFIXES(replaceablePrefix = SCode.NOT_REPLACEABLE()),info=info),_),inst_dims,impl,_,_)
equation
((classmod as DAE.REDECL(finalPrefix,_,{(_,_)}))) = Mod.lookupModificationP(mods, Absyn.IDENT(n))
"Redeclare of class definition, replaceable is false" ;
Error.addSourceMessage(Error.REDECLARE_NON_REPLACEABLE, {"class", n}, info);
then
fail();

// Classdefinition without redeclaration
case (cache,env,ih,store,mods,pre,csets,ci_state,(comp as SCode.CLASS(name = n),cmod),inst_dims,impl,_,graph)
equation
Expand Down

0 comments on commit 376d175

Please sign in to comment.