uses of void

as the (non-) return value of a function that doesn’t return anything

so it is a syntax error to have

	return myval;

one must have only

	return;
as (non-) type of pointer to raw memory,

as is returned from malloc(). One typically casts the pointer to a meaningful type:

int *myIntArray = (int *)malloc( NUM_INTS * sizeof( int ) );
the conversion to (void *) from a non-void * is sometimes useful.
This makes sense if the pointer is thereafter to be regarded as a pointer to raw memory (as in free() or memcpy()). Otherwise it should be avoided.