diff --git a/rlp/encode.go b/rlp/encode.go
index 2aeee472192662d1bd059d3ba2ecfc4e54c6d8b9..d73b17c282a3690cf8ab0a5ddfcf04e78d733a62 100644
--- a/rlp/encode.go
+++ b/rlp/encode.go
@@ -45,12 +45,6 @@ type Encoder interface {
 	EncodeRLP(io.Writer) error
 }
 
-// ListSize returns the encoded size of an RLP list with the given
-// content size.
-func ListSize(contentSize uint64) uint64 {
-	return uint64(headsize(contentSize)) + contentSize
-}
-
 // Encode writes the RLP encoding of val to w. Note that Encode may
 // perform many small writes in some cases. Consider making w
 // buffered.
diff --git a/rlp/raw.go b/rlp/raw.go
index fca445618d78d8c66654432745ffaf742bbc20a5..33aae6ee53999e3e027da2d6587c340fdebe6f1d 100644
--- a/rlp/raw.go
+++ b/rlp/raw.go
@@ -28,6 +28,12 @@ type RawValue []byte
 
 var rawValueType = reflect.TypeOf(RawValue{})
 
+// ListSize returns the encoded size of an RLP list with the given
+// content size.
+func ListSize(contentSize uint64) uint64 {
+	return uint64(headsize(contentSize)) + contentSize
+}
+
 // Split returns the content of first RLP value and any
 // bytes after the value as subslices of b.
 func Split(b []byte) (k Kind, content, rest []byte, err error) {