Commit 268be88c by Bernd Edlinger Committed by Bernd Edlinger

re PR c++/69865 (-trigraphs option broken)

gcc/c-family/ChangeLog:
2016-02-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>

        PR c++/69865
        * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
        here...
        (c_common_init_options): ...to here.
        (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.

gcc/testsuite/ChangeLog:
2016-02-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>

        PR c++/69865
        * c-c++-common/Wshift-negative-value-6.c: Add -std=c++11 before
        -std=c++03.

From-SVN: r233574
parent f3609a89
2016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
PR c++/69865
* c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
here...
(c_common_init_options): ...to here.
(set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
2016-02-19 Jakub Jelinek <jakub@redhat.com>
PR c++/69826
......
......@@ -246,6 +246,10 @@ c_common_init_options (unsigned int decoded_options_count,
}
}
/* Set C++ standard to C++14 if not specified on the command line. */
if (c_dialect_cxx ())
set_std_cxx14 (/*ISO*/false);
global_dc->colorize_source_p = true;
}
......@@ -802,10 +806,6 @@ c_common_post_options (const char **pfilename)
&& flag_no_builtin)
flag_tree_loop_distribute_patterns = 0;
/* Set C++ standard to C++14 if not specified on the command line. */
if (c_dialect_cxx () && cxx_dialect == cxx_unset)
set_std_cxx14 (/*ISO*/false);
/* -Woverlength-strings is off by default, but is enabled by -Wpedantic.
It is never enabled in C++, as the minimum limit is not normative
in that standard. */
......@@ -1519,6 +1519,8 @@ set_std_cxx98 (int iso)
flag_no_gnu_keywords = iso;
flag_no_nonansi_builtin = iso;
flag_iso = iso;
flag_isoc94 = 0;
flag_isoc99 = 0;
cxx_dialect = cxx98;
lang_hooks.name = "GNU C++98";
}
......
2016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
PR c++/69865
* c-c++-common/Wshift-negative-value-6.c: Add -std=c++11 before
-std=c++03.
2016-02-19 Jakub Jelinek <jakub@redhat.com>
PR c++/69826
......
/* PR c/65179 */
/* { dg-do compile } */
/* { dg-options "-O -Wextra" } */
/* { dg-additional-options "-std=c++03" { target c++ } } */
/* { dg-additional-options "-std=c++11 -std=c++03" { target c++ } } */
/* { dg-additional-options "-std=c90" { target c } } */
enum E {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment