[GHC] #11829: C++ does not catch exceptions when used with Haskell-main and linked by ghc