- literals_arr = listArray (0, n_literals-1) linked_literals
- :: UArray Int Word
- literals_barr = case literals_arr of UArray lo hi barr -> barr
+ litRange
+ | n_literals > 65535 = panic "linkBCO: >= 64k literals"
+ | n_literals > 0 = (0, fromIntegral n_literals - 1)
+ | otherwise = (1, 0)
+ literals_arr :: UArray Word16 Word
+ literals_arr = listArray litRange linked_literals
+ !literals_barr = case literals_arr of UArray _lo _hi _n barr -> barr