Nim Programming Cookbook // Metaprogramming

Metaprogramming is the writing of computer programs with the ability to treat programs as their data. It means that a program could be designed to read, generate, analyse and/or transform other programs, and even modify itself while running. – Wikipedia

Nim’s two constructs – templates, and macros offer powerful metaprogramming capabilities.

Further Reading