Переглянути джерело

Merged revisions 7816,7818-7819,7828,7834 via svnmerge from
svn+ssh://svn.freepascal.org/FPC/svn/fpc/trunk

........
r7816 | daniel | 2007-06-26 08:57:20 +0200 (di, 26 jun 2007) | 2 lines

* Use ptruint instead of ptrint.

........
r7818 | daniel | 2007-06-26 09:52:55 +0200 (di, 26 jun 2007) | 2 lines

* Fix bug found by new hint.

........
r7819 | daniel | 2007-06-26 10:24:09 +0200 (di, 26 jun 2007) | 2 lines

* Fix another bug found by new hint.

........
r7828 | hajny | 2007-06-26 23:08:37 +0200 (di, 26 jun 2007) | 1 line

* fix from r7819 extended to more platforms
........
r7834 | daniel | 2007-06-27 22:28:45 +0200 (wo, 27 jun 2007) | 3 lines

* When adding the start offset of the parameters, process chained
paralocs too.

........

git-svn-id: branches/fixes_2_2@7836 -

daniel 18 роки тому
батько
коміт
987e405888

+ 8 - 3
compiler/x86_64/cpupara.pas

@@ -550,9 +550,14 @@ unit cpupara;
             for i:=0 to paras.count-1 do
               begin
                 hp:=tparavarsym(paras[i]);
-                with hp.paraloc[side].location^ do
-                  if (loc=LOC_REFERENCE) then
-                    inc(reference.offset,target_info.first_parm_offset);
+                paraloc:=hp.paraloc[side].location;
+                while paraloc<>nil do
+                  begin
+                    with paraloc^ do
+                     if (loc=LOC_REFERENCE) then
+                       inc(reference.offset,target_info.first_parm_offset);
+                    paraloc:=paraloc^.next;
+                  end;
               end;
           end;
       end;

+ 1 - 1
rtl/amiga/dos.pp

@@ -431,7 +431,7 @@ var
   TV: TTimeVal;
 begin
   Get_Sys_Time (@TV);
-  GetMsCount := TV.TV_Secs * 1000 + TV.TV_Micro div 1000;
+  GetMsCount := int64 (TV.TV_Secs) * 1000 + TV.TV_Micro div 1000;
 end;
 
 {******************************************************************************

+ 1 - 1
rtl/go32v2/dos.pp

@@ -151,7 +151,7 @@ end;
 
 function GetMsCount: int64;
 begin
-  GetMsCount := MemL [$40:$6c] * 55;
+  GetMsCount := int64 (MemL [$40:$6c]) * 55;
 end;
 
 

+ 2 - 2
rtl/inc/elfres32.inc

@@ -89,8 +89,8 @@ begin
         CurrentResource:=pFPCResourceInfo(pointer(FPCResourceSectionLocation^.reshash.ptr+i*sizeof(TFPCResourceInfo)));
         FPCRuntimeResourceInfoArray[i].reshash:=CurrentResource^.reshash;
         FPCRuntimeResourceInfoArray[i].restype:=CurrentResource^.restype;
-        FPCRuntimeResourceInfoArray[i].ptr:=pointer(CurrentResource^.ptr)+PtrInt(FPCResourceSectionLocation^.resdata.ptr);
-        FPCRuntimeResourceInfoArray[i].name:=pchar(CurrentResource^.name)+PtrInt(FPCResourceSectionLocation^.ressym.ptr);
+        FPCRuntimeResourceInfoArray[i].ptr:=pointer(CurrentResource^.ptr)+ptruint(FPCResourceSectionLocation^.resdata.ptr);
+        FPCRuntimeResourceInfoArray[i].name:=pchar(CurrentResource^.name)+ptruint(FPCResourceSectionLocation^.ressym.ptr);
         FPCRuntimeResourceInfoArray[i].size:=CurrentResource^.size;
       end;
     end;

+ 1 - 1
rtl/morphos/dos.pp

@@ -431,7 +431,7 @@ var
   TV: TTimeVal;
 begin
   Get_Sys_Time (@TV);
-  GetMsCount := TV.TV_Secs * 1000 + TV.TV_Micro div 1000;
+  GetMsCount := int64 (TV.TV_Secs) * 1000 + TV.TV_Micro div 1000;
 end;
 
 {******************************************************************************

+ 1 - 1
rtl/netware/dos.pp

@@ -105,7 +105,7 @@ end;
 
 function GetMsCount: int64;
 begin
-  GetMsCount := Nwserv.GetCurrentTicks * 55;
+  GetMsCount := int64 (Nwserv.GetCurrentTicks) * 55;
 end;
 
 

+ 1 - 1
rtl/netwlibc/dos.pp

@@ -143,7 +143,7 @@ var
   tz : TimeZone;
 begin
   FPGetTimeOfDay (tv, tz);
-  GetMsCount := tv.tv_Sec * 1000 + tv.tv_uSec div 1000;
+  GetMsCount := int64 (tv.tv_Sec) * 1000 + tv.tv_uSec div 1000;
 end;
 
 

+ 1 - 1
rtl/objpas/dateutil.inc

@@ -958,7 +958,7 @@ Var
 
 begin
   DecodeTime(AValue,H,M,S,MS);
-  Result:=((M+(H+((DayOfTheYear(AValue)-1)*24))*60)*60+S)*1000+MS;
+  Result:=((M+(H+((int64(DayOfTheYear(AValue))-1)*24))*60)*60+S)*1000+MS;
 end;
 
 

+ 1 - 1
rtl/unix/dos.pp

@@ -296,7 +296,7 @@ var
 {  tz : TimeZone;}
 begin
   FPGetTimeOfDay (@tv, nil {,tz});
-  GetMsCount := tv.tv_Sec * 1000 + tv.tv_uSec div 1000;
+  GetMsCount := int64(tv.tv_Sec) * 1000 + tv.tv_uSec div 1000;
 end;
 
 

+ 1 - 1
rtl/watcom/dos.pp

@@ -151,7 +151,7 @@ end;
 
 function GetMsCount: int64;
 begin
-  GetMsCount := MemL [$40:$6c] * 55;
+  GetMsCount := int64 (MemL [$40:$6c]) * 55;
 end;
 
 {******************************************************************************