Browse Source

* variant size must be 24 bytes on 64 bit platforms

git-svn-id: trunk@3441 -
florian 19 years ago
parent
commit
2983b01109
2 changed files with 10 additions and 2 deletions
  1. 5 1
      compiler/symdef.pas
  2. 5 1
      rtl/inc/varianth.inc

+ 5 - 1
compiler/symdef.pas

@@ -2055,7 +2055,11 @@ implementation
 
     procedure tvariantdef.setsize;
       begin
-         savesize:=16;
+{$ifdef cpu64bit}
+        savesize:=24;
+{$else cpu64bit}
+        savesize:=16;
+{$endif cpu64bit}
       end;
 
 

+ 5 - 1
rtl/inc/varianth.inc

@@ -36,6 +36,8 @@ const
    varint64 = 20;
    varqword = 21;
 
+   varrecord = 36;
+
    varstrarg = $48;
    varstring = $100;
    varany = $101;
@@ -104,7 +106,9 @@ type
                      varany :  (vany : pointer);
                      vararray : (varray : pvararray);
                      varbyref : (vpointer : pointer);
-                 );
+                     { unused so far, only to fill up space }
+                     varrecord : (vrecord : pointer;precinfo : pointer);
+                );
                1:
                  (vlongs : array[0..2] of longint);
            );