reallocationCharacterArray fails

Skip to first unread message

Nov 15, 2021, 1:17:43 PM11/15/21


Nov 15, 2021, 6:23:58 PM11/15/21
On Monday, November 15, 2021 at 10:17:43 AM UTC-8, wrote:
> any idea regarding this

Seems to me slightly complicated, especially related to the character
variable lengths. What does it do with CHARACTER(1) instead?

As well as I know, the array constructors get the length from the first
element, which in this case is a variable. I think you can put a
CHARACTER(1):: at the beginning of the array constructor to tell
it the length. In some cases, that is required. You might also
try it with other lengths.

Note that a character array has all strings of the same length.

Nov 16, 2021, 1:44:33 AM11/16/21
ב-יום שלישי, 16 בנובמבר 2021 בשעה 01:23:58 UTC+2, gah4 כתב/ה:
Thanks for the reply.

Writing explicitly character(len=1) - makes the program work also with gfortran.

but (!) give attention to the fact that when the appended array was size 3 - the program succeeded.
So given that - I do not see how the `len=:` makes it a problem - since appending 3 works.
The problem arises only whn appending 4 and above.

Anyway - this has been confirmed to be an internal compiler error, since then...
Reply all
Reply to author
0 new messages