haskell / haskell/primitive

fromList for mutable arrays

Open
#413 7 comments 0 reactions 0 assignees View on GitHub
Dominant language
Haskell
Stars
123
Forks
60
PR merge metrics
No merged PRs in 30d

Description

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
arrayFromListN :: Int -> [a] -> Array a
```

My particular use case is also more directly expressed by `generate`, but I understand if this is too much for this library.

```hs
generate :: PrimMonad m => Int -> (Int -> a) -> m (MutableArray (PrimState m) a)
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.