Fix MSVC build problems

Mostly regarding erf.c