projects
/
ghc-base.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Add a missing castPtr (only shows up in -DDEBUG)
[ghc-base.git]
/
GHC
/
IO
/
Encoding
/
UTF16.hs
diff --git
a/GHC/IO/Encoding/UTF16.hs
b/GHC/IO/Encoding/UTF16.hs
index
d44259f
..
1f27bb1
100644
(file)
--- a/
GHC/IO/Encoding/UTF16.hs
+++ b/
GHC/IO/Encoding/UTF16.hs
@@
-48,10
+48,11
@@
import GHC.IORef
import System.Posix.Internals
import Foreign.C
import GHC.Show
+import GHC.Ptr
puts :: String -> IO ()
puts s = do withCStringLen (s++"\n") $ \(p,len) ->
- c_write 1 p (fromIntegral len)
+ c_write 1 (castPtr p) (fromIntegral len)
return ()
#endif