public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Janus Weil <janus@gcc.gnu.org>
To: Mikael Morin <mikael.morin@sfr.fr>
Cc: Tobias Burnus <burnus@net-b.de>, gfortran <fortran@gcc.gnu.org>,
		gcc-patches <gcc-patches@gcc.gnu.org>
Subject: Re: [Patch, Fortran] gfc_notify_std cleanup
Date: Tue, 17 Jul 2012 21:55:00 -0000	[thread overview]
Message-ID: <CAKwh3qiRoJMuiwQdMcWpYH3az-XDeg1OfdtruVZKqEQa=WaA4Q@mail.gmail.com> (raw)
In-Reply-To: <CAKwh3qjyoQ7TcHSVqAWpZEipyP850pCyMtiSN3GE034gzQnm8Q@mail.gmail.com>

>>>> Okay, that won't work as one has to call error_print only once. Maybe
>>>> something like the following will work:
>>>>
>>>> const char *msg, *msg2;
>>>> char *buffer;
>>>>   msg = _("Warning: ");
>>>>   msg2 = _("Deleted feature:");
>>>>   buffer = (char *) alloca (strlen (msg) + strlen (msg2)+1);
>>>>   strcpy(buffer, msg);
>>>>   strcat (buffer, msg2);
>>>>   error_print (buffer, _(gmsgid), argp);
>>>>
>>>> where the buffer itself is not send through _().
>>>
>>> With this you are almost back to my last version, except that you
>>> allocate the buffer dynamically.
>> ... which is better ;-).
>
> Yes, of course it's better :)
>
> Attached is a new version, which uses the dynamic allocation as
> proposed by Tobias.
>
>
>> Nice patch anyway.
>
> Thanks. In case there are more comments on the patch, just keep it
> coming. Otherwise I'll commit the attached version soon (once I'm done
> with the tedious task of writing a ChangeLog for this baby).

Committed as r189589.

Cheers,
Janus

  reply	other threads:[~2012-07-17 21:55 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-17  9:42 Janus Weil
2012-07-17 10:03 ` Tobias Burnus
2012-07-17 11:48   ` Janus Weil
2012-07-17 12:50     ` Janus Weil
2012-07-17 13:26       ` Tobias Burnus
2012-07-17 14:45         ` Janus Weil
2012-07-17 18:56           ` Mikael Morin
2012-07-17 20:00             ` Janus Weil
2012-07-17 21:55               ` Janus Weil [this message]
2012-07-17 19:25   ` Mikael Morin
2012-07-17 19:40     ` Tobias Burnus

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='CAKwh3qiRoJMuiwQdMcWpYH3az-XDeg1OfdtruVZKqEQa=WaA4Q@mail.gmail.com' \
    --to=janus@gcc.gnu.org \
    --cc=burnus@net-b.de \
    --cc=fortran@gcc.gnu.org \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=mikael.morin@sfr.fr \
    /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).