[cfe-commits] [PATCH] Change wording of the warning about 'long long' being an extension

Dmitri Gribenko gribozavr at gmail.com
Mon Sep 24 08:53:07 PDT 2012


On Mon, Sep 24, 2012 at 6:48 PM, Ronan Keryell <Ronan.Keryell at silkan.com> wrote:
>>>>>> On Mon, 24 Sep 2012 15:02:11 +0300, Dmitri Gribenko <gribozavr at gmail.com> said:
>
>
>     Dmitri> Hello,
>
>     Dmitri> This patch changes the wording of the extension warning from
>
>     >> 'long long' is an extension when C99 mode is not enabled
>
>     Dmitri> to
>
>     >> 'long long' is a C++11 extension
>
>     Dmitri> while compiling in C++98 mode.
>
> Why not merging the 2 messages such as "'long long' is an extension when
> C99 or C++11 mode is not enabled" ?
>
> Rationale: some people using MSVC may use C++ only because they think
> it is the next version after C89 and cannot even imagine C99 and C11 do
> exist.
>
> So for them, advertising on both C99 and C++11 is indeed interesting. :-)

The rationale for my change is that if one has some C++ code that is
being compiled in C++98 mode, offering C99 isn't of much help, since
most C++ features are not C99-compatible.

Dmitri

-- 
main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if
(j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr at gmail.com>*/



More information about the cfe-commits mailing list