Arpit Saxena

Home

❯

C++ Function definitions in header (a)

C++ Function definitions in header (a)

Mar 21, 2025 • 1 min read • Last modified Apr 24, 2025

Continued from C++ Function definitions in header

Note that template functions need to be defined in headers so that they can be instantiated as needed in the code. Linker will then eliminate duplicate instantiations. Cf armlink - Elimination of common groups or sections.

Similar to how only the linker can eliminate non-static functions, see C++ static function (a)


Backlinks

  • C++ template code size (a)

Graph View

  • Created by Arpit Saxena © 2025
  • GitHub
  • Blog
  • 🦋 BlueSky