This commit fixes `RecordedInvocation` and `RuntimeHintsInvocationsAssert` so that they don't refer to the recorded instance for static calls. This also consistently resolves the `TypeReference` of recorded instances. Fixes gh-28907
This commit fixes `RecordedInvocation` and `RuntimeHintsInvocationsAssert` so that they don't refer to the recorded instance for static calls. This also consistently resolves the `TypeReference` of recorded instances. Fixes gh-28907