﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
5518	newInst: Assert with a string parameter and unset default value can't be compiled	Karim Adbdelhak	Per Östlund	"The following model can't be compiled with ""-d=newInst"" but runs under the OF. 
{{{
model testcase
    parameter Real ThresholdA;
    parameter Real ThresholdB;
    parameter String Value;

    parameter String A = ""A"";
    parameter String B = ""B"";

    Real MyThreshold;

  equation
    assert(Value == A or Value == B,
           ""The value should be A or B"");

    if (Value == A) then
      MyThreshold = ThresholdA;
    else
      MyThreshold = ThresholdB;
    end if;
end testcase;
}}}

Setting the value of {{{Value}}} to any string solves the problem, but it is quite confusing to me that it completely breaks when its not set. The error occurs somewhere before creating a {{{BackendDAE}}}.

I tried to make this minimal example smaller, but it seems that it works when there is only one condition in the assert. I am not quite sure what the NF does different than before, but i think it has something to do with the default values of unset strings. Seems unimportant, but that it does not compile at all should be fixed."	defect	closed	critical	Future	New Instantiation		fixed	assert, string, parameter, default value	Adrian Pop
