aboutsummaryrefslogtreecommitdiff
path: root/include/string.h
blob: c432f2ad4da7dad3d4fb2a9502b84c236159c5030a35edbc5b25ecd34a7a5e26 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28

/*
 * C89 string.h file.
 *
 * Copyright © 2022-2026 Samuel Lidén Borell <samuel@kodafritt.se>
 *
 * SPDX-License-Identifier: EUPL-1.2+ OR LGPL-2.1-or-later
 */

#ifndef _DS9K_STRING_H
#define _DS9K_STRING_H

#define _DS9K_NEED_NULL
#define _DS9K_NEED_SIZE_T
#include "ds9k_internal.h"

void *memcpy(void *dest, const void *source, size_t size);
void *memset(void *dest, int value, size_t size);
int memcmp(const void *a, const void *b, size_t size);
void *memchr(const void *buff, int c, size_t n);
char *strchr(const char *s, int c);
char *strrchr(const char *s, int c);
int strcmp(const char *a, const char *b);
int strncmp(const char *a, const char *b, size_t len);
size_t strlen(const char *s);
size_t strcspn(const char *s, const char *reject);
size_t strspn(const char *s, const char *accept);

#endif