浏览代码

* MaxBitFlags must not exceed MaxInt atm. After r12443, MaxBitFlags was $3FFFFFFE0. "unreachable code" warning indicated that something is wrong. Please fix all warning/notes to eliminate possible coding errors...

git-svn-id: trunk@12687 -
yury 16 年之前
父节点
当前提交
8bbb39b630
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      rtl/objpas/classes/classesh.inc

+ 2 - 2
rtl/objpas/classes/classesh.inc

@@ -302,8 +302,8 @@ const
    BITSHIFT = 5;
    BITSHIFT = 5;
    MASK = 31; {for longs that are 32-bit in size}
    MASK = 31; {for longs that are 32-bit in size}
    // to further increase, signed integer limits have to be researched.
    // to further increase, signed integer limits have to be researched.
-   MaxBitRec = $7FFFFFFF Div (SizeOf(longint));  
-   MaxBitFlags = MaxBitRec * 32;
+   MaxBitFlags = $7FFFFFE0;
+   MaxBitRec = MaxBitFlags Div (SizeOf(cardinal)*8);
 type
 type
    TBitArray = array[0..MaxBitRec - 1] of cardinal;
    TBitArray = array[0..MaxBitRec - 1] of cardinal;