on master help sign in
Add a TODO comment about checking bounds
d09a236Harendra Kumar
core/src/Streamly/Internal/Data/Unbox.hs+2
@@ -371,6 +371,8 @@ class Unbox a where
371 Int -> MutableByteArray -> a -> IO ()
371 Int -> MutableByteArray -> a -> IO ()
372 pokeByteIndex i arr = genericPokeByteIndex arr i
372 pokeByteIndex i arr = genericPokeByteIndex arr i
373
373
374+-- XXX Add asserts to check bounds
375+
374#define DERIVE_UNBOXED(_type, _constructor, _readArray, _writeArray, _sizeOf) \
376#define DERIVE_UNBOXED(_type, _constructor, _readArray, _writeArray, _sizeOf) \
375instance Unbox _type where { \
377instance Unbox _type where { \
376; {-# INLINE peekByteIndex #-} \
378; {-# INLINE peekByteIndex #-} \