compileUserError err = do
  e <- compileExp err
  decl <- ask
  let line = maybe 0 (srcLocLine . snd . unOriginal) decl
  return $ throwExp (Loc ("X.hs",line))
                    (force (Apply (Variable (Identifier "ghczmprim$GHC$CString$packCStringzh"))
                                  [e]))

-- | Optimize nested IO actions like a>>b>>c to __(a),__(b),c
compileUserError err = do
  e <- compileExp err
  decl <- ask
  let line = maybe 0 (srcLocLine . snd . unOriginal) decl
  return $ throwExp (Loc ("X.hs",line))
                    (force (Apply (Variable (Identifier "ghczmprim$GHC$CString$packCStringzh"))
                                  [e]))

-- | Optimize nested IO actions like a>>b>>c to __(a),__(b),c
compileUserError err = do
  e <- compileExp err
  decl <- ask
  let line = maybe 0 (srcLocLine . snd . unOriginal) decl
  return $ throwExp (Loc ("X.hs",line))
                    (force (Apply (Variable (Identifier "ghczmprim$GHC$CString$packCStringzh"))
                                  [e]))

-- | Optimize nested IO actions like a>>b>>c to __(a),__(b),c