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: [gold patch] Fix C++11 warnings


>> 2011-12-16 ?Cary Coutant ?<ccoutant@google.com>
>>
>> ? ? ? * dwarf_reader.cc (Sized_dwarf_line_info::read_lines): Add casts.
>> ? ? ? * i386.cc (Target_i386::do_code_fill): Use char constants for nop
>> ? ? ? arrays.
>> ? ? ? * x86_64.cc (Target_x86_64::do_code_fill): Likewise.
>
> This is OK.

I missed one file...

-cary


 ? ? ? * resolve.cc (Symbol_table::resolve): Likewise.


Index: resolve.cc
===================================================================
RCS file: /cvs/src/src/gold/resolve.cc,v
retrieving revision 1.64
diff -u -p -r1.64 resolve.cc
--- resolve.cc	18 Oct 2011 00:25:52 -0000	1.64
+++ resolve.cc	17 Dec 2011 22:08:42 -0000
@@ -336,9 +336,9 @@ Symbol_table::resolve(Sized_symbol<size>
       && to->name()[0] == '_' && to->name()[1] == 'Z')
     {
       Symbol_location fromloc
-          = { object, orig_st_shndx, sym.get_st_value() };
+          = { object, orig_st_shndx, static_cast<off_t>(sym.get_st_value()) };
       Symbol_location toloc = { to->object(), to->shndx(&to_is_ordinary),
-				to->value() };
+				static_cast<off_t>(to->value()) };
       this->candidate_odr_violations_[to->name()].insert(fromloc);
       this->candidate_odr_violations_[to->name()].insert(toloc);
     }


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