Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

More namelist questions

htigner
Beginner
813 Views
Hello all,
A few questions:
1. Is there any way to direct a namelist write to format the output in a line per variable output? Our programs use namelists extensively, many of the namelists are hand edited frequently for various reasons, and the current output of a namelist write is difficult at best to read through or diff with existing namelists to verify data.

2. Is there any way to default a namelist write to automatically use DELIM='APOSTROPHE', without explicitly setting this in each namelist open? I can see the benefit of being able to change this variable per namelist requirements, but is there any reason why there is not a default value of apostrophe?

3. Is there any way to force the namelist write to use the extensions $NAMELIST and $END instead of the &NAMELIST and '/'?

Thanks
Harley Tigner
0 Kudos
4 Replies
Steven_L_Intel1
Employee
813 Views
1. No.

2. No, and because the standard says so. It's the file open where you specify DELIM=. It isn't on a per-NAMELIST or per-variable basis.

3. Not in the current version, but it may appear in the future version that uses a run-time library derived from Compaq Fortran's, as it has this as an option. Keep in mind that the $ syntax is non-standard (though it was a de-facto standard prior to F90.)

Steve
0 Kudos
htigner
Beginner
813 Views
Thanks!
0 Kudos
Steven_L_Intel1
Employee
813 Views
FWIW, I noticed that Compaq Fortran formats NAMELIST output the way you want it, with each variable on a new line, so that behavior will come to Intel Fortran too.

Steve
0 Kudos
htigner
Beginner
813 Views
Thanks again. Learning as I go...
Harley
0 Kudos
Reply