mp_units::operator-¶
Subtraction operator
Synopsis¶
Declared in <mp-units/framework/quantity_point.h>
template<auto R1, auto PO1, typename Rep1, auto R2, typename Rep2>
requires ReferenceOf<MP_UNITS_NTTP_HACK(decltype(R2)), get_quantity_spec(PO1)>
[[nodiscard]] constexpr QuantityPoint auto operator-(quantity_point<R1, PO1, Rep1> const& qp,
quantity<R2, Rep2> const& q)
requires requires { qp.quantity_ref_from(PO1) - q; };
Note
This function is a hidden friend of quantity_point, declared inside an implementation-defined base class: it can be found only through argument-dependent lookup.
Return Value¶
Note
The return value should not be discarded.
Parameters¶
| Name | Description |
|---|---|
| qp | The left operand |
| q | The right operand |