mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-11 13:08:31 +02:00
FpDebug: FIX, Array-slices [n..m], check if they are in active part of condition. If not, don't create multiple results.
This commit is contained in:
parent
64b2dbfaea
commit
f6c415d958
@ -6587,6 +6587,7 @@ begin
|
||||
|
||||
FSlicePart.FCurrentIndex := FSlicePart.StartValue;
|
||||
FSlicePart.FTouched := False;
|
||||
ResetEvaluationForIndex;
|
||||
Result := Items[0].ResultValue;
|
||||
|
||||
if not FSlicePart.FTouched then begin
|
||||
@ -6595,6 +6596,13 @@ begin
|
||||
exit;
|
||||
end;
|
||||
|
||||
// Need to return an array, the array itself should not set an error (the 1st (or any) member may do)
|
||||
// We need to get the error again later, when we get the first member
|
||||
if IsError(Expression.FError) then
|
||||
Items[0].ResetEvaluation;
|
||||
Expression.FValid := True;
|
||||
Expression.FError := nil;
|
||||
|
||||
if not FCheckedForVariantPart then begin
|
||||
FSlicePart.CheckForVariantExpressionParts;
|
||||
FCheckedForVariantPart := True;
|
||||
|
Loading…
Reference in New Issue
Block a user