Make bit_length usage more backwards compatible.