hm. oversight on my part. we don't allow negative lengths, so might as well use `TO_UINT32(length)`.