public inbox for fortran@gcc.gnu.org
 help / color / mirror / Atom feed
From: Mikael Morin <morin-mikael@orange.fr>
To: Harald Anlauf <anlauf@gmx.de>, fortran@gcc.gnu.org
Cc: gcc-patches@gcc.gnu.org
Subject: Re: [PATCH, v2] Fortran: detect blanks within literal constants in free-form mode [PR92805]
Date: Fri, 29 Jul 2022 22:36:31 +0200	[thread overview]
Message-ID: <46cc765d-469e-d6e8-23c5-dc470028d881@orange.fr> (raw)
In-Reply-To: <adec596c-edb1-462a-1f2b-a8d1ff7071f5@gmx.de>

Le 29/07/2022 à 21:59, Harald Anlauf via Fortran a écrit :
> 
> Am 29.07.22 um 13:11 schrieb Mikael Morin:
> 
>  > and use gfc_next_char instead of gfc_match_char
>> in get_kind.
> 
> There is one important functionality in gfc_match_char(): it manages
> the locus.  We would need then to add this explicitly to get_kind,
> which does not look to me like a big improvement over the present
> solution.  Otherwise I get test regressions.
> 
Indeed, I overlooked that, but my opinion remains that we shouldn’t play 
with fixed vs free form considerations here.
So the options I can see are:
  - handle the locus in get_kind; we do it a lot already in matching 
functions, so it wouldn’t be different here.
  - implement a variant of gfc_match_char without space gobbling.
  - use gfc_match(...), which is a bit heavy weight to match a single 
char string, but otherwise would keep things concise.

My preference goes to the third option, but I’m fine with either of them 
if you have a different one.

  parent reply	other threads:[~2022-07-29 20:36 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-28 20:11 [PATCH] " Harald Anlauf
2022-07-29 11:11 ` Mikael Morin
2022-07-29 19:59   ` [PATCH, v2] " Harald Anlauf
2022-07-29 19:59     ` Harald Anlauf
2022-07-29 20:36     ` Mikael Morin [this message]
2022-07-29 21:09       ` [PATCH, v3] " Harald Anlauf
2022-07-29 21:09         ` Harald Anlauf
2022-07-30  7:46         ` Thomas Koenig
2022-07-30 18:32           ` Harald Anlauf
2022-07-30 18:32             ` Harald Anlauf
2022-07-30  8:28         ` Mikael Morin
2022-07-30 19:40           ` [PATCH, v4] " Harald Anlauf
2022-07-31  8:35             ` Mikael Morin
2022-07-31 19:01               ` Harald Anlauf
2022-07-31 19:01                 ` Harald Anlauf

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=46cc765d-469e-d6e8-23c5-dc470028d881@orange.fr \
    --to=morin-mikael@orange.fr \
    --cc=anlauf@gmx.de \
    --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).