diff options
| author | Felix Morgner <felix.morgner@gmail.com> | 2020-01-02 12:48:57 +0100 |
|---|---|---|
| committer | Felix Morgner <felix.morgner@gmail.com> | 2020-01-02 12:49:21 +0100 |
| commit | 9c81cffc32a5e88ac9f81fe3d08c2a670efa79d2 (patch) | |
| tree | f5dd35cf4f3b6b6589c2808d47979bad0de11775 /doc | |
| parent | c44d9c610e7f5b03eda13769e889eea72b056d6b (diff) | |
| download | newtype-9c81cffc32a5e88ac9f81fe3d08c2a670efa79d2.tar.xz newtype-9c81cffc32a5e88ac9f81fe3d08c2a670efa79d2.zip | |
new_type: implement multiplication
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/src/index.rst | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/doc/src/index.rst b/doc/src/index.rst index 7f75ec4..18e81f7 100644 --- a/doc/src/index.rst +++ b/doc/src/index.rst @@ -293,6 +293,15 @@ Arithmetic Operators **enablement:** This operator shall be available iff. a) :cpp:type:`new_type<BaseType, TagType, DerivationClause>::base_type` is subtractable using the operator :literal:`-` and b) :cpp:type:`DerivationClause` includes :cpp:var:`Arithmetic`. +.. cpp:function:: template<typename BaseType, \ + typename TagType, \ + auto DerivationClause> \ + constexpr new_type<BaseType, TagType, DerivationClause> operator*(new_type<BaseType, TagType, DerivationClause> const & lhs, new_type<BaseType, TagType, DerivationClause> const & rhs) + + **noexcept specification:** This input operator shall be noexcept iff. :cpp:type:`new_type<BaseType, TagType, DerivationClause>::base_type` is nothrow multipliable as well as nothrow copy-constructible. + + **enablement:** This operator shall be available iff. a) :cpp:type:`new_type<BaseType, TagType, DerivationClause>::base_type` is multipliable using the operator :literal:`*` and b) :cpp:type:`DerivationClause` includes :cpp:var:`Arithmetic`. + Header :literal:`<newtype/derivable.hpp>` ========================================= |
