MERGE from 6.6: Windows fix for stdcall foreign-import-wrapper, fixes ffi012(ghci)