def _import_string(names):
 _names = []
 for (name, asname) in names:
  if (asname is not None):
   _names.append(('%s as %s' % (name, asname)))
  else:
   _names.append(name)
 return ', '.join(_names)

def _import_string ( names ) : _names = [ ] for ( name , asname ) in names : if ( asname is not None ) : _names . append ( ( '%s as %s' % ( name , asname ) ) ) else : _names . append ( name ) return ', ' . join ( _names )
return a list of formatted as a string .