Not sure if this is possible, but I just found a memory leak that might have been caught with static analysis :
constructor TProjectParameterCollection.Create;
begin
inherited Create;
FParameters := TList<IProjectParameter>.Create;
end;
destructor TProjectParameterCollection.Destroy;
begin
Clear;
FParameters := nil; // << should be FParameters.Free;
inherited;
end;
I guess the rule could be defined as ".Free never called on object" ??
Just an idea.