Fixed compatibility with C++, nuked some warnings