File I/O Unformatted Stream Vs Binary

File I/O Unformatted Stream Vs Binary

I am not familiar with opening a file with form set to Unformated with Acess set to Stream. Is this identical to opening a file with form set to Binary. If not, since they are record free files would something written with both forms produce the same binary? What would be the pros/cons between them if there is a difference. Right now I am able to postprocess form set to binary with python, but I assume it should work with stream because its equivalent to a C-binary?


Thanks as always.

publicaciones de 5 / 0 nuevos
Último envío
Para obtener más información sobre las optimizaciones del compilador, consulte el aviso sobre la optimización.

Yes, it's the same (for unformatted). 'BINARY' is an extension, ACCESS='STREAM' is standard.

Steve - Intel Developer Support



would produce the same file as:


Assuming all the WRITEs are the same, yes.

Steve - Intel Developer Support

I've been using FORM='BINARY' for years now with scratch files and a few others. I understand that the introduction of STREAM was at least partly to standardize the way different compilers implemented BINARY, for compatibility reasons. There was one little twist I found; I was using ACCESS="APPEND' in one case,, which is another extension and incompatible with STREAM. Fortunately, the POSITION keyword in OPEN came to the rescue....

Deje un comentario

Por favor inicie sesión para agregar un comentario. ¿No es socio? Únase ya