@staticmethod
def _assert_is_bytes(v):
    """
        Assert that the value passed in is a bytes-line object or None.

        We co-opt the use of the memoryview constructor to perform the checking
        for us.

        :param v: Some value to check.
        :raises TypeError: The input value ``v`` was not of a bytes-line type.
        """
    if v is not None:
        memoryview(v)
