This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: [Patch,libgfortran & patch,fortran] Namelist (corrected)
Giovanni Bajo wrote:
>>I'd prefer 'if (ts->type == BT_CHARACTER) ... else ...;'.
>
> So that, when another value is added to the enumerator, the code will silently
> select the "else" branch without anyone noticing, instead of triggering an
> assert and thus requiring people to double-check the intended behaviour?
- I don't expect new types to be added to gfortran soon
- new types will most probably not require string length information
- the code ~10 lines above this hunk does exactly what you suggest
- Tobi