Skip to content

Commit a8a90f5

Browse files
committed
0.5
1 parent 1fb93e4 commit a8a90f5

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

NStack/NStack.csproj

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<PropertyGroup>
66
<TargetFramework>netstandard1.5</TargetFramework>
77
<PackageId>NStack.Core</PackageId>
8-
<PackageVersion>0.4</PackageVersion>
8+
<PackageVersion>0.5</PackageVersion>
99
<Authors>Miguel de Icaza</Authors>
1010
<PackageLicenseUrl>https://github.com/migueldeicaza/NStack/blob/master/LICENSE.md</PackageLicenseUrl>
1111
<Owners>Miguel de Icaza</Owners>
@@ -17,6 +17,8 @@
1717

1818
It starts with a new string type that is focused on Unicode code-points as opposed to the historical chars and UTF-16 encoding and introduces a utf8 string that supports slicing</Description>
1919
<ReleaseVersion>0.3</ReleaseVersion>
20+
<PackageReleaseNotes>* Renamed some methods to match the equivalent methods in Char.
21+
* Introduced Substring (int start)</PackageReleaseNotes>
2022
</PropertyGroup>
2123

2224
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">

NStack/strings/ustring.cs

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -895,6 +895,20 @@ public static ustring Make (byte [] buffer, int start, int count)
895895
}
896896
}
897897

898+
/// <summary>
899+
/// Returns the substring starting at the given position.
900+
/// </summary>
901+
/// <returns>The substring starting at the specified offset.</returns>
902+
/// <param name="start">Starting point, the value is .</param>
903+
public ustring Substring (int start)
904+
{
905+
int len = Length;
906+
if (start < 0)
907+
start = 0;
908+
return GetRange (start, len);
909+
}
910+
911+
898912
/// <summary>
899913
/// Gets a value indicating whether this <see cref="T:NStack.ustring"/> is empty.
900914
/// </summary>

0 commit comments

Comments
 (0)