title: PyYaml.load_all() returns generator rather than a dict?
body: <p>I am working with Yaml (and Python!) for the first time. I am attempting to load multiple documents from within a single .yaml file, but not getting a result that I would expect. I am expecting a dict of dicts back containing each of the documents, but am instead getting a generator object...? I should note that when I used yaml.load() in a previous test (instead of load_all()) on a <em>single</em> document yaml file, I was able to get a dictionary back just fine.</p>
  
  <p>What obvious thing am I missing that is preventing me from receiving multiple docs back?</p>
  
  <p>The test yaml:</p>
  
  <pre><code>---
  Tiles:
   dungeon_floor:
     name: 'Dungeon Floor'
     blocked: False
     block_sight: False
     terrain_type: CONST.E_TERRAIN_TYPES.FLAT_FLOOR
     persistent_effects: 'None'
  ...
  ---
  NPCs:
   gnoll:
     name: "Gnoll"
     equipment: Sword, Shield
  
  def yaml_loader(filepath):
      """Load a yaml file."""
      with open(filepath, "r") as file_descriptor:
          data = yaml.load_all(file_descriptor)
      return data
  </code></pre>
  
  <p>And the code attempting to load and print the dict:</p>
  
  <pre><code>def yaml_loader(filepath):
      """Load a yaml file."""
      with open(filepath, "r") as file_descriptor:
          data = yaml.load_all(file_descriptor)
      return data
  
  if __name__ == "__main__":
      filepath = CONST.YAML_ECS_CONFIG_PATH
      data = yaml_loader(filepath)
      print(data)
  </code></pre>
  
  <p>...produces the following terminal output:</p>
  
  <pre><code>&lt;generator object load_all at 0x0000000003A64990&gt;
  
  Process finished with exit code 0
  </code></pre>