nkr
A C++20 library with a custom meta-programming language.
nkr::positive Namespace Reference

Positive types are used to represent numbers that are only ever positive and cannot be negated. More...

Detailed Description

Positive types are used to represent numbers that are only ever positive and cannot be negated.

The name "positive" was chosen for two reasons:

  1. The word "positive" is extremely clear and straightforward. It can not be mistaken that this number is only ever going to be positive.
  2. unsigned is a C++ reserved word and cannot be used as a namespace name.
Note
Compare to nkr::negatable.