From: Richard Biener <rguenther@suse.de>
To: gcc-patches@gcc.gnu.org
Subject: [PATCH 1/5] fix anti-range dumping
Date: Tue, 28 Feb 2023 14:47:17 +0100 (CET) [thread overview]
Message-ID: <20230228134718.2C43413440@imap2.suse-dmz.suse.de> (raw)
when vrange_printer::visit gets a VR_ANTI_RANGE it should print it
as such, not just print the first element as range. When
irange::num_pairs and upper/lower_bound are fixed that would no
longer print a canonicalized anti-range.
* value-range-pretty-print.cc (vrange_printer::visit):
Handle all VR_ANTI_RANGE specially.
---
gcc/value-range-pretty-print.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/value-range-pretty-print.cc b/gcc/value-range-pretty-print.cc
index d20e2562431..23817f48a3d 100644
--- a/gcc/value-range-pretty-print.cc
+++ b/gcc/value-range-pretty-print.cc
@@ -64,7 +64,7 @@ vrange_printer::visit (const irange &r) const
return;
}
// Handle legacy symbolics.
- if (!r.constant_p ())
+ if (!r.constant_p () || r.kind () == VR_ANTI_RANGE)
{
if (r.kind () == VR_ANTI_RANGE)
pp_character (pp, '~');
--
2.35.3
next reply other threads:[~2023-02-28 13:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-28 13:47 Richard Biener [this message]
2023-03-01 10:08 ` Aldy Hernandez
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=20230228134718.2C43413440@imap2.suse-dmz.suse.de \
--to=rguenther@suse.de \
--cc=gcc-patches@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: link
Be 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).