* ensure that _LookupVtableInfoEx isn't called with a type that needs special handling as we can't (or won't) really cover that using some generic RTTI handling

(cherry picked from commit db66d8f057)
This commit is contained in:
Sven/Sarah Barth 2023-03-28 23:13:34 +02:00 committed by marcoonthegit
parent 7ae9a8745a
commit 3346c3b5c2

View File

@ -3382,6 +3382,10 @@ end;
function _LookupVtableInfoEx(AGInterface: TDefaultGenericInterface; ATypeInfo: PTypeInfo; ASize: SizeInt;
AFactory: THashFactoryClass): Pointer;
begin
if ATypeInfo^.Kind in TComparerService.UseBinaryMethods then begin
System.Error(reInvalidCast);
Exit(Nil);
end;
case AGInterface of
giComparer:
Exit(