Commit c4c2f7ec authored by Simon Marlow's avatar Simon Marlow
Browse files

Using 'stdcall' when it is not supported is only a warning now (#3336)

parent 41bfdf71
......@@ -53,7 +53,8 @@ convToABI CCallConv = fFI_DEFAULT_ABI
#ifdef mingw32_HOST_OS
convToABI StdCallConv = fFI_STDCALL
convToABI _ = panic "convToABI: convention not supported"
-- unknown conventions are mapped to the default, (#3336)
-- c.f. DsForeign.primTyDescChar
primRepToFFIType :: PrimRep -> Ptr C_ffi_type
......@@ -310,7 +310,8 @@ checkCConv CCallConv = return ()
#if i386_TARGET_ARCH
checkCConv StdCallConv = return ()
checkCConv StdCallConv = addErrTc (text "calling convention not supported on this platform: stdcall")
-- This is a warning, not an error. see #3336
checkCConv StdCallConv = addWarnTc (text "the 'stdcall' calling convention is unsupported on this platform,"$$ text "treating as ccall")
checkCConv PrimCallConv = addErrTc (text "The `prim' calling convention can only be used with `foreign import'")
checkCConv CmmCallConv = panic "checkCConv CmmCallConv"
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment