diff options
author | Herbert Valerio Riedel <hvr@gnu.org> | 2016-01-30 19:44:58 +0100 |
---|---|---|
committer | Herbert Valerio Riedel <hvr@gnu.org> | 2016-01-30 19:44:58 +0100 |
commit | 731f7dddcbae3c4332beac742605dade2d4a80ad (patch) | |
tree | 0eac898007723182c50eb09af16f7e720610554e /System/Posix/Directory | |
parent | 03783d2758d2f35c01a8570da30f508c3b9e019b (diff) |
Add CTYPE annotations to ptr types used for FFI
This avoids incompatible-pointer warnings from the c-compiler when using
`CApiFFI`
Diffstat (limited to 'System/Posix/Directory')
-rw-r--r-- | System/Posix/Directory/Common.hsc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/System/Posix/Directory/Common.hsc b/System/Posix/Directory/Common.hsc index 4ea8f78..9fb5ac4 100644 --- a/System/Posix/Directory/Common.hsc +++ b/System/Posix/Directory/Common.hsc @@ -39,8 +39,8 @@ import Foreign.C newtype DirStream = DirStream (Ptr CDir) -type CDir = () -type CDirent = () +data {-# CTYPE "DIR" #-} CDir +data {-# CTYPE "struct dirent" #-} CDirent -- | @rewindDirStream dp@ calls @rewinddir@ to reposition -- the directory stream @dp@ at the beginning of the directory. |