blob: 72ba769b531c2374dc2484fb669fb37235fd7fea [file] [log] [blame]
Antonio Nino Diazcf0f8052018-08-17 10:45:47 +01001/*
2 * Copyright (c) 2012-2017 Roberto E. Vargas Caballero
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
7#ifndef _STRING_H
8#define _STRING_H
9
10#include <arch/string.h>
11
12#ifndef NULL
13#define NULL ((void *) 0)
14#endif
15
16extern void *memcpy(void * restrict s1, const void * restrict s2, size_t n);
17extern void *memmove(void *s1, const void *s2, size_t n);
18extern char *strcpy(char * restrict s1, const char * restrict s2);
19extern char *strncpy(char * restrict s1, const char * restrict s2, size_t n);
20extern char *strcat(char * restrict s1, const char * restrict s2);
21extern char *strncat(char * restrict s1, const char * restrict s2, size_t n);
22extern int memcmp(const void *s1, const void *s2, size_t n);
23extern int strcmp(const char *s1, const char *s2);
24extern int strcoll(const char *s1, const char *s2);
25extern int strncmp(const char *s1, const char *s2, size_t n);
26extern size_t strxfrm(char * restrict s1, const char * restrict s2, size_t n);
27extern void *memchr(const void *s, int c, size_t n);
28extern char *strchr(const char *s, int c);
29extern size_t strcspn(const char *s1, const char *s2);
30extern char *strpbrk(const char *s1, const char *s2);
31extern char *strrchr(const char *s, int c);
32extern size_t strspn(const char *s1, const char *s2);
33extern char *strstr(const char *s1, const char *s2);
34extern char *strtok(char * restrict s1, const char * restrict s2);
35extern void *memset(void *s, int c, size_t n);
36extern char *strerror(int errnum);
37extern size_t strlen(const char *s);
38
39#endif