Fixed compilation error: Math.DivRem() doesn't exist in the XNA Framework for XBox 360
git-svn-id: file:///srv/devel/repo-conversion/nusu@198 d2e56fa2-650e-0410-a79f-9358c0239efd
This commit is contained in:
parent
bbd0849d43
commit
d8d7af174a
|
@ -291,8 +291,13 @@ namespace Nuclex.Support {
|
|||
/// <param name="builder">String builder the number will be appended to</param>
|
||||
/// <param name="remaining">Remaining digits that will be recursively processed</param>
|
||||
private static void recursiveAppend(StringBuilder builder, int remaining) {
|
||||
#if XBOX
|
||||
int digit = remaining % 10;
|
||||
int tenth = remaining / 10;
|
||||
#else
|
||||
int digit;
|
||||
int tenth = Math.DivRem(remaining, 10, out digit);
|
||||
#endif
|
||||
|
||||
if(tenth > 0) {
|
||||
recursiveAppend(builder, tenth);
|
||||
|
@ -305,8 +310,13 @@ namespace Nuclex.Support {
|
|||
/// <param name="builder">String builder the number will be appended to</param>
|
||||
/// <param name="remaining">Remaining digits that will be recursively processed</param>
|
||||
private static void recursiveAppend(StringBuilder builder, long remaining) {
|
||||
#if XBOX
|
||||
long digit = remaining % 10;
|
||||
long tenth = remaining / 10;
|
||||
#else
|
||||
long digit;
|
||||
long tenth = Math.DivRem(remaining, 10, out digit);
|
||||
#endif
|
||||
|
||||
if(tenth > 0) {
|
||||
recursiveAppend(builder, tenth);
|
||||
|
|
Loading…
Reference in New Issue
Block a user