diff --git a/src/Data/ByteString/ToolsYj.hs b/src/Data/ByteString/ToolsYj.hs
--- a/src/Data/ByteString/ToolsYj.hs
+++ b/src/Data/ByteString/ToolsYj.hs
@@ -7,7 +7,7 @@
 
 	fromBits, fromBits', toBits, toBits',
 
-	fromBitsBE', toBitsBE
+	fromBitsBE', toBitsBE, splitAt'
 
 	) where
 
@@ -43,3 +43,8 @@
 	where
 	go 0 _ = ""
 	go n b = go (n - 1) (b `shiftR` 8) `BS.snoc` bitsToBits 8 b
+
+splitAt' :: Int -> BS.ByteString -> Maybe (BS.ByteString, BS.ByteString)
+splitAt' n bs
+	| BS.length bs < n = Nothing
+	| otherwise = Just $ BS.splitAt n bs
diff --git a/tools-yj.cabal b/tools-yj.cabal
--- a/tools-yj.cabal
+++ b/tools-yj.cabal
@@ -5,7 +5,7 @@
 -- see: https://github.com/sol/hpack
 
 name:           tools-yj
-version:        0.1.0.28
+version:        0.1.0.29
 synopsis:       Tribial tools
 description:    Please see the README on GitHub at <https://github.com/YoshikuniJujo/tools-yj#readme>
 category:       Tools
