review/rutil.py @ cada9aab8b6f

tests: add some tests for non-ascii diffs
author Steve Losh <steve@stevelosh.com>
date Fri, 23 Jul 2010 21:30:38 -0400
parents 96afc843f1a7
children (none)
from mercurial import encoding

def tolocal(s):
    return encoding.tolocal(s.encode('UTF-8'))

def fromlocal(s):
    return s.decode(encoding.encoding, 'replace')