ArrayRef-0.1: Examples/Array/Storable.hs
-- This example demonstrates using of StorableArray
import Data.ArrayBZ.Storable
main = do
-- This section demonstrates using of StorableArray
test_StorableArray >>= print
-- Using StorableArray
test_StorableArray = do
array <- newListArray (1,10) [1..10] :: IO (StorableArray Int Double)
elements <- getElems array
return (sum elements)