#1434: Slow conversion from Double to Int
------------------------------------------+---------------------------------
Reporter: [EMAIL PROTECTED] | Owner:
Type: bug | Status: new
Priority: normal | Milestone: 6.8 branch
Component: libraries/base | Version: 6.4.1
Severity: normal | Resolution:
Keywords: | Difficulty: Unknown
Os: Linux | Testcase:
Architecture: Unknown |
------------------------------------------+---------------------------------
Comment (by simonmar):
I bet this is the lack of a specialised version of `truncate` for `Int16`.
We have RULEs for `truncate` at `Float->Int` and `Double->Int`. We could
presumably add RULEs for small integral types, of the form `truncate =
fromIntegral . double2Int` (truncate is undefined outside the range of the
target anyway).
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/1434#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs