diff options
Diffstat (limited to 'testsuite/tests/codeGen/should_compile/cg007.hs')
-rw-r--r-- | testsuite/tests/codeGen/should_compile/cg007.hs | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/testsuite/tests/codeGen/should_compile/cg007.hs b/testsuite/tests/codeGen/should_compile/cg007.hs new file mode 100644 index 0000000000..5ef739bd47 --- /dev/null +++ b/testsuite/tests/codeGen/should_compile/cg007.hs @@ -0,0 +1,26 @@ +{-# LANGUAGE ForeignFunctionInterface #-} +module ShouldCompile where + +import Foreign.C.Types + +{- +During 6.11, this was failing like this: + +In file included from /ghc/includes/Stg.h:207, + + from /tmp/ghc2904_0/ghc2904_0.hc:3:0: +/tmp/ghc2904_0/ghc2904_0.hc: In function `swM_ret': + +/tmp/ghc2904_0/ghc2904_0.hc:22:0: + error: `gamma' undeclared (first use in this function) + +/tmp/ghc2904_0/ghc2904_0.hc:22:0: + error: (Each undeclared identifier is reported only once + +/tmp/ghc2904_0/ghc2904_0.hc:22:0: + error: for each function it appears in.) +-} + +foreign import ccall unsafe "math.h gamma" + gamma :: CDouble -> CDouble + |