On Wed, Jan 10, 2018 at 1:21 PM, Jakub Jelinek <ja...@redhat.com> wrote:
> On Wed, Jan 10, 2018 at 01:18:46PM +0200, Janne Blomqvist wrote:
>
> Thanks for fixing this PR.
>
>> @@ -1562,7 +1562,8 @@ gfc_trans_array_ctor_element (stmtblock_t * pblock, 
>> tree desc,
>>         if (first_len)
>>           {
>>             gfc_add_modify (&se->pre, first_len_val,
>> -                                se->string_length);
>> +                           fold_convert (TREE_TYPE (first_len_val),
>> +                                                    se->string_length));
>
> Wrong formatting, se->string_length should have been below TREE_TYPE.
>
>>             first_len = false;
>>           }
>>         else
>> @@ -1571,7 +1572,9 @@ gfc_trans_array_ctor_element (stmtblock_t * pblock, 
>> tree desc,
>>                length.  */
>>             tree cond = fold_build2_loc (input_location, NE_EXPR,
>>                                          logical_type_node, first_len_val,
>> -                                        se->string_length);
>> +                                        fold_convert (TREE_TYPE
>> +                                                      (first_len_val),
>> +                                                      se->string_length));
>
> And here, it might have been better to add a temporary for
> TREE_TYPE (first_len_val)
> to avoid the excessive line wrapping.

Hmm, yes. Fixed in r256426. I also managed to get the PR number wrong
(it's 83740, not 84740, fixed the ChangeLog entry too).


-- 
Janne Blomqvist

Reply via email to