mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-09 15:26:29 +02:00
* patch by Bi0T1N: fix result type of InterlockedCompareExchange64 for QWord, resolves #37186
git-svn-id: trunk@45647 -
This commit is contained in:
parent
febeef03e4
commit
bc1b7960ec
@ -73,15 +73,15 @@
|
||||
Key:TKey;
|
||||
end;
|
||||
var
|
||||
private
|
||||
private
|
||||
type
|
||||
TContainer = specialize TVector<TPair>;
|
||||
TTable = specialize TVector<TContainer>;
|
||||
var
|
||||
var
|
||||
FData:TTable;
|
||||
FDataSize:SizeUInt;
|
||||
FDataSize:SizeUInt;
|
||||
procedure EnlargeTable;
|
||||
public
|
||||
public
|
||||
type
|
||||
TIterator = specialize THashmapIterator<TKey, TValue, TPair, TTable>;
|
||||
constructor Create;
|
||||
@ -124,7 +124,7 @@ begin
|
||||
end;
|
||||
|
||||
procedure THashmap.EnlargeTable;
|
||||
var i,j,h,oldDataSize:SizeUInt;
|
||||
var i,j,h,oldDataSize:SizeUInt;
|
||||
curbucket:TContainer;
|
||||
value:TPair;
|
||||
begin
|
||||
@ -195,6 +195,7 @@ begin
|
||||
{$endif}
|
||||
inc(i);
|
||||
end;
|
||||
// Result:=Default(TValue);
|
||||
// exception?
|
||||
end;
|
||||
|
||||
|
@ -1550,7 +1550,7 @@ function InterlockedIncrement64 (var Target: qword) : qword; external name 'FPC_
|
||||
function InterlockedDecrement64 (var Target: qword) : qword; external name 'FPC_INTERLOCKEDDECREMENT64';
|
||||
function InterlockedExchange64 (var Target: qword;Source : qword) : qword; external name 'FPC_INTERLOCKEDEXCHANGE64';
|
||||
function InterlockedExchangeAdd64 (var Target: qword;Source : qword) : qword; external name 'FPC_INTERLOCKEDEXCHANGEADD64';
|
||||
function InterlockedCompareExchange64(var Target: qword; NewValue: qword; Comperand: qword): int64; external name 'FPC_INTERLOCKEDCOMPAREEXCHANGE64';
|
||||
function InterlockedCompareExchange64(var Target: qword; NewValue: qword; Comperand: qword): qword; external name 'FPC_INTERLOCKEDCOMPAREEXCHANGE64';
|
||||
{$endif cpu64}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user