Similar to dirname(3), but with the safety of Modelica strings.
function dirname input String path; output String dirname; end dirname;