Исправлена ошибка с null_based + срезы + ^1
This commit is contained in:
parent
4f526b1fe8
commit
213c4710d0
|
|
@ -15,7 +15,7 @@ internal static class RevisionClass
|
|||
public const string Major = "3";
|
||||
public const string Minor = "8";
|
||||
public const string Build = "0";
|
||||
public const string Revision = "2944";
|
||||
public const string Revision = "2945";
|
||||
|
||||
public const string MainVersion = Major + "." + Minor;
|
||||
public const string FullVersion = Major + "." + Minor + "." + Build + "." + Revision;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
%COREVERSION%=0
|
||||
%REVISION%=2944
|
||||
%MINOR%=8
|
||||
%REVISION%=2945
|
||||
%COREVERSION%=0
|
||||
%MAJOR%=3
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
3.8.0.2944
|
||||
3.8.0.2945
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
!define VERSION '3.8.0.2944'
|
||||
!define VERSION '3.8.0.2945'
|
||||
|
|
|
|||
|
|
@ -121,20 +121,20 @@ end;
|
|||
|
||||
///--
|
||||
procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: integer;
|
||||
step: integer); extensionmethod;
|
||||
step: integer := 1); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: integer); extensionmethod;
|
||||
{procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: integer); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1);
|
||||
end;
|
||||
end;}
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex;
|
||||
step: integer); extensionmethod;
|
||||
step: integer := 1); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
|
|
@ -143,54 +143,48 @@ begin
|
|||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue + 1;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: integer;
|
||||
step: integer); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: integer); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex;
|
||||
step: integer); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue + 1;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue + 1;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
{procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex); extensionmethod;
|
||||
begin
|
||||
Self.SystemSliceAssignment(rightValue,situation,from, &to, 1);
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue + 1;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1);
|
||||
end;}
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: integer;
|
||||
step: integer := 1); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
{procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: integer); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1, 0);
|
||||
end;}
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex;
|
||||
step: integer := 1); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
{procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1, 0);
|
||||
end;}
|
||||
|
||||
//{{{--doc: Конец секции расширений строк для срезов }}}
|
||||
|
|
|
|||
|
|
@ -13020,10 +13020,10 @@ end;
|
|||
function SystemSlice0(Self: string; situation: integer; from, &to: SystemIndex; step: integer := 1): string; extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Count - from.IndexValue + 1;
|
||||
from.IndexValue := Self.Count - from.IndexValue;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Count - &to.IndexValue + 1;
|
||||
Result := SystemSliceStringImpl(Self, situation, from.IndexValue-1, &to.IndexValue-1, step, 0);
|
||||
&to.IndexValue := Self.Count - &to.IndexValue;
|
||||
Result := SystemSliceStringImpl(Self, situation, from.IndexValue, &to.IndexValue, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@ begin
|
|||
s := '123456';
|
||||
a := s[::2];
|
||||
Assert(a='135');
|
||||
a := s[1:^1];
|
||||
Assert(a='2345');
|
||||
//s[::2]:=s[1::2];
|
||||
//Assert(s='224466');
|
||||
end.
|
||||
|
|
@ -121,20 +121,20 @@ end;
|
|||
|
||||
///--
|
||||
procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: integer;
|
||||
step: integer); extensionmethod;
|
||||
step: integer := 1); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: integer); extensionmethod;
|
||||
{procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: integer); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1);
|
||||
end;
|
||||
end;}
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex;
|
||||
step: integer); extensionmethod;
|
||||
step: integer := 1); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
|
|
@ -143,54 +143,48 @@ begin
|
|||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue + 1;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: integer;
|
||||
step: integer); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: integer); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex;
|
||||
step: integer); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue + 1;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue + 1;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
{procedure SystemSliceAssignment(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex); extensionmethod;
|
||||
begin
|
||||
Self.SystemSliceAssignment(rightValue,situation,from, &to, 1);
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue + 1;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue + 1;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1);
|
||||
end;}
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: integer;
|
||||
step: integer := 1); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
{procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: integer); extensionmethod;
|
||||
begin
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1, 0);
|
||||
end;}
|
||||
|
||||
///--
|
||||
procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex;
|
||||
step: integer := 1); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
{procedure SystemSliceAssignment0(var Self: string; rightValue: string; situation: integer; from, &to: SystemIndex); extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Length - from.IndexValue;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Length - &to.IndexValue;
|
||||
SystemSliceAssignmentStringImpl(Self, rightValue, situation, from, &to, 1, 0);
|
||||
end;}
|
||||
|
||||
//{{{--doc: Конец секции расширений строк для срезов }}}
|
||||
|
|
|
|||
|
|
@ -13020,10 +13020,10 @@ end;
|
|||
function SystemSlice0(Self: string; situation: integer; from, &to: SystemIndex; step: integer := 1): string; extensionmethod;
|
||||
begin
|
||||
if from.IsInverted then
|
||||
from.IndexValue := Self.Count - from.IndexValue + 1;
|
||||
from.IndexValue := Self.Count - from.IndexValue;
|
||||
if &to.IsInverted then
|
||||
&to.IndexValue := Self.Count - &to.IndexValue + 1;
|
||||
Result := SystemSliceStringImpl(Self, situation, from.IndexValue-1, &to.IndexValue-1, step, 0);
|
||||
&to.IndexValue := Self.Count - &to.IndexValue;
|
||||
Result := SystemSliceStringImpl(Self, situation, from.IndexValue, &to.IndexValue, step, 0);
|
||||
end;
|
||||
|
||||
///--
|
||||
|
|
|
|||
Loading…
Reference in a new issue