mp_units::named_constant

Named constant definition

Synopsis

Declared in <mp-units/framework/unit.h>

template<
    symbol_text Symbol,
    Unit auto U>
requires (!Symbol.empty())
struct named_constant
    : ::_base_type_

Description

It is very similar to named_unit but:

  • allows negative exponents in the unit definition (TODO )

  • does not allow the constant to be associated with a quantity_spec

  • does not allow the constant to be prefixed

Base Classes

NameDescription
::_base_type_

Type Aliases

Name
_base_type_

Static Data Members

NameDescription
_symbol_ Unique constant identifier

Derived Classes

NameDescription
pi

Template Parameters

NameDescription
Symbola short text representation of the constant
Unita unit that we use to define a constant