﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
5579	New Frontend does not check for circular dependencies in parameter bindings	Karim Adbdelhak	Per Östlund	"Consider following model:
{{{
model circularBinding
  parameter Boolean b1 = true;
  parameter Real f = if b1 then g else 2.0;
  parameter Real g = if b1 then 2.0 else f;
end circularBindung;
}}}
The old frontend detected the (seemingly) possible circular dependency in the bindings of {{{f}}} and {{{g}}} and marked the condition {{{b1}}} with {{{final=true}}}. The new frontend does not do that and therefore it fails in the backend.

 The minimal thing that is needed is that {{{{b1}}} has to get {{{final= true}}}, that is what the old frontend does and {{{evaluateParameters}}} in combination with {{{simplifyIfEquations}}} takes care of it. But those models are mostly useless right now and it would be great to get rid of them or at least thin them out (i guess some form of simplification for if equations has to stay).

Optimally the frontend would take care of it, detect and resolve the structural parameters.

Also related: 
The old frontend evaluated protected parameters whereas the new frontend does not. As far as i know they can't be changed after compilation anyways, so what is the correct way to handle it?"	defect	new	high	Future	New Instantiation				
