Closed type families, apartness, and occurs check

2014-07-02 Thread Brandon Moore
From the user manual, it sounds like a clause of a closed type family should be rejected once no subsitution of the type could make it unify with the clause. If so, it doesn't seem to do an occurs check: type family IsEq a b :: Bool where   IsEq a a = True   IsEq a b = False :kind! forall a

Re: Closed type families, apartness, and occurs check

2014-07-02 Thread Brandon Moore
It is conceivable that some restrictions around UndecidableInstances (short of banning it in a whole program, including all importing modules) can mitigate this problem, but no one I know has gotten to the bottom of it. Richard On Jul 2, 2014, at 4:19 AM, Brandon Moore brandon_m_mo...@yahoo.com wrote

Parallel --make (GHC build times on newer MacBook Pros?)

2011-08-26 Thread Brandon Moore
From: Evan Laforge qdun...@gmail.com Sent: Friday, August 26, 2011 6:35 PM Subject: Re: GHC build times on newer MacBook Pros? On Tue, Aug 23, 2011 at 10:24 AM, David Terei davidte...@gmail.com wrote:   I have a 16 core machine at work (with 48GB of ram, a perk of the job   :)). GHC can

Re: Package management

2011-04-28 Thread Brandon Moore
From: Albert Y. C. Lai tre...@vex.net To: glasgow-haskell-users@haskell.org Sent: Wed, April 27, 2011 9:53:38 PM Subject: Re: Package management On 11-04-26 05:05 PM, Brandon Moore wrote: There are already hashes to keep incompatible builds of a package separate. Would anything break

Package management

2011-04-26 Thread Brandon Moore
Based on my own misadventures and Albert Y. C. Lai's SICP (http://www.vex.net/~trebla/haskell/sicp.xhtml) it seems the that root of all install problems is that reinstalling a particular version of a particular package deletes any other existing builds of that version, even if other packages

Re: memory slop

2011-03-22 Thread Brandon Moore
On Tue, March 22, 2011 21:00:29 Tim Docker t...@dockerz.net wrote: I'm a bit shocked at the amount of wasted memory here. The sample data file has ~61k key/value pair. Hence ~122k ByteStrings - as you point out many of these are very small (1500 of them are empty). Assuming it's the

Heap representation evil

2006-10-23 Thread Brandon Moore
Thinking to take advantage of fortuitous heap layout of some Haskell values for interfacing with C, I've written the following function: addressOf :: a - Ptr () addressOf x = x `seq` unsafeCoerce# (Box x) data Box x = Box x For example, data A = A {-# UNPACK #-} !(Ptr Word8) {-# UNPACK #-}

Re: Heap representation evil

2006-10-23 Thread Brandon Moore
. Stable pointers might help with the GC relocating things, except I don't think having a stable pointer guarantees that the object won't be moved around, just that the stable pointer won't be invalidated by GC. On Mon, Oct 23, 2006 at 06:43:26PM -0700, Brandon Moore wrote: A different and in all