public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: "Владимир Андреев" <volodya@netfolder.ru>
To: Jonathan Wakely <jwakely.gcc@gmail.com>
Cc: gcc-help@gcc.gnu.org
Subject: Re: Strongly typed enums as bit fields
Date: Mon, 21 Nov 2011 04:38:00 -0000	[thread overview]
Message-ID: <CAJXPUYJpg_=z0fF6uwMG2zEqTh9ybX9n0DNLM5QRE5PTvP3Wvw@mail.gmail.com> (raw)
In-Reply-To: <CAH6eHdSwPdkOFSpVGwfSuofTxjaQtPUPEyp0t6CRoovX-owozA@mail.gmail.com>

Today I have tested Intel C++ Compiler - that is OK.

Additionally I noted, that GCC doesn't support declaration like

using NewType = OldType;

which semantically equals to

typedef OldType NewType;

2011/11/20 Jonathan Wakely <jwakely.gcc@gmail.com>:
> 2011/11/20 Владимир Андреев:
>>
>> C:\MinGW\bin>gcc E:/Test/Main.cpp -o E:/Test/Out.exe -std=c++0x
>> E:/Test/Main.cpp:9:18: error: bit-field 'Field1' with non-integral type
>>
>> MSVC 11.0 normally processes this program.
>>
>> Why GCC throws this error and MCVC doesn't?
>
> I think this should be valid, the standard says "A bit-field shall have
> integral or enumeration type (3.9.1)."
>
> Please report it to bugzilla, thanks.
>



-- 
С уважением, Владимир

  reply	other threads:[~2011-11-20 18:17 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CAJXPUYLcHEO5rMjF+BJK+5oHOePvMj8zxDU7SGZP=RezL8uR1A@mail.gmail.com>
2011-11-20  9:06 ` Владимир Андреев
2011-11-20 18:17   ` Jonathan Wakely
2011-11-21  4:38     ` Владимир Андреев [this message]
2011-11-21  4:47       ` Jonathan Wakely

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJXPUYJpg_=z0fF6uwMG2zEqTh9ybX9n0DNLM5QRE5PTvP3Wvw@mail.gmail.com' \
    --to=volodya@netfolder.ru \
    --cc=gcc-help@gcc.gnu.org \
    --cc=jwakely.gcc@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).