Reported by hansolsson on 15 Mar 2013 08:49 UTC
Francesco discovered this for PumpMonitoringNPSH.
A simple model demonstrating the issue is (the code contains some redundant parts):
model TwoPhasePipe
import Modelica.Media.Interfaces.PartialTwoPhaseMedium;
extends Modelica.Fluid.Pipes.StaticPipe(
redeclare replaceable partial package
Medium = PartialTwoPhaseMedium
constrainedby PartialTwoPhaseMedium);
end TwoPhasePipe;
Looking at 6.4 plug compatibility we see that there are new package constants without value (smoothValue, onePhase...). They are not "default connectable", and therefore PartialTwoPhaseMedium is not "plug compatible" with PartialMedium, and thus the redeclaration is incorrect.
This seems like an unnecessary limitation since PartiaulTwoPhaseMedium is partial and will anyway be redeclared before being used.
However, it might be that more is needed than just removing this restriction for partial classes.
Reported by hansolsson on 15 Mar 2013 08:49 UTC Francesco discovered this for PumpMonitoringNPSH.
A simple model demonstrating the issue is (the code contains some redundant parts):
Looking at 6.4 plug compatibility we see that there are new package constants without value (smoothValue, onePhase...). They are not "default connectable", and therefore PartialTwoPhaseMedium is not "plug compatible" with PartialMedium, and thus the redeclaration is incorrect.
This seems like an unnecessary limitation since PartiaulTwoPhaseMedium is partial and will anyway be redeclared before being used.
However, it might be that more is needed than just removing this restriction for partial classes.
Migrated-From: https://trac.modelica.org/Modelica/ticket/1030