From c599cca3f20b7b7894e6539318e6c4028d52e594 Mon Sep 17 00:00:00 2001 From: Cyril Sobierajewicz Date: Sat, 18 Jul 2020 19:21:59 +0200 Subject: [PATCH] Add roles declarations to allow safe coercions --- src/Data/Array/ST.purs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Data/Array/ST.purs b/src/Data/Array/ST.purs index 4a57939d..2b3e030b 100644 --- a/src/Data/Array/ST.purs +++ b/src/Data/Array/ST.purs @@ -43,6 +43,8 @@ import Data.Maybe (Maybe(..)) -- | except that mutation is allowed. foreign import data STArray :: Region -> Type -> Type +type role STArray nominal representational + -- | An element and its index. type Assoc a = { value :: a, index :: Int }