applied uncrustify to io source

master
Anton Lydike 3 years ago
parent 5128b0376f
commit 7246772787

@ -28,7 +28,7 @@ void dbgln(char* text, int len)
/* alphabet for itoa */
char alpha[16] = "0123456789abcdef";
char* itoa (int value, char* str, int base)
char* itoa(int value, char* str, int base)
{
if (base > 16 || base < 2) {
*str++ = '?';
@ -42,6 +42,7 @@ char* itoa (int value, char* str, int base)
int digits = 0;
int num = 0;
// reverse number
do {
num = num * base;
@ -56,8 +57,7 @@ char* itoa (int value, char* str, int base)
value = value / base;
*str++ = alpha[num];
digits--;
}
while (digits > 0);
}while (digits > 0);
return str;
}

@ -15,7 +15,7 @@
void dbgln(char* text, int len);
/* alphabet for itoa */
char* itoa (int value, char* str, int base);
char* itoa(int value, char* str, int base);
// if we don't have a textIO module for debugging
#else
@ -24,9 +24,9 @@ char* itoa (int value, char* str, int base);
// if we don't have textio, dbgln becomes an empty macro to save on cycles
#define dbgln(a,b)
#define dbgln(a, b)
// itoa just evaluates to the passes pointer
#define itoa(a,b,c) b
#define itoa(a, b, c) b
#endif
#endif

Loading…
Cancel
Save