parameters: (to_install, package_set)
return_statement: return installed
docstring: Computes the version of packages after installing to_install.
docstring_summary: Computes the version of packages after installing to_install.
docstring_tokens: Computes the version of packages after installing to_install .
function: def _simulate_installation_of(to_install, package_set):
  
      # type: (List[InstallRequirement], PackageSet) -> Set[str]
  
      """Computes the version of packages after installing to_install.
  
      """
  
  
  
      # Keep track of packages that were installed
  
      installed = set()
  
  
  
      # Modify it as installing requirement_set would (assuming no errors)
  
      for inst_req in to_install:
  
          abstract_dist = make_distribution_for_install_requirement(inst_req)
  
          dist = abstract_dist.get_pkg_resources_distribution()
  
  
  
          assert dist is not None
  
          name = canonicalize_name(dist.key)
  
          package_set[name] = PackageDetails(dist.version, dist.requires())
  
  
  
          installed.add(name)
  
  
  
      return installed
function_tokens: def _simulate_installation_of ( to_install , package_set ) : # type: (List[InstallRequirement], PackageSet) -> Set[str] # Keep track of packages that were installed installed = set ( ) # Modify it as installing requirement_set would (assuming no errors) for inst_req in to_install : abstract_dist = make_distribution_for_install_requirement ( inst_req ) dist = abstract_dist . get_pkg_resources_distribution ( ) assert dist is not None name = canonicalize_name ( dist . key ) package_set [ name ] = PackageDetails ( dist . version , dist . requires ( ) ) installed . add ( name ) return installed