I would also suggest that the example use IOMSG= and print the returned message now that that is widely available. It will (hopefully) produce a clear message that an attempt was made to read a non-existent record. Another thing not mentioned is youcan have your
code check the size of a unit:that I go and look. My own build scripts and fpm(1) specify it so I had forgotten.
The number of bits in a file storage unit is given by the constant FILE_STORAGE_SIZE (16.10.2.11) defined
in the intrinsic module ISO_FORTRAN_ENV. It is recommended that the file storage unit be an 8-bit octet
where this choice is practical.
so you can, in the case of ifort(1), warn if it is compiled with a FILE_STORAGE_SIZE of 32 instead of 8. I thought ifort(1) no longer used longwords as the unit for RECL by default, too. I guess that is not the case unless formatted I/O is used, now
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 131 |
Nodes: | 8 (1 / 7) |
Uptime: | 05:38:21 |
Calls: | 2,691 |
Calls today: | 1 |
Files: | 9,234 |
Messages: | 2,256,733 |