tfchain/encoders/rivine.py
def _add_slice_length(self, length):
        """
        Encodes the length of the slice
        """
        if length < pow(2, 7):
            self.add_int8(length << 1)
        elif length < pow(2, 14):
            self.add_int16(1 | length << 2)
        elif length < pow(2, 21):
            self.add_int24(3 | length << 3)
        elif length < pow(2, 29):
            self.add_int32(7 | length << 3)
        else:
            raise SliceLengthOutOfRange(
                "slice length {} is out of range".format(length))

        Encodes the length of the slice
        
Encodes the length of the slice
Encodes the length of the slice
def _add_slice_length(self, length):
        if length < pow(2, 7):
            self.add_int8(length << 1)
        elif length < pow(2, 14):
            self.add_int16(1 | length << 2)
        elif length < pow(2, 21):
            self.add_int24(3 | length << 3)
        elif length < pow(2, 29):
            self.add_int32(7 | length << 3)
        else:
            raise SliceLengthOutOfRange(
                "slice length {} is out of range".format(length))
def _add_slice_length ( self , length ) : if length < pow ( 2 , 7 ) : self . add_int8 ( length << 1 ) elif length < pow ( 2 , 14 ) : self . add_int16 ( 1 | length << 2 ) elif length < pow ( 2 , 21 ) : self . add_int24 ( 3 | length << 3 ) elif length < pow ( 2 , 29 ) : self . add_int32 ( 7 | length << 3 ) else : raise SliceLengthOutOfRange ( "slice length {} is out of range" . format ( length ) )
Encodes the length of the slice
Encodes the length of the slice
"""
        Encodes the length of the slice
        """
self
length