Cast directly to long, not short, for IsPrime

This commit is contained in:
Oliver Booth 2022-04-21 11:49:21 +01:00
parent 86b6a94adc
commit f6c08fedf3
No known key found for this signature in database
GPG Key ID: 32A00B35503AF634
1 changed files with 1 additions and 1 deletions

View File

@ -44,7 +44,7 @@ public static class SByteExtensions
/// </returns> /// </returns>
public static bool IsPrime(this sbyte value) public static bool IsPrime(this sbyte value)
{ {
return ((short)value).IsPrime(); return ((long)value).IsPrime();
} }
/// <summary> /// <summary>