1
0
mirror of https://github.com/oliverbooth/X10D synced 2024-11-22 18:58:47 +00:00

🔨 Call overloads to reduce code duplication

This commit is contained in:
Oliver Booth 2019-11-16 11:04:02 +00:00
parent ae4f7f7b38
commit 2df13450a0
No known key found for this signature in database
GPG Key ID: 4B0992B2602C3778
2 changed files with 4 additions and 4 deletions

View File

@ -120,7 +120,7 @@
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
/// <see langword="true"/> otherwise.</returns>
public static bool ToBoolean(this short value) =>
value != 0;
((long)value).ToBoolean();
/// <summary>
/// Gets an boolean value that represents this integer.
@ -129,6 +129,6 @@
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
/// <see langword="true"/> otherwise.</returns>
public static bool ToBoolean(this ushort value) =>
value != 0;
((ulong)value).ToBoolean();
}
}

View File

@ -256,7 +256,7 @@
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
/// <see langword="true"/> otherwise.</returns>
public static bool ToBoolean(this int value) =>
value != 0;
((long)value).ToBoolean();
/// <summary>
/// Gets an boolean value that represents this integer.
@ -265,6 +265,6 @@
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
/// <see langword="true"/> otherwise.</returns>
public static bool ToBoolean(this uint value) =>
value != 0;
((ulong)value).ToBoolean();
}
}