[Haskell-cafe] Pointer equality for nullary constructors

Joachim Breitner mail at joachim-breitner.de
Wed Feb 21 02:43:10 UTC 2018


Hi,

Am Dienstag, den 20.02.2018, 17:56 -0500 schrieb Gregory Collins:
> You mean like this? https://github.com/gregorycollins/hashtables/blob/master/src/Data/HashTable/Internal/UnsafeTricks.hs#L72
> 
> My experience is that this works, except when doing coverage, where the compiler adds instrumentation code that breaks the technique. I #ifdef'd my way around the problem, swapping out a slower impl when I was doing code coverage.

it seems that in this case,
https://ghc.haskell.org/trac/ghc/ticket/14826
would very much apply, wouldn’t it?

Cheers,
Joachim

-- 
Joachim Breitner
  mail at joachim-breitner.de
  http://www.joachim-breitner.de/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20180220/147e47ed/attachment.sig>


More information about the Haskell-Cafe mailing list