https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82453
--- Comment #4 from fulvio ciriaco <oivulf at gmail dot com> --- Thanks for answering. This was the use case I imagined for f2003, when it allows allocatable arrays. Are they otherwise any distinguishable from ordinary arrays in this context? Too sad. Thank you again Fulvio On 10/06/2017 03:51 PM, tkoenig at gcc dot gnu.org wrote: > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82453 > > Thomas Koenig <tkoenig at gcc dot gnu.org> changed: > > What |Removed |Added > ---------------------------------------------------------------------------- > Status|UNCONFIRMED |RESOLVED > CC| |tkoenig at gcc dot gnu.org > Resolution|--- |INVALID > > --- Comment #3 from Thomas Koenig <tkoenig at gcc dot gnu.org> --- > You are passing an unallocated array to an input > function, probably in the expectation that it will > be allocated by the READ. > > This is a feature which Fortran doesn't have. You have > to allocate the array manually, using an ALLOCATE statement, > or use a non-allocatable array as in your second example. > > There is no "allocate on read" comparable to "allocate > on assignment". > > The segfault is the usual result of trying to do something > with an unallocated array. > > (And yes, this is something that I have also wanted, from a > user perspective. From an implementor's perspective, maybe less :-) >