This is the mail archive of the binutils@sourceware.org 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]
Other format: [Raw text]

Re: Support Xilinx MicroBlaze processor - patch 1


Tom Tromey wrote:
"Andreas" == Andreas Schwab <schwab@redhat.com> writes:

Andreas> A cast expression is not an lvalue. Andreas> See <http://sourceware.org/ml/binutils/2005-08/msg00423.html>.

Yes. (Shouldn't gcc complain about this?)


Yeah, I'm actually testing the appended patch.
Other BFD ports seem to do this.

I don't think a dummy variable is required. There are two cases where a cast is used with an &. This should fix both:

Index: bfd/elf32-microblaze.c
===================================================================
RCS file: /cvs/src/src/bfd/elf32-microblaze.c,v
retrieving revision 1.1
diff -r1.1 elf32-microblaze.c
2115c2115
<                 head = &((struct elf32_mb_link_hash_entry *) h)->dyn_relocs;
---
>                 head = ((struct elf32_mb_link_hash_entry **) h)->dyn_relocs;
2135c2135
<                           &elf_section_data (s)->local_dynrel);
---
>                           elf_section_data (s)->local_dynrel);

--
Michael Eager	 eager@eagercon.com
1960 Park Blvd., Palo Alto, CA 94306  650-325-8077


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