This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/77388] Reference to a packed structure member
- From: "rguenther at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 26 Aug 2016 12:33:23 +0000
- Subject: [Bug c++/77388] Reference to a packed structure member
- Auto-submitted: auto-generated
- References: <bug-77388-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77388
--- Comment #6 from rguenther at suse dot de <rguenther at suse dot de> ---
On Fri, 26 Aug 2016, andre.simoesdiasvieira at arm dot com wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77388
>
> --- Comment #5 from Andre Vieira <andre.simoesdiasvieira at arm dot com> ---
> I see, thank you!
>
> Oh and leaving out the const yields an error:
> t.cpp:28:16: error: cannot bind packed field '((B*)this)->B::s->test_struct::c'
> to 'short int&'
> return A (s->c);
Ah, great!