public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Martin Liska <marxin@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc(refs/users/marxin/heads/PR102955-gtoggle-ice-v3)] Reset when -gtoggle is used in gcc_options. Date: Thu, 4 Nov 2021 13:56:52 +0000 (GMT) [thread overview] Message-ID: <20211104135652.CE91C3857C58@sourceware.org> (raw) https://gcc.gnu.org/g:b458389805f3d0677b04850d95990a88df40806f commit b458389805f3d0677b04850d95990a88df40806f Author: Martin Liska <mliska@suse.cz> Date: Mon Nov 1 16:28:34 2021 +0100 Reset when -gtoggle is used in gcc_options. PR debug/102955 gcc/ChangeLog: * opts.c (finish_options): Reset flag_gtoggle when it is used. gcc/testsuite/ChangeLog: * g++.dg/pr102955.C: New test. Diff: --- gcc/opts.c | 1 + gcc/testsuite/g++.dg/pr102955.C | 14 ++++++++++++++ 2 files changed, 15 insertions(+) diff --git a/gcc/opts.c b/gcc/opts.c index 3f80fce82bc..442e6597b63 100644 --- a/gcc/opts.c +++ b/gcc/opts.c @@ -1377,6 +1377,7 @@ finish_options (struct gcc_options *opts, struct gcc_options *opts_set, if (flag_gtoggle) { + flag_gtoggle = false; if (debug_info_level == DINFO_LEVEL_NONE) { debug_info_level = DINFO_LEVEL_NORMAL; diff --git a/gcc/testsuite/g++.dg/pr102955.C b/gcc/testsuite/g++.dg/pr102955.C new file mode 100644 index 00000000000..de9689edec4 --- /dev/null +++ b/gcc/testsuite/g++.dg/pr102955.C @@ -0,0 +1,14 @@ +/* PR debug/102955 */ +/* { dg-do compile } */ +/* { dg-options "-g -gtoggle" } */ + +#pragma GCC optimize "0" +struct j +{ + explicit j (); + ~j (); +}; +void g (void) +{ + new j(); +}
reply other threads:[~2021-11-04 13:56 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20211104135652.CE91C3857C58@sourceware.org \ --to=marxin@gcc.gnu.org \ --cc=gcc-cvs@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).