presto-main/src/main/java/io/prestosql/type/setdigest/SetDigestOperators.java/SetDigestOperators/castToHyperLogLog
class SetDigestOperators:    @ScalarOperator(CAST)
    @SqlType(StandardTypes.HYPER_LOG_LOG)
    public static Slice castToHyperLogLog(@SqlType(SetDigestType.NAME) Slice slice)
    {
        checkArgument(slice.getByte(0) == 1, "Legacy version of SetDigest cannot cast to HyperLogLog");
        int hllLength = slice.getInt(SIZE_OF_BYTE);
        return Slices.wrappedBuffer(slice.getBytes(SIZE_OF_BYTE + SIZE_OF_INT, hllLength));
    }