https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107721

--- Comment #8 from Jerry DeLisle <jvdelisle at gcc dot gnu.org> ---
FWIW : I think the typespec is being lost because the initial call into
gfc_match_array_constructor which finds and matches the typespec sets a local
variable seen_ts which is used later in that function to do the type conversion
steps. However, before that happens a call from gfc_match_array_constructor
into match_array_cons_element then results in a subsequent call to
gfc_match_array_constructor where there is no typespec left to match. The local
seen_ts is set to false so the conversion code does not get called.

Killing parens does not fix any of this.  I think what is needed is the seen_ts
needs to be passed down the call chain to preserve it during the
match_array_cons_element process. My intuition tells me it would be better if
portions of this code are refactored little to avoid some of these recursive
calls.

Reply via email to