Clicky

Fortran Wiki
Preprocessors (Rev #12, changes)

Skip the Navigation Links | Home Page | All Pages | Recently Revised | Authors | Feeds | Export |

Showing changes from revision #11 to #12: (追記) Added (追記ここまで) | (削除) Removed (削除ここまで) | (削除) Chan (削除ここまで)(追記) ged (追記ここまで)

Introduction

Preprocessors serve multiple purposes, including conditional-compilation, macros for code simplification, and inclusion of additional source files. Fortran originally had no proper preprocessor, so it became common to use cpp. However, cpp is not fully compatible with Fortran source, so Sun developed fpp, a Fortran-compatible version of cpp. Around the same time, Fortran 95 defined an optional conditional-compilation preprocessor, called coco.

Today, fpp is essentially the de facto standard Fortran preprocessor, although some compilers still invoke cpp in traditional mode. Compilers that support cpp or fpp usually support Predefined preprocessor macros that aid compiler-specific code requirements. Although coco is an official standard, it is generally not supported directly by Fortran compilers, and therefore loses the benefit of compiler-defined preprocessor tokens.

Fortran-Specific Preprocessors

  • fpp
  • f90ppr
  • coco
  • Forpedo
  • Fpx3
  • PyF95++
  • PreForM.py
  • Fypp
  • ufpp
  • (追記) (追記ここまで)(追記)
  • pref - basic pre-processor primarily designed for use with Fortran. It does not support macros but is quite capable of supporting conditional compilation for general platform-specific issues.
  • (追記ここまで)

Other Preprocessors

See Also

Revision from June 9, 2021 07:36:40 by Beliavsky?
Forward in time (to current) | Back in time (11 more) | See current | Hide changes | History | Rollback | View: Source | Linked from: HomePage, 2009, Generic programming, Tools, Forpedo, Fpx3, 2010, f90ppr, coco, fpp, BlockIt, F2008 Smart Macros, PreForM.py, Fypp

AltStyle によって変換されたページ (->オリジナル) /