From 521d01e8ad87e931af3e9a763cc84a6cf7fe5ee3 Mon Sep 17 00:00:00 2001 From: Nicholas Noll Date: Sun, 5 Dec 2021 09:47:21 -0800 Subject: Feat: basic string and memory functions Continue filling out the basic standard lib functions. Included prototypes of the str* and mem* families. Plan to add e(str|mem) and n(str|mem) variants as well. --- src/base/string/itoa.c | 23 ----------------------- 1 file changed, 23 deletions(-) delete mode 100644 src/base/string/itoa.c (limited to 'src/base/string/itoa.c') diff --git a/src/base/string/itoa.c b/src/base/string/itoa.c deleted file mode 100644 index a2910f4..0000000 --- a/src/base/string/itoa.c +++ /dev/null @@ -1,23 +0,0 @@ -#include "internal.h" - -static char * -kernel(char *s, int x) -{ - if(x/10) - s = kernel(s, x/10); - *s++ = x%10 + '0'; - return s; -} - -char * -strĀ·itoa(char *s, int x) -{ - if(x<0){ - *s++ = '-'; - x=-x; - } - s = kernel(s, x); - *s = '0'; - - return s; -} -- cgit v1.2.1