I have a unit which at top defines
I then have a function
function mytest: string;
begin
other_function_in_other_normal_unit(Result);
end;
...
In another unit I then have
function other_function_in_other_normal_unit(var S: string);
begin
S := 'try long string over 255 chars';
end;
...
You will now get error
Got "ShortString" expected "AnsiString"
...
It was lucky I tried the above because it was driving me nuts my strings were "cut" without I understood why

Is the above intended behavior? Or a bug? (FPC 3.0.4)