[GOLD] powerpc64 ODR violation check

Ian Lance Taylor iant@google.com
Fri Mar 8 06:09:00 GMT 2013

On 3/7/13, Alan Modra <amodra@gmail.com> wrote:

> - Moving find_shdr to Object requires specifying template parameters
> explicitly since the arguments don't allow a compiler to deduce them.
> I didn't know how to do that using this->find_shdr() syntax, or if it
> is even possible.

You just write
    this->find_shdr<size, big_endian>(...)
Do that instead of the Object::find_shdr approach.

> +  // Find the section header with the given NAME.  If HDR is non-NULL
> +  // then it is a section header returned from a previous call to this
> +  // function and the next section header with the same name will be
> +  // returned.
> +  template<int size, bool big_endian>
> +  const unsigned char*
> +  find_shdr(const unsigned char* /*pshdrs*/, const char* /*name*/,
> +	    const char* /*names*/, section_size_type /*names_size*/,
> +	    const unsigned char* /*hdr*/) const;

You don't need to comment out the parameter names here.

This is OK with those changes.



More information about the Binutils mailing list