D Programming Language 1.0

Last update Mon Dec 31 10:53:29 2012


C's <stdlib.h> D Programming Language runtime library

Walter Bright, Digital Mars, http://www.digitalmars.com

Public Domain

struct div_t;

struct ldiv_t;

struct lldiv_t;

div_t div(int, int);
ldiv_t ldiv(int, int);
lldiv_t lldiv(long, long);

const int EXIT_SUCCESS;
const int EXIT_FAILURE;

int atexit(void function());
void exit(int);
void _exit(int);

void* alloca(size_t);
Allocate bytes on stack

void* calloc(size_t, size_t);
void* malloc(size_t);
void* realloc(void*, size_t);
void free(void*);

void* bsearch(void*, void*, size_t, size_t, int function(void*, void*));
void qsort(void* base, size_t nelems, size_t elemsize, int function(void* elem1, void* elem2) compare);

char* getenv(char*);

int setenv(char*, char*, int);
extension to ISO C standard, not available on all platforms

void unsetenv(char*);
extension to ISO C standard, not available on all platforms

int rand();
void srand(uint);
int random(int num);
void randomize();
int getErrno();
int setErrno(int);

double atof(char*);
int atoi(char*);
int atol(char*);
float strtof(char*, char**);
double strtod(char*, char**);
real strtold(char*, char**);
long strtol(char*, char**, int);
uint strtoul(char*, char**, int);
long atoll(char*);
long strtoll(char*, char**, int);
ulong strtoull(char*, char**, int);

char* itoa(int, char*, int);
char* ultoa(uint, char*, int);

int mblen(char* s, size_t n);
int mbtowc(wchar* pwc, char* s, size_t n);
int wctomb(char* s, wchar_t wc);
size_t mbstowcs(wchar* pwcs, char* s, size_t n);
size_t wcstombs(char* s, wchar* pwcs, size_t n);