

@classmethod
def frombytes(cls, octets):
    typecode = chr(cls[0])
    memv = memoryview(octets[1:]).cast(typecode)
    return cls(*memv)

dataset/ETHPy150Open fluentpython/example-code/09-pythonic-obj/vector2d_v1.py Vector2d.frombytes/VarMisuse@19/22 `octets`->`cls`