summaryrefslogtreecommitdiffstats
path: root/include/string.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/string.h')
-rw-r--r--include/string.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/include/string.h b/include/string.h
new file mode 100644
index 0000000..a821f1c
--- /dev/null
+++ b/include/string.h
@@ -0,0 +1,25 @@
+#ifndef _JOVE_STRING_H
+#define _JOVE_STRING_H 1
+
+#include <stdbool.h>
+#include <stddef.h>
+
+/**@FUNC Writes the given integer to the string using a custom base.
+ * If the integer is larger than size, s will stop being written to at s[size-1].
+ * Returns the number of characters written, or would have been written.
+ * @PARAM s buffer to write to.
+ * @PARAM size size of buffer to write to.
+ * @PARAM l integer to write.
+ * @PARAM sign whether the integer is signed or unsigned.
+ * @PARAM radix base to write at.
+ * @RETURN number of characters in number.*/
+int ltostr(char *s, int size, unsigned long l, bool sign, int radix);
+
+size_t strlen(const char *s);
+int strcmp(const char *s1, const char *s2);
+
+void *memset(void *dest, char c, size_t n);
+void *memcpy(void *dest, const void *src, size_t n);
+void *memmove(void *dest, const void *src, size_t n);
+
+#endif