code: def findPatternsInFile(codes, patternFinder):
      
      tree = ast.parse(codes)
      patternFinder.visit(tree)
docs: Find patterns of exceptions in a file.
  
      @param codes: code of the file to check
      @param patternFinder: a visitor for pattern checking and save results