
#12890: Stdcall - treating as CCall (bogus warning on win 64 bit) -------------------------------------+------------------------------------- Reporter: tim-m89 | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.0.1 Resolution: | Keywords: Operating System: Windows | Architecture: x86_64 Type of failure: Incorrect | (amd64) error/warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by Phyx-): Hi, Thanks for the report. Win32 now contains a header you can include instead of needing to define the macros over and over again see https://github.com/haskell/win32/commit/7f91a92f74b7d93081df49d01b408ae1cd9c... About the warning. While I agree, I don't know what the right thing here is. You most definitely should get a warning. But the Microsoft x64 calling convention doesn't really have a name we can refer to. And the Haskell FFI standard doesn't allow you to omit the calling convention https://www.haskell.org/onlinereport/haskell2010/haskellch8.html#x15-1540008.... We default to `cdecl` because that means in this case `do whatever is native to the platform`. If you have any suggestions on how we can do better here, I'm all for it! -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12890#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler