Unicode raw string containing \u
"Martin v. Löwis"
martin at v.loewis.de
Sun Oct 28 04:30:21 EDT 2007
> That doesn't answer my question, since I asked for a unicode RAW
> string literal. Is this not possible? (I was able to get what I want
> using ur"\u005Cuniverse", although this is not totally ideal.)
It's a design flaw in Unicode raw string literals that they still
interpret \u escapes. And yes, your notation is one way to get what
you want; another is u"\\"+r"universe", although I'm unsure whether
that meets your requirements.
Regards,
Martin
More information about the Python-list
mailing list