+1

[W521] False positive when Result is set in a function call

Lübbe Onken 9 years ago 0

Example:


function MyObj.Convert(Value: String): THexWert;
begin
  if Assigned(fConversion) then
    fConversion.Convert(Wert, Result)
  else
    Result := 0;
end;

I think it's safe to assume that fConversion.Convert now has the responsibility to set Result, if it is a var parameter of fConversion.Convert.


possibly related to http://fixinsight.userecho.com/topic/677142-w521-false-positive-with-result/