Modifying files to make them MSVC compliant and replacing complement function