Re: [Patch, Fortran] gfc_notify_std cleanup

2012-07-17 Thread Janus Weil
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

Re: [Patch, Fortran] gfc_notify_std cleanup

2012-07-17 Thread Tobias Burnus
Mikael Morin wrote: On 17/07/2012 12:03, Tobias Burnus wrote: On 07/17/2012 11:42 AM, Janus Weil wrote: +case GFC_STD_F2008_TS: + strcat (buffer, " TS 29113:"); + break; That's currently correct. However, there is another post-Fortran 2008 Technical Specification in preparation.

Re: [Patch, Fortran] gfc_notify_std cleanup

2012-07-17 Thread Mikael Morin
On 17/07/2012 12:03, Tobias Burnus wrote: > On 07/17/2012 11:42 AM, Janus Weil wrote: >> +case GFC_STD_F2008_TS: >> + strcat (buffer, " TS 29113:"); >> + break; > > That's currently correct. However, there is another post-Fortran 2008 > Technical Specification in preparation. (Coarra

Re: [Patch, Fortran] gfc_notify_std cleanup

2012-07-17 Thread Mikael Morin
Hello, On 17/07/2012 16:44, Janus Weil wrote: > Hi, > >> Ditto here. Though, I think you are in danger of exceeding the buffer - if >> not here, then further down. > > admitted - the buffer length could clearly be a problem (in connection > with translation). > > >> Wouldn't it be simplyer to

Re: [Patch, Fortran] gfc_notify_std cleanup

2012-07-17 Thread Janus Weil
Hi, > Ditto here. Though, I think you are in danger of exceeding the buffer - if > not here, then further down. admitted - the buffer length could clearly be a problem (in connection with translation). > Wouldn't it be simplyer to keep the error print for Warning/Error, assign > the messages t

Re: [Patch, Fortran] gfc_notify_std cleanup

2012-07-17 Thread Tobias Burnus
I am far from being a gettext expert, but I think the new version doesn't work. My understanding is that one can either mark strings for translation - or one inserts a translation function call, which also marks them for translation. In either case, the string passed to gettext will be used as

Re: [Patch, Fortran] gfc_notify_std cleanup

2012-07-17 Thread Tobias Burnus
On 07/17/2012 11:42 AM, Janus Weil wrote: here is a patch which makes 'gfc_notify_std' print the relevant version of the Fortran standard automatically when issuing errors/warnings. Up to now this had to be done manually and was forgotten (or inconsistent) I think the patch is a good idea. Some