code: def viable_source_types_for_generator (generator):
      
      assert isinstance(generator, Generator)
      if generator not in __viable_source_types_cache:
          __vstg_cached_generators.append(generator)
          __viable_source_types_cache[generator] = viable_source_types_for_generator_real (generator)
  
      return __viable_source_types_cache[generator]
docs: Caches the result of 'viable_source_types_for_generator'.