docs: def cache_nodes(gir_root, all_girs):
      '''
      Identify and store all the gir symbols the symbols we will document
      may link to, or be typed with
      '''
      ns_node = gir_root.find('./{%s}namespace' % NS_MAP['core'])
      id_prefixes = ns_node.attrib['{%s}identifier-prefixes' % NS_MAP['c']]
      sym_prefixes = ns_node.attrib['{%s}symbol-prefixes' % NS_MAP['c']]
  
      id_key = '{%s}identifier' % NS_MAP['c']
      for node in gir_root.xpath(
              './/*[@c:identifier]',
              namespaces=NS_MAP):
          make_translations (node.attrib[id_key], node)
  
      id_type = c_ns('type')
      glib_type = glib_ns('type-name')
      class_tag = core_ns('class')
      callback_tag = core_ns('callback')
      interface_tag = core_ns('interface')
      for node in gir_root.xpath('.//*[not(self::core:type) and not (self::core:array)][@c:type or @glib:type-name]',
              namespaces=NS_MAP):
          try:
              name = node.attrib[id_type]
          except KeyError:
              name = node.attrib[glib_type]
          make_translations (name, node)
          gi_name = '.'.join(get_gi_name_components(node))
          ALL_GI_TYPES[gi_name] = get_klass_name(node)
          if node.tag in (class_tag, interface_tag):
              __update_hierarchies (ns_node.attrib.get('name'), node, gi_name)
              make_translations('%s::%s' % (name, name), node)
              __generate_smart_filters(id_prefixes, sym_prefixes, node)
          elif node.tag in (callback_tag,):
              ALL_CALLBACK_TYPES.add(node.attrib[c_ns('type')])
  
      for field in gir_root.xpath('.//self::core:field', namespaces=NS_MAP):
          unique_name = get_field_c_name(field)
          make_translations(unique_name, field)
  
      for node in gir_root.xpath(
              './/core:property',
              namespaces=NS_MAP):
          name = '%s:%s' % (get_klass_name(node.getparent()),
                            node.attrib['name'])
          make_translations (name, node)
  
      for node in gir_root.xpath(
              './/glib:signal',
              namespaces=NS_MAP):
          name = '%s::%s' % (get_klass_name(node.getparent()),
                             node.attrib['name'])
          make_translations (name, node)
  
      for node in gir_root.xpath(
              './/core:virtual-method',
              namespaces=NS_MAP):
          name = get_symbol_names(node)[0]
          make_translations (name, node)
  
      for inc in gir_root.findall('./core:include',
              namespaces = NS_MAP):
          inc_name = inc.attrib["name"]
          inc_version = inc.attrib["version"]
          gir_file = __find_gir_file('%s-%s.gir' % (inc_name, inc_version), all_girs)
          if not gir_file:
              warn('missing-gir-include', "Couldn't find a gir for %s-%s.gir" %
                      (inc_name, inc_version))
              continue
  
          if gir_file in __PARSED_GIRS:
              continue
  
          __PARSED_GIRS.add(gir_file)
          inc_gir_root = etree.parse(gir_file).getroot()
          cache_nodes(inc_gir_root, all_girs)