Browse Source

+ support 16-bit pointer size in TFPGInterfacedObjectList.IndexOf

Nikolay Nikolov 2 years ago
parent
commit
538f8201e2
1 changed files with 3 additions and 1 deletions
  1. 3 1
      rtl/objpas/fgl.pp

+ 3 - 1
rtl/objpas/fgl.pp

@@ -1265,7 +1265,9 @@ end;
 function TFPGInterfacedObjectList.IndexOf(const Item: T): Integer;
 begin
   Result :=
-{$if sizeof(pointer) = sizeof(dword)}
+{$if sizeof(pointer) = sizeof(word)}
+    IndexWord
+{$elseif sizeof(pointer) = sizeof(dword)}
     IndexDWord
 {$elseif sizeof(pointer) = sizeof(qword)}
     IndexQWord