changed element_length_bits to be public