Negation of integral_constants
Summary
Unfortunately, the user-defined literal cannot parse the negation sign. Thus negative integral constants could not be generated by, e.g., -123_sc
. The solution is to only parse the unsigned digits and add a negation operator for integral_constants instead. In order to use the user-defined literals, the namespace Dune::Indices::Literals
must be included. This allows to make also the operator-(integral_constant)
visible.