Jump to content

C++ Language/Templates/Metaprogramming/NumericTemplateParameters

From Wikibooks, open books for an open world

A template-parameter usually serves as a placeholder for a type. But, a template-parameter could be numeric. This gives templates a capability of performing compile-time calculations by "template-metaprograms".

Additional information about numeric template-parameters (includes interactive examples)