Cleanup type names to be more consistent
Make all headers c++-safe