parameters: (path)
docstring: Same as os.path.splitext() but faster.
docstring_summary: Same as os.path.splitext() but faster.
docstring_tokens: Same as os . path . splitext () but faster .
function: def splitext(path):
      "Same as os.path.splitext() but faster."
      sep = rightmost_separator(path, os.sep)
      dot = path.rfind('.')
      # An ext is only real if it has at least one non-digit char
      if dot > sep and not containsOnly(path[dot:], "0123456789."):
          return path[:dot],path[dot:]
      else:
          return path,""
function_tokens: def splitext ( path ) : sep = rightmost_separator ( path , os . sep ) dot = path . rfind ( '.' ) # An ext is only real if it has at least one non-digit char if dot > sep and not containsOnly ( path [ dot : ] , "0123456789." ) : return path [ : dot ] , path [ dot : ] else : return path , ""