Skip to content

Commit

Permalink
Added error metadata attribute to string decrement
Browse files Browse the repository at this point in the history
  • Loading branch information
martindevans committed Mar 17, 2023
1 parent 6a145f2 commit 849c73f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions Yolol/Execution/YString.cs
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,7 @@ internal static YString UnsafeDecrement(YString value)
return new YString(value._span.Decrement());
}

[ErrorMetadata(nameof(WillDecThrow), unsafeAlternative: nameof(UnsafeDecrement))]
public static YString operator --(YString value)
{
if (value.Length == 0)
Expand Down
2 changes: 1 addition & 1 deletion Yolol/Yolol.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<PackageProjectUrl>https://github.com/martindevans/Yolol</PackageProjectUrl>
<RepositoryUrl>https://github.com/martindevans/Yolol</RepositoryUrl>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Version>14.15.1</Version>
<Version>14.15.2</Version>
<LangVersion>8.0</LangVersion>
<Nullable>enable</Nullable>
<Platforms>AnyCPU;x64</Platforms>
Expand Down

0 comments on commit 849c73f

Please sign in to comment.