def _pad(self, a: bitarray) -> bitarray:
        """
        bitpadding, 1 then 0.

        If the array is already a multiple of blocksize, we add a full block.
        """
        pad_len = BLOCKSIZE - (len(a) % BLOCKSIZE) - 1
        padding = bitarray("1" + "0" * pad_len)
        return a + padding

        bitpadding, 1 then 0.

        If the array is already a multiple of blocksize, we add a full block.
        
structured_prompting/fairseq-version/fairseq/fairseq/data/huffman/huffman_coder.py