https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92296

--- Comment #18 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Thu Nov 21 17:15:56 2019
New Revision: 278581

URL: https://gcc.gnu.org/viewcvs?rev=278581&root=gcc&view=rev
Log:
        Backported from mainline
        2019-10-31  Jakub Jelinek  <ja...@redhat.com>

        PR preprocessor/92296
        * internal.h (struct def_pragma_macro): Add is_builtin bitfield.
        (_cpp_restore_special_builtin): Declare.
        * init.c (_cpp_restore_special_builtin): New function.
        * directives.c (do_pragma_push_macro): For NT_MACRO with NODE_BUILTIN
        set is_builtin and don't try to grab definition.
        (cpp_pop_definition): Use _cpp_restore_special_builtin to restore
        builtin macros.

        * c-c++-common/cpp/pr92296-1.c: New test.
        * c-c++-common/cpp/pr92296-2.c: New test.

Added:
    branches/gcc-8-branch/gcc/testsuite/c-c++-common/cpp/pr92296-1.c
    branches/gcc-8-branch/gcc/testsuite/c-c++-common/cpp/pr92296-2.c
Modified:
    branches/gcc-8-branch/gcc/testsuite/ChangeLog
    branches/gcc-8-branch/libcpp/ChangeLog
    branches/gcc-8-branch/libcpp/directives.c
    branches/gcc-8-branch/libcpp/init.c
    branches/gcc-8-branch/libcpp/internal.h

Reply via email to