Skip to content

Functional template metaprogramming in Trivium (Andreas Maniotis)

Photo of DavidFarago
Hosted By
DavidFarago
Functional template metaprogramming in Trivium (Andreas Maniotis)

Details

Motivation

Template metaprogramming (TMP) code tends to be unfriendly to humans. The code is generally neither easy to read nor easy to write, because the metaprogramming capacities of C++ arose by coincidence and not by design.

We claim and prove that metaprogrammed code in C++ can be as simple, clear, reusable, modular and configurable as code that is written in a functional language like Lisp or Haskell.

Contents

We shall discuss Trivium, a library that aspires to meet these objectives via the technique of *symbolic metaprogramming*. The library consists of three components:
1. Trivium Lisp, a homoiconic domain-specific symbolic language for metaprogramming;
2. A symbolic representation of the C++-type system;
3. A C++-representation of symbolic expressions.

Through these three copmonents we completely separate the peculiarities of the C++-type system from the representation of metaprograms.

Source Code: https://github.com/andreas-maniotis/trivium

Speaker

Andreas Maniotis is a freelancing C++ developer. He holds a PhD in computer science and a master's degree in mathematics. He has mainly worked in the hardware industry, in robotics, and in CAD/CAE. He has done research work in the fields of reversible computing, functional programming, performance engineering and algorithmics.

Event

This meetup will be in person in Karlsruhe (details announced later).

The talk will be in English unless all participants speak German.

Photo of C++ User Group Karlsruhe group
C++ User Group Karlsruhe
See more events
Needs a location
FREE