PSCF v1.4.0
C++ Templates

Coding Standards (Prev)         Periodic Systems: CPU vs. GPU (Next)

The PSCF source code makes extensive use of C++ class templates to avoid duplication of code for closely analogous classes. To reduce compilation times, PSCF also relies heavily on explicit instantiation of templates in cases for which there are only a few possible valid values of the template parameters. The subpages linked below explain some of the ways in which templates are used in PSCF, and explain conventions used for templates that are designed to be explicitly instantiated.

  1. Use Cases
  2. Concepts and Definitions
  3. Implicit vs. Explicit Templates


Coding Standards (Prev)         Developer Information (Up)         Periodic Systems: CPU vs. GPU (Next)