public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug preprocessor/65238] [5 Regression] __has_attribute is not handled properly with -traditional-cpp. Date: Mon, 23 Mar 2015 09:03:00 -0000 [thread overview] Message-ID: <bug-65238-4-j4MHmTXWnM@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-65238-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65238 --- Comment #10 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Author: jakub Date: Mon Mar 23 08:02:39 2015 New Revision: 221587 URL: https://gcc.gnu.org/viewcvs?rev=221587&root=gcc&view=rev Log: PR preprocessor/65238 * internal.h (_cpp_scan_out_logical_line): Add third argument. * directives.c (prepare_directive_trad): Pass false to it. * traditional.c (_cpp_read_logical_line_trad, _cpp_create_trad_definition): Likewise. (struct fun_macro): Add paramc field. (fun_like_macro): New function. (maybe_start_funlike): Handle NODE_BUILTIN macros. Initialize macro->paramc field. (save_argument): Use macro->paramc instead of macro->node->value.macro->paramc. (push_replacement_text): Formatting fix. (recursive_macro): Use fun_like_macro helper. (_cpp_scan_out_logical_line): Likewise. Add BUILTIN_MACRO_ARG argument. Initialize fmacro.paramc field. Handle builtin function-like macros. * c-c++-common/cpp/pr65238-1.c: New test. * gcc.dg/cpp/pr65238-2.c: New test. * gcc.dg/cpp/trad/pr65238-3.c: New test. * gcc.dg/cpp/trad/pr65238-4.c: New test. Added: trunk/gcc/testsuite/c-c++-common/cpp/pr65238-1.c trunk/gcc/testsuite/gcc.dg/cpp/pr65238-2.c trunk/gcc/testsuite/gcc.dg/cpp/trad/pr65238-3.c trunk/gcc/testsuite/gcc.dg/cpp/trad/pr65238-4.c Modified: trunk/gcc/testsuite/ChangeLog trunk/libcpp/ChangeLog trunk/libcpp/directives.c trunk/libcpp/internal.h trunk/libcpp/traditional.c
next prev parent reply other threads:[~2015-03-23 8:03 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2015-02-27 14:20 [Bug c/65238] New: " iains at gcc dot gnu.org 2015-02-27 18:44 ` [Bug preprocessor/65238] " mpolacek at gcc dot gnu.org 2015-03-05 10:49 ` mpolacek at gcc dot gnu.org 2015-03-07 20:59 ` iains at gcc dot gnu.org 2015-03-07 21:05 ` mpolacek at gcc dot gnu.org 2015-03-08 10:36 ` ktietz at gcc dot gnu.org 2015-03-09 12:39 ` jakub at gcc dot gnu.org 2015-03-11 15:50 ` jakub at gcc dot gnu.org 2015-03-23 9:03 ` jakub at gcc dot gnu.org [this message] 2015-03-23 9:21 ` jakub at gcc dot gnu.org
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=bug-65238-4-j4MHmTXWnM@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /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: linkBe 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).