LazUtils: fix not adding '[' as a literal to the internal mask if ranges and sets are disabled:

MatchesMask('a[b]c','a[b]c',False,MaskOpCodesDisableRange) now correctly evaluates to True.
This commit is contained in:
Bart 2021-11-02 23:08:52 +01:00
parent 3c7586c0f8
commit a22cac6853

View File

@ -932,7 +932,6 @@ begin
then
CompileRange
else begin
if (fMask[fMaskInd]=FMaskEscapeChar) and (mocEscapeChar in FMaskOpcodesAllowed) then begin
// next is Literal
inc(fMaskInd,fCPLength);
@ -941,15 +940,16 @@ begin
end else begin
Exception_IncompleteMask();
end;
AddLiteral;
end;
AddLiteral;
end;
end;
end;
end
else
begin
AddLiteral;
end;
inc(fMaskInd,fCPLength);
end;
end;