

def cast_bytes(s, enc='utf-8'):
    if isinstance(s, unicode):
        return s.encode(s)
    return s

dataset/ETHPy150Open RDFLib/rdfextras/rdfextras/py3compat.py cast_bytes/VarMisuse@29/36 `enc`->`s`