﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
4300	MetaModelica type checking fail with function pointers	Per Östlund	Martin Sjölund	"This script fails without any error message:
{{{#!mo
setCommandLineOptions(""-g=MetaModelica"");

loadString(""
  uniontype U
    record R
      String path;
    end R;

    function name
      input U u;
      output String name = u.path;
    end name;
  end U;

  function typeCheckFail
  protected
    U u = U.R(\""test\"");
  algorithm
    print(u.name); // Oops, should've been u.path.
  end typeCheckFail;
""); getErrorString();

typeCheckFail(); getErrorString();
}}}
In other words, calling a function expecting e.g. a string with a function pointer just silently fails. Using --showErrorMessages shows nothing, but replacing the argument with e.g. an integer does produce the expected error."	defect	new	normal	Future	MetaModelica	v1.12.0			
