def METHOD_NAME(beg, end):
    """
    Convert a range of characters into an unicode range literal
    (e.g. \u0064-\u006f), to be used in a Python regular expression's bracket
    expression.
    """
    if beg == end:
        return py_unicode_literal(beg)
    else:
        return "{}-{}".format(
            py_unicode_literal(beg),
            py_unicode_literal(end))