mirror of
https://gitlab.com/freepascal.org/fpc/pas2js.git
synced 2025-04-13 16:49:22 +02:00
* Fix uninitialized result warnings
This commit is contained in:
parent
67dc093559
commit
d19e385f71
@ -1300,6 +1300,7 @@ end;
|
||||
function TDictionary<TKey, TValue>.ExtractPair(const Key: TKey): TMyPair;
|
||||
|
||||
begin
|
||||
Result:=Default(TMyPair);
|
||||
if FMap.Has(Key) then
|
||||
begin
|
||||
Result.Create(Key,TValue(FMap.get(key)));
|
||||
@ -1419,6 +1420,7 @@ Var
|
||||
|
||||
begin
|
||||
A:=TJSValueDynArray(FVal.Value);
|
||||
Result:=Default(TMyPair);
|
||||
Result.Create(TKey(A[0]),TValue(A[1]));
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user