<s> """<STR_LIT>""" <EOL> import os <EOL> import sys <EOL> import stat <EOL> import genericpath <EOL> import warnings <EOL> from genericpath import * <EOL> __all__ = [ "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , <EOL> "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , <EOL> "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , <EOL> "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , <EOL> "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , <EOL> "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , <EOL> "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" , "<STR_LIT>" ] <EOL> curdir = '<STR_LIT:.>' <EOL> pardir = '<STR_LIT:..>' <EOL> extsep = '<STR_LIT:.>' <EOL> sep = '<STR_LIT:/>' <EOL> pathsep = '<STR_LIT::>' <EOL> defpath = '<STR_LIT>' <EOL> altsep = None <EOL> devnull = '<STR_LIT>' <EOL> def normcase ( s ) : <EOL> """<STR_LIT>""" <EOL> return s <EOL> def isabs ( s ) : <EOL> """<STR_LIT>""" <EOL> return s . startswith ( '<STR_LIT:/>' ) <EOL> def join ( a , * p ) : <EOL> """<STR_LIT>""" <EOL> path = a <EOL> for b in p : <EOL> if b . startswith ( '<STR_LIT:/>' ) : <EOL> path = b <EOL> elif path == '<STR_LIT>' or path . endswith ( '<STR_LIT:/>' ) : <EOL> path += b <EOL> else : <EOL> path += '<STR_LIT:/>' + b <EOL> return path <EOL> def split ( p ) : <EOL> """<STR_LIT>""" <EOL> i = p . rfind ( '<STR_LIT:/>' ) + <NUM_LIT:1> <EOL> head , tail = p [ : i ] , p [ i : ] <EOL> if head and head != '<STR_LIT:/>' * len ( head ) : <EOL> head = head . rstrip ( '<STR_LIT:/>' ) <EOL> return head , tail <EOL> def splitext ( p ) : <EOL> return genericpath . _splitext ( p , sep , altsep , extsep ) <EOL> splitext . __doc__ = genericpath . _splitext . __doc__ <EOL> def splitdrive ( p ) : <EOL> """<STR_LIT>""" <EOL> return '<STR_LIT>' , p <EOL> def basename ( p ) : <EOL> """<STR_LIT>""" <EOL> i = p . rfind ( '<STR_LIT:/>' ) + <NUM_LIT:1> <EOL> return p [ i : ] <EOL> def dirname ( p ) : <EOL> """<STR_LIT>""" <EOL> i = p . rfind ( '<STR_LIT:/>' ) + <NUM_LIT:1> <EOL> head = p [ : i ] <EOL> if head and head != '<STR_LIT:/>' * len ( head ) : <EOL> head = head . rstrip ( '<STR_LIT:/>' ) <EOL> return head <EOL> def samestat ( s1 , s2 ) : <EOL> """<STR_LIT>""" <EOL> return s1 . st_ino == s2 . st_ino and s1 . st_dev == s2 . st_dev <EOL> def normpath ( path ) : <EOL> """<STR_LIT>""" <EOL> slash , dot = ( u'<STR_LIT:/>' , u'<STR_LIT:.>' ) if isinstance ( path , unicode ) else ( '<STR_LIT:/>' , '<STR_LIT:.>' ) <EOL> if path == '<STR_LIT>' : <EOL> return dot <EOL> initial_slashes = path . startswith ( '<STR_LIT:/>' ) <EOL> if ( initial_slashes and <EOL> path . startswith ( '<STR_LIT>' ) and not path . startswith ( '<STR_LIT>' ) ) : <EOL> initial_slashes = <NUM_LIT:2> <EOL> comps = path . split ( '<STR_LIT:/>' ) <EOL> new_comps = [ ] <EOL> for comp in comps : <EOL> if comp in ( '<STR_LIT>' , '<STR_LIT:.>' ) : <EOL> continue <EOL> if ( comp != '<STR_LIT:..>' or ( not initial_slashes and not new_comps ) or <EOL> ( new_comps and new_comps [ - <NUM_LIT:1> ] == '<STR_LIT:..>' ) ) : <EOL> new_comps . append ( comp ) <EOL> elif new_comps : <EOL> new_comps . pop ( ) <EOL> comps = new_comps <EOL> path = slash . join ( comps ) <EOL> if initial_slashes : <EOL> path = slash * initial_slashes + path <EOL> return path or dot <EOL> def abspath ( path ) : <EOL> """<STR_LIT>""" <EOL> return normpath ( path ) <EOL> def realpath ( filename ) : <EOL> return abspath ( filename ) <EOL> def islink ( path ) : <EOL> raise NotImplemented ( ) <EOL> def lexists ( path ) : <EOL> raise NotImplemented ( ) <EOL> def samefile ( f1 , f2 ) : <EOL> raise NotImplemented ( ) <EOL> def sameopenfile ( fp1 , fp2 ) : <EOL> raise NotImplemented ( ) <EOL> def ismount ( path ) : <EOL> raise NotImplemented ( ) <EOL> def walk ( top , func , arg ) : <EOL> raise NotImplemented ( ) <EOL> def expanduser ( path ) : <EOL> raise NotImplemented ( ) <EOL> def expandvars ( path ) : <EOL> raise NotImplemented ( ) <EOL> supports_unicode_filenames = ( sys . platform == '<STR_LIT>' ) <EOL> def relpath ( path , start = curdir ) : <EOL> raise NotImplemented ( ) </s>
