[GHC] #12570: Different behaviour in Linux and Mac OS when using some locale environments