Ticket #155 (assigned defect)

Opened 4 years ago

Last modified 4 years ago

PANIC "mergeClasses: classes have differing kinds" in my Hashtable first cut

Reported by: blackh Owned by: benl
Priority: blocker Milestone: 0.1.3
Component: Core Type Checker Version: 0.1.2
Keywords: Cc:

Description

[1 of 1] Compiling Hashtable
ddc: PANIC in Type.Squid.Class
        mergeClasses: classes have differing kinds
            cids = [720, 721]
            ks   = [*, * -> *]
        
        Please report this bug to the maintainers at:
            http://trac.haskell.org/ddc
            or by emailing disciple-cafe@googlegroups.com

Attachments

Hashtable.ds (1.1 kB) - added by blackh 4 years ago.

Change History

Changed 4 years ago by blackh

Changed 4 years ago by benl

  • owner set to benl
  • status changed from new to assigned

Changing the hashtable function to the following works. The original version missed the value to initialise the array elements [] in this case.

hashtable_new :: (k -> Int) -> Int -> Hashtable k v
hashtable_new hash capacity = Hashtable hash (array_new capacity [])

However, the following gives the same error message:

hashtable_new :: (k -> Int) -> Int -> Hashtable k v
hashtable_new hash capacity = Hashtable hash (new&{Array} capacity [])

So it looks like the projection new&{Array} isn't being managed properly.

Changed 4 years ago by benl

  • priority changed from normal to blocker
  • milestone set to 0.1.3
Note: See TracTickets for help on using tickets.