strategy.
Kind regards,
Roger
From: meta...@gmail.com on behalf of Richard Smith
Sent: 15 July 2016 01:28:57
To: Reid Kleckner
Cc: Roger Ferrer Ibanez; cfe-commits
Subject: Re: r275417 - Diagnose taking address and reference binding of packed
members
OK
OK, actually, GCC is doing something a lot more clever here.
Here's what seems to really be going on:
Packed members are modeled somewhat like bitfield members: a packed member
lvalue is a different kind of lvalue to which a reference cannot be bound
(like a bitfield). An attempt to bind a const
It appears that GCC accepts that case. More generally, it looks like GCC
suppresses the warning when the reference is a function parameter (any
function, not just a copy constructor or similar). I'm not sure if that's
an intentional feature or a bug, but it should be pretty easy for us to be
compat
I wonder if GCC accepts this:
In file included from ../../net/tools/quic/quic_epoll_clock_test.cc:7:
In file included from
../../net/tools/quic/test_tools/mock_epoll_server.h:16:
In file included from ../../net/tools/epoll_server/epoll_server.h:41:
../../build/linux/debian_wheezy_amd64-sysroot/usr
On Thu, Jul 14, 2016 at 3:52 PM, Reid Kleckner via cfe-commits <
cfe-commits@lists.llvm.org> wrote:
> Why did we upgrade the unaligned reference binding from a warning to an
> error? That will make it hard to roll this change out across many codebases.
>
GCC has given an error on this since versi
Why did we upgrade the unaligned reference binding from a warning to an
error? That will make it hard to roll this change out across many codebases.
On Thu, Jul 14, 2016 at 7:10 AM, Roger Ferrer Ibanez via cfe-commits <
cfe-commits@lists.llvm.org> wrote:
> Author: rogfer01
> Date: Thu Jul 14 09:1
*Sent:* 14 July 2016 22:14:10
> *To:* Richard Smith
> *Cc:* Roger Ferrer Ibanez; cfe-commits
> *Subject:* Re: r275417 - Diagnose taking address and reference binding of
> packed members
>
> On Thu, Jul 14, 2016 at 5:07 PM, Richard Smith
> wrote:
>
>> On Thu, Jul 14, 2016
- Diagnose taking address and reference binding of packed
members
On Thu, Jul 14, 2016 at 5:07 PM, Richard Smith
mailto:rich...@metafoo.co.uk>> wrote:
On Thu, Jul 14, 2016 at 10:15 AM, Nico Weber via cfe-commits
mailto:cfe-commits@lists.llvm.org>> wrote:
Hi,
this fires on (at least) u
On Thu, Jul 14, 2016 at 5:07 PM, Richard Smith
wrote:
> On Thu, Jul 14, 2016 at 10:15 AM, Nico Weber via cfe-commits <
> cfe-commits@lists.llvm.org> wrote:
>
>> Hi,
>>
>> this fires on (at least) usrsctplib [1]:
>>
>> FAILED: obj/third_party/usrsctp/usrsctp/sctp_input.o
>> ../../third_party/usrsc
On Thu, Jul 14, 2016 at 10:15 AM, Nico Weber via cfe-commits <
cfe-commits@lists.llvm.org> wrote:
> Hi,
>
> this fires on (at least) usrsctplib [1]:
>
> FAILED: obj/third_party/usrsctp/usrsctp/sctp_input.o
> ../../third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_input.c:1708:15:
> error: tak
Weber
Sent: 14 July 2016 18:15:42
To: Roger Ferrer Ibanez
Cc: cfe-commits
Subject: Re: r275417 - Diagnose taking address and reference binding of packed
members
Hi,
this fires on (at least) usrsctplib [1]:
FAILED: obj/third_party/usrsctp/usrsctp/sctp_input.o
../../third_party/usrsctp/usrsctplib
Hi,
this fires on (at least) usrsctplib [1]:
FAILED: obj/third_party/usrsctp/usrsctp/sctp_input.o
../../third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_input.c:1708:15:
error: taking address of packed member 'time_entered' of class or structure
'sctp_state_cookie' may result in an unaligne
Author: rogfer01
Date: Thu Jul 14 09:10:43 2016
New Revision: 275417
URL: http://llvm.org/viewvc/llvm-project?rev=275417&view=rev
Log:
Diagnose taking address and reference binding of packed members
This patch implements PR#22821.
Taking the address of a packed member is dangerous since the redu
13 matches
Mail list logo