This is the mail archive of the
mailing list for the GCC project.
Re: Fix for "FAIL: tmpdir-gcc.dg-struct-layout-1/t028 c_compat_x_tst.o compile, (internal compiler error)"
- From: Richard Earnshaw <rearnsha at arm dot com>
- To: Mike Stump <mikestump at comcast dot net>, "Joseph S. Myers" <joseph at codesourcery dot com>
- Cc: Andreas Schwab <schwab at suse dot de>, David Sherwood <David dot Sherwood at arm dot com>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, "vmakarov at redhat dot com" <vmakarov at redhat dot com>, Richard Sandiford <Richard dot Sandiford at arm dot com>
- Date: Wed, 01 Oct 2014 09:50:29 +0100
- Subject: Re: Fix for "FAIL: tmpdir-gcc.dg-struct-layout-1/t028 c_compat_x_tst.o compile, (internal compiler error)"
- Authentication-results: sourceware.org; auth=none
- References: <000001cfd995$c7bcafe0$57360fa0$ at arm dot com> <8738b9leiv dot fsf at e105548-lin dot cambridge dot arm dot com> <mvmwq8liky8 dot fsf at hawking dot suse dot de> <87y4t1jreq dot fsf at e105548-lin dot cambridge dot arm dot com> <mvmppediawv dot fsf at hawking dot suse dot de> <542AB5C5 dot 1030908 at arm dot com> <Pine dot LNX dot 4 dot 64 dot 1409301614310 dot 15186 at digraph dot polyomino dot org dot uk> <7C2EA902-25FC-426B-A413-712744DA453D at comcast dot net>
On 30/09/14 20:33, Mike Stump wrote:
> On Sep 30, 2014, at 9:15 AM, Joseph S. Myers <email@example.com> wrote:
>> On Tue, 30 Sep 2014, Richard Earnshaw wrote:
>>> GCC is written in C++ these days, so technically, you need the C++
>>> standard :-)
>> And, while C++14 requires plain int bit-fields to be signed, GCC is
>> written in C++98/C++03.
> So, seemingly left unstated in the thread is what is required by the language standard we write inâ From c++98:
Isn't that exactly what I suggested?
GCC is supposed to bootstrap using a portable ISO C++ compiler, there's
an argument for removing the ambiguity entirely by being explicit."
> It is implementa-
> tion-defined whether bit-fields and objects of char type are repre-
> sented as signed or unsigned quantities. The signed specifier forces
> char objects and bit-fields to be signed; it is redundant with other
> integral types.
> So, I think you need a signed on bitfields if your want them to be signed. It doesnât matter what g++ does, if we want to be portable to any C++ compiler.