Browse Source

* Git Patch 181ab62eacfe31cfdf76d704564e289a91e88487 from Maciej

git-svn-id: trunk@39375 -
michael 7 years ago
parent
commit
f1673275c7
1 changed files with 10 additions and 2 deletions
  1. 10 2
      packages/rtl-generics/src/generics.defaults.pas

+ 10 - 2
packages/rtl-generics/src/generics.defaults.pas

@@ -229,8 +229,8 @@ type
       _Release: CodePointer;
       _Release: CodePointer;
       Equals: CodePointer;
       Equals: CodePointer;
       GetHashCode: CodePointer;
       GetHashCode: CodePointer;
-      __Reserved: Pointer; // initially or TExtendedEqualityComparerVMT compatibility
-                           // (important when ExtendedEqualityComparer is calling Binary method)
+      __Reserved: CodePointer; // initially or TExtendedEqualityComparerVMT compatibility
+                               // (important when ExtendedEqualityComparer is calling Binary method)
       __ClassRef: THashFactoryClass; // hidden field in VMT. For class ref THashFactoryClass
       __ClassRef: THashFactoryClass; // hidden field in VMT. For class ref THashFactoryClass
     end;
     end;
 
 
@@ -513,6 +513,7 @@ type
 
 
   TExtendedHashService = class(THashService)
   TExtendedHashService = class(THashService)
   public
   public
+    class function LookupEqualityComparer(ATypeInfo: PTypeInfo; ASize: SizeInt): Pointer; override;
     class function LookupExtendedEqualityComparer(ATypeInfo: PTypeInfo; ASize: SizeInt): Pointer; virtual; abstract;
     class function LookupExtendedEqualityComparer(ATypeInfo: PTypeInfo; ASize: SizeInt): Pointer; virtual; abstract;
   end;
   end;
 
 
@@ -2187,6 +2188,13 @@ begin
   Result.SelectorInstance := ASelectorInstance;
   Result.SelectorInstance := ASelectorInstance;
 end;
 end;
 
 
+{ TExtendedHashService }
+
+class function TExtendedHashService.LookupEqualityComparer(ATypeInfo: PTypeInfo; ASize: SizeInt): Pointer;
+begin
+  Result := LookupExtendedEqualityComparer(ATypeInfo, ASize);
+end;
+
 { THashService }
 { THashService }
 
 
 class function THashService<T>.SelectIntegerEqualityComparer(ATypeData: PTypeData; ASize: SizeInt): Pointer;
 class function THashService<T>.SelectIntegerEqualityComparer(ATypeData: PTypeData; ASize: SizeInt): Pointer;