Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

How to C

Name: Anonymous 2016-01-08 14:23

https://matt.sh/howto-c

Very good read for anyone that wants to write this outdated language in 2016.

Name: Anonymous 2016-01-22 21:13

>>96
A valid implementation of malloc and free are:
static char mem[~0U];
static size_t nalloc;

void *malloc(size_t n)
{
void *p = mem+nalloc;
nalloc += n;
return p;
}

void free(void *p)
{
// no-op
}

The standard imposes to real semantic requirements on these functions.
malloc() is allowed to fail at any time.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List