Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[NF] Variability fixes and other improvements.
- Replaced EquationScope, ClassScope and ExpOrigin with new ExpOrigin bitfield. - Removed Component.Attributes.DEFAULT and Class.Attributes.DEFAULT, constants work equally well to save memory and simplifies the code. - Set variables with no variability prefix and discrete type to be discrete so e.g. pre() works correctly. - Fixed variability of many builtin functions. - Fixed variability of relations with regards to noEvent. - Fixed variability of expressions in when-clauses. - Fixed typing of noEvent. - Added check that time, pre, edge and change isn't used in a function context. - Fixed handling of size on subscripted expressions. - Moved handling of end to typing of subscripts, since the old handling relied upon ExpOrigin being a uniontype with subscript information. - Improved handling of end to generate appropriate size expressions when the size of the dimension is unknown. - Adapted the parenthesization algorithm from Dump to NFExpression.toString to get rid of extraneous parentheses in error messages. - Fixed flattening of if-equations so the bodies of the branches aren't in reverse order compared with the conditions (oops...). Belonging to [master]: - OpenModelica/OMCompiler#2069 - OpenModelica/OpenModelica-testsuite#801
- Loading branch information