> Message: 1
> Date: Sat, 26 Dec 2015 21:15:53 +0100
> From: Joerg Sonnenberger via lldb-dev <[email protected]>
> To: [email protected]
> Subject: Re: [lldb-dev] Patch for addressing format warnings on 32-bit
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset=utf-8
>
> On Fri, Dec 25, 2015 at 06:34:09PM -0800, William Dillon via lldb-dev wrote:
>> There are a handful of -Wformat warnings on 32-bit platforms.
>> I addressed all those that I’ve seen while working on Swift.
>> Let me know if the git diff format is inappropriate for this.
>
> Don't cast size_t to uint64_t, format it with %zu directly.
>
> Joerg
>
I can go ahead and do that, but I wonder whether there should be two different
ways of handling this, even on the same line. For example:
- error.SetErrorStringWithFormat ("SoftwareBreakpointr::%s addr=0x%"
PRIx64 ": tried to read %lu bytes but only read %" PRIu64, __FUNCTION__,
m_addr, m_opcode_size, (uint64_t)bytes_read);
+ error.SetErrorStringWithFormat ("SoftwareBreakpointr::%s addr=0x%"
PRIx64 ": tried to read %" PRIu64 " bytes but only read %" PRIu64,
__FUNCTION__, m_addr, (uint64_t)m_opcode_size, (uint64_t)bytes_read);
- Will
_______________________________________________
lldb-dev mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev