Made #include <locale> unconditional to fix dependency bug