primitive icon indicating copy to clipboard operation
primitive copied to clipboard

This package provides various primitive memory-related operations.

Results 55 primitive issues
Sort by recently updated
recently updated
newest added

It would useful to have a function like ```hs mutableArrayFromListN :: PrimMonad m => Int -> [a] -> m (MutableArray (PrimState m) a) ``` given that there already exists ```hs...

GHC exposes a set of `(read|write|index)Word8ArrayAs[ty]#` primops for safe unaligned accesses to GC pointers. I think the `Prim` class could sensibly expose these. Also note that similar primops for `Addr#`...

In https://github.com/haskell/primitive/issues/409 it was discovered that @raehik and I had independently developed the same interface (modulo naming) for talking about fixed-endianness elements in a primitive array. The interface looks like...

Before GHC 8.6, there are no primitives for unaligned access to byte arrays. These have now been available for a long time, and I have a typeclass and functions for...

it falls back to a scalar c loop when not zeroing. which seems disappointing. Also not sure if it correctly handles `-0` in the floating point code

bug
enhancement
task

There are operations that can't support unpinned arrays, but currently the types don't actually prevent such arrays from being provided. There are constructive operations that should be able to produce...

The `withMutablePrimArrayContents` and `withPrimArrayContents` functions take a `Ptr a -> m a`, which restricts you to only returning an `a`. Best guess as to why this might have been done...

The latest tag is from 4 years ago (0.6.3), we should probably add the remaining tags since then

I'd like to move this from `primitive-unlifted` into this `primitive`: ``` class PrimUnlifted a where type Unlifted a :: UnliftedType toUnlifted# :: a -> Unlifted a fromUnlifted# :: Unlifted a...