jukkae / rascal

A roguelike.
Other
1 stars 0 forks source link

Templated dice functions #211

Closed jukkae closed 6 years ago

jukkae commented 6 years ago

Instead of hardcoded d6() etc, something like d<unsigned int N>(). Call site is less beautiful, but e.g. JSON parsing becomes much more simple.

jukkae commented 6 years ago

Can't use in JSON parsing, template parameter must be known at compile time.