summaryrefslogtreecommitdiffstats
path: root/Lib/genericpath.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/genericpath.py')
-rw-r--r--Lib/genericpath.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/Lib/genericpath.py b/Lib/genericpath.py
index 7ddb94c..2648e54 100644
--- a/Lib/genericpath.py
+++ b/Lib/genericpath.py
@@ -10,6 +10,14 @@ __all__ = ['commonprefix', 'exists', 'getatime', 'getctime', 'getmtime',
'getsize', 'isdir', 'isfile']
+try:
+ _unicode = unicode
+except NameError:
+ # If Python is built without Unicode support, the unicode type
+ # will not exist. Fake one.
+ class _unicode(object):
+ pass
+
# Does a path exist?
# This is false for dangling symbolic links on systems that support them.
def exists(path):