------- Comment #7 from jakub at gcc dot gnu dot org  2009-05-20 14:32 -------
For all involved strings being non-array CHAR with length 1 I fail to see why
normal SWITCH_EXPR isn't used instead (though that would just be an
optimization).

The middle-end can't know the _gfortran_select_string function will never
return numbers bigger than the size of the jump table it is called with, so the
Fortran FE should help it.  If the table contains a default label, it should
use a default: case label instead of corresponding number, and if there is no
case label, but all possible strings are covered, it can pick a random case
label as the default.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40206

Reply via email to