Fixing various issues with the compiler