This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Strang code in elf_merge_symbol


In elf_merge_symbol, there is

  if (! newdyn
      && (newdef 
          || (bfd_is_com_section (sec)
              && (h->root.type == bfd_link_hash_defweak
                  || h->type == STT_FUNC)))
      && olddyn
      && olddef
      && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
      && (bind != STB_WEAK
          || h->root.type == bfd_link_hash_defweak))
    {

I don't understand

             (bfd_is_com_section (sec)
              && (h->root.type == bfd_link_hash_defweak
                  || h->type == STT_FUNC))

If the symbol is in the common section, can it be STT_FUNC?


H.J.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]