This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/80009] Printing/writing a structure with a real edit descriptor.


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

Jerry DeLisle <jvdelisle at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|WAITING                     |NEW

--- Comment #9 from Jerry DeLisle <jvdelisle at gcc dot gnu.org> ---
9.6.4.8.4 Resolving defined input/output procedure references

In paragraph 2, there are two conditions that BOTH must be satisfied for a user
defined procedure to be used:

Condition 1:

 a) list directed, namelist, or unformatted
     or
 b) formatted and the edit descriptor corresponds to the effective item and is
DT

Condition 2:

 a) effective item as a suitable type bound procedure
     or
 b) a generic interface is accessible

With the specific case given in this PR:

write (unit=*, fmt="(f4.1)") B_type(20.0)

The "effective item" is key here. My interpretation is that it is the kind=real
number 20.0 and that th B_type(20.0) needs to be further resolved in io.c

Confirming this bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]