Mercurial > hg
comparison mercurial/windows.py @ 17203:0cb55b5c19a3
util, posix: eliminate encodinglower and encodingupper
2ebe3d0ce91d claims this was needed "to avoid cyclic dependency", but there is
no cyclic dependency.
windows.py already imports encoding, posix.py can import it too, so we can
simply use encoding.upper in windows.py and in posix.py.
(this is a partial backout of 2ebe3d0ce91d)
author | Adrian Buehlmann <adrian@cadifra.com> |
---|---|
date | Wed, 18 Jul 2012 14:41:58 +0200 |
parents | 80142f385af9 |
children | c315842cb25f |
comparison
equal
deleted
inserted
replaced
17202:1ae119269ddc | 17203:0cb55b5c19a3 |
---|---|
128 return path.replace('/', '\\') | 128 return path.replace('/', '\\') |
129 | 129 |
130 def normpath(path): | 130 def normpath(path): |
131 return pconvert(os.path.normpath(path)) | 131 return pconvert(os.path.normpath(path)) |
132 | 132 |
133 encodinglower = None | |
134 encodingupper = None | |
135 | |
136 def normcase(path): | 133 def normcase(path): |
137 return encodingupper(path) | 134 return encoding.upper(path) |
138 | 135 |
139 def realpath(path): | 136 def realpath(path): |
140 ''' | 137 ''' |
141 Returns the true, canonical file system path equivalent to the given | 138 Returns the true, canonical file system path equivalent to the given |
142 path. | 139 path. |