From: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
To: Janne Blomqvist <blomqvist.janne@gmail.com>
Cc: rep.dot.nop@gmail.com, gcc-patches@gcc.gnu.org,
Bernhard Reutner-Fischer <aldot@gcc.gnu.org>,
fortran@gcc.gnu.org
Subject: Re: [PATCH 3/5] Fortran: Narrow return types [PR78798]
Date: Sun, 13 Nov 2022 11:39:38 +0100 [thread overview]
Message-ID: <20221113113938.555d4a06@nbbrfq> (raw)
In-Reply-To: <CAO9iq9F0zveVgy13TPWAqw-T7hGU3qvT91W_Drc4CC3WGHa-qg@mail.gmail.com>
On Sun, 13 Nov 2022 12:13:26 +0200
Janne Blomqvist <blomqvist.janne@gmail.com> wrote:
> On Sun, Nov 13, 2022 at 1:47 AM Bernhard Reutner-Fischer via Fortran
> <fortran@gcc.gnu.org> wrote:
> > --- a/gcc/fortran/arith.cc
> > +++ b/gcc/fortran/arith.cc
> > @@ -1135,7 +1135,7 @@ compare_complex (gfc_expr *op1, gfc_expr *op2)
> > strings. We return -1 for a < b, 0 for a == b and 1 for a > b.
> > We use the processor's default collating sequence. */
> >
> > -int
> > +signed char
> > gfc_compare_string (gfc_expr *a, gfc_expr *b)
> > {
> > size_t len, alen, blen, i;
> > @@ -1162,7 +1162,7 @@ gfc_compare_string (gfc_expr *a, gfc_expr *b)
> > }
>
> Hmm, really? PR 78798 mentions changing int to bool, where
> appropriate, which I think is uncontroversial, but this?
Well we could leave this or all spots alone where a bool is
insufficient, if you prefer.
In the case of gfc_compare_string, the only user is simplify which only
looks at ge/gt/le/lt 0
next prev parent reply other threads:[~2022-11-13 10:39 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-12 23:45 [PATCH 0/5] function result decl location; type demotion Bernhard Reutner-Fischer
2022-11-12 23:45 ` [PATCH 1/5] c: Set the locus of the function result decl Bernhard Reutner-Fischer
2022-11-14 21:25 ` Joseph Myers
2022-11-12 23:45 ` [PATCH 2/5] c++: " Bernhard Reutner-Fischer
2022-11-15 23:52 ` Jason Merrill
2022-11-12 23:45 ` [PATCH 3/5] Fortran: Narrow return types [PR78798] Bernhard Reutner-Fischer
2022-11-13 10:13 ` Janne Blomqvist
2022-11-13 10:39 ` Bernhard Reutner-Fischer [this message]
2022-11-13 20:29 ` Harald Anlauf
2022-11-13 21:50 ` Bernhard Reutner-Fischer
2023-05-10 16:47 ` [PATCH v2] " Bernhard Reutner-Fischer
2023-05-14 12:27 ` Mikael Morin
2023-05-14 13:04 ` Thomas Koenig
2023-05-14 15:24 ` Bernhard Reutner-Fischer
2023-05-14 18:06 ` Mikael Morin
2023-05-18 19:52 ` Bernhard Reutner-Fischer
2022-11-12 23:45 ` [PATCH 4/5] value-range: Add as_string diagnostics helper Bernhard Reutner-Fischer
2022-11-12 23:55 ` Andrew Pinski
2022-11-17 3:30 ` Jeff Law
2022-11-12 23:45 ` [PATCH 5/5] gimple: Add pass to note possible type demotions; IPA pro/demotion; DO NOT MERGE Bernhard Reutner-Fischer
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=20221113113938.555d4a06@nbbrfq \
--to=rep.dot.nop@gmail.com \
--cc=aldot@gcc.gnu.org \
--cc=blomqvist.janne@gmail.com \
--cc=fortran@gcc.gnu.org \
--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).