def usages_add_import_modules(evaluator, definitions):
 new = set()
 for d in definitions:
  imp_or_stmt = d.get_definition()
  if isinstance(imp_or_stmt, tree.Import):
   s = imports.ImportWrapper(evaluator, d)
   new |= set(s.follow(is_goto=True))
 return (set(definitions) | new)

def usages_add_import_modules ( evaluator , definitions ) : new = set ( ) for d in definitions : imp_or_stmt = d . get_definition ( ) if isinstance ( imp_or_stmt , tree . Import ) : s = imports . ImportWrapper ( evaluator , d ) new |= set ( s . follow ( is_goto = True ) ) return ( set ( definitions ) | new )
adds the modules of the imports .