﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
1334	Do dependency analysis in instElementList	Martin Sjölund	Martin Sjölund	"In order to instantiate Modelica.Media models, we need to instantiate elements in the order of dependencies.
First constants, then parameters, then variables.
You need to start with constants that have no dependencies on other constants in the package.
As a first step, we could simply say that constants with bindings that contain function calls are instantiated after any other constant (functions may refer to constants in this package). If this does not solve the issues, we need all dependencies in all functions called by this function, etc.

You can verify that this solves some issues in Modelica.Media by changing the order of the declared constants in packages.

Note: You cannot do the dependency analysis lazy (instElement on another element if we realize it's needed). The reason for this is that you sometimes end up with infinite loops."	task	closed	high	White December			fixed		Martin Sjölund Per Östlund
