最終更新日時:
が更新

履歴 編集

function template
<utility>

std::constant_wrapper::operator>>=(C++26)

template <constexpr-param T, constexpr-param R>
constexpr auto operator>>=(this T self, R y) noexcept;

概要

constant_wrapperが保持する値に対して、>>=による右シフトの複合代入をおこなう。

戻り値

constant_wrapper<(T::value >>= R::value)>{}を返す。

備考

  • constant_wrapperが保持するvalueconstであるため、保持する値そのものを変更する式(++valuevalue op= xvalue = x)は不適格となる。
  • したがって、このオーバーロードは説明用基底クラスcw-operatorsのインターフェースとして宣言されているものの、constant_wrapperに対してはオーバーロード解決に参加せず、使用できない。

バージョン

言語

  • C++26

処理系

関連項目

参照