i18n for gfortran-compiled code (or Fortran in general)

Dennis Wassel dennis.wassel@googlemail.com
Wed Sep 1 07:50:00 GMT 2010


2010/8/29 Tobias Burnus <burnus@net-b.de>:
> In principle there should be no problem with Unicode (UCN-8)/UTF-8. Fortran
> 2003 supports this optionally and Fortran 2008 requires the support.
> (gfortran 4.4 has almost complete support for it, 4.6 completed it.) Cf.
> http://gcc.gnu.org/onlinedocs/gfortran/SELECTED_005fCHAR_005fKIND.html

Cool. I'll wait for 4.6 to "ripen" then!

> I think at the end it boils down to replace
>  string = "Hello World"
> by
>  string = my_i18n ("Hello World")
> where "my_i18n" checks whether for the currently requested language a
> translation is available - and if not it simply returns the original string.

I guess you're right. If I really want to go ahead with this, I guess
I'll have a look at gettext and mimic its behaviour.

> In terms of i18n support of gfortran itself: It is considered (low priority)
> to i18n the run-time error messages of libgfortran. Additionally, as Jerry
> mentioned, it is planned to support source code written in UTF-8, i.e. one
> can directly write UTF-8 character in strings - whichout using either
> char(..., kind=...) or backslashes for input.

Nice.
I completely agree that i18n for gfortran itself ought to be a
low-priority issue. At least for me it is seriously confusing when my
compilers suddenly start "talking" German to me, and I need to
re-learn all the messages :-/

Cheers,
Dennis



More information about the Fortran mailing list