http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46678
--- Comment #5 from Tobias Burnus <burnus at gcc dot gnu.org> 2010-11-27
09:54:36 UTC ---
(In reply to comment #4)
> While it makes a bit more sense, I admittedly still fail to understand why
> int .string
> {
> .string = 4
> }
> // use .string
> fails
'cause I cannot read. One has:
sub (integer(kind=4)[0:D.1579] * restrict a, integer(kind=4) & restrict n)
{
character(kind=1) string[1:.string];
integer(kind=4) .string;
{
.string = MAX_EXPR <...>
character(kind=1) string[1:.string];
// working
}
// failing
}
which makes sense but indicates that we somehow mishandle variable-length
strings; in particular, it indicates that it won't work that way with
allocatable string lengths.