#1 2018-07-23 11:49:20

jaclas
Member
Registered: 2014-09-12
Posts: 215

GetTickCount64() - returned value type

In SynCommons GetTickCount64 is declared as function that return Int64 value:

var
  /// the number of milliseconds that have elapsed since the system was started
  // - compatibility function, to be implemented according to the running OS
  // - will use the corresponding native API function under Vista+, or
  // will emulate it for older Windows versions

  GetTickCount64: function: Int64; stdcall;

procedure RetrieveSystemInfo;
var
[...]
begin
  [...]
  GetTickCount64 := GetProcAddress(Kernel,'GetTickCount64');
  if not Assigned(GetTickCount64) then
    GetTickCount64 := @GetSystemTimeMillisecondsForXP;

but WinAPI function return UInt64:

https://msdn.microsoft.com/pl-pl/librar … s.85).aspx

Does the declaration from Int64 do not interfere with UInt64 from WinAPI?

Offline

Board footer

Powered by FluxBB