From 8eab0f07cd8a6b2e3085f3a0bf67bb04a8bb08f5 Mon Sep 17 00:00:00 2001 From: Harendra Kumar Date: Thu, 11 Jan 2024 13:23:56 +0530 Subject: [PATCH] Add a comment about newRounded --- core/src/Streamly/Internal/Data/MutByteArray/Type.hs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core/src/Streamly/Internal/Data/MutByteArray/Type.hs b/core/src/Streamly/Internal/Data/MutByteArray/Type.hs index 0e0d3782f..ca72c5277 100644 --- a/core/src/Streamly/Internal/Data/MutByteArray/Type.hs +++ b/core/src/Streamly/Internal/Data/MutByteArray/Type.hs @@ -142,6 +142,8 @@ asUnpinnedPtrUnsafe arr f = do nil :: MutByteArray nil = unsafePerformIO $ new 0 +-- XXX add "newRounded" to round up the large size to the next page boundary +-- and return the allocated size. {-# INLINE new #-} new :: Int -> IO MutByteArray new nbytes | nbytes < 0 =