mirror of
https://github.com/oliverbooth/X10D
synced 2024-11-22 23:58:48 +00:00
🔨 Call overloads to reduce code duplication
This commit is contained in:
parent
ae4f7f7b38
commit
2df13450a0
@ -120,7 +120,7 @@
|
|||||||
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
|
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
|
||||||
/// <see langword="true"/> otherwise.</returns>
|
/// <see langword="true"/> otherwise.</returns>
|
||||||
public static bool ToBoolean(this short value) =>
|
public static bool ToBoolean(this short value) =>
|
||||||
value != 0;
|
((long)value).ToBoolean();
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets an boolean value that represents this integer.
|
/// Gets an boolean value that represents this integer.
|
||||||
@ -129,6 +129,6 @@
|
|||||||
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
|
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
|
||||||
/// <see langword="true"/> otherwise.</returns>
|
/// <see langword="true"/> otherwise.</returns>
|
||||||
public static bool ToBoolean(this ushort value) =>
|
public static bool ToBoolean(this ushort value) =>
|
||||||
value != 0;
|
((ulong)value).ToBoolean();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -256,7 +256,7 @@
|
|||||||
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
|
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
|
||||||
/// <see langword="true"/> otherwise.</returns>
|
/// <see langword="true"/> otherwise.</returns>
|
||||||
public static bool ToBoolean(this int value) =>
|
public static bool ToBoolean(this int value) =>
|
||||||
value != 0;
|
((long)value).ToBoolean();
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets an boolean value that represents this integer.
|
/// Gets an boolean value that represents this integer.
|
||||||
@ -265,6 +265,6 @@
|
|||||||
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
|
/// <returns>Returns <see langword="false"/> if <paramref name="value"/> is 0,
|
||||||
/// <see langword="true"/> otherwise.</returns>
|
/// <see langword="true"/> otherwise.</returns>
|
||||||
public static bool ToBoolean(this uint value) =>
|
public static bool ToBoolean(this uint value) =>
|
||||||
value != 0;
|
((ulong)value).ToBoolean();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user