diff options
| author | Billy Robert O'Neal III <bion@microsoft.com> | 2018-01-05 01:32:00 +0000 |
|---|---|---|
| committer | Billy Robert O'Neal III <bion@microsoft.com> | 2018-01-05 01:32:00 +0000 |
| commit | 3770e403eec750087cd564f2701e9474d955fa9a (patch) | |
| tree | 7c8d62a5249a5248cae901675d697fbae377a419 /libcxx/test/support | |
| parent | 4958692ad9d0834b6ba94dbeaffc88e5159debeb (diff) | |
| download | bcm5719-llvm-3770e403eec750087cd564f2701e9474d955fa9a.tar.gz bcm5719-llvm-3770e403eec750087cd564f2701e9474d955fa9a.zip | |
Move + and * operators of MoveOnly into MoveOnly.h.
llvm-svn: 321852
Diffstat (limited to 'libcxx/test/support')
| -rw-r--r-- | libcxx/test/support/MoveOnly.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libcxx/test/support/MoveOnly.h b/libcxx/test/support/MoveOnly.h index 4afa8aef710..2eba8e7428a 100644 --- a/libcxx/test/support/MoveOnly.h +++ b/libcxx/test/support/MoveOnly.h @@ -19,7 +19,6 @@ class MoveOnly { - friend class MoveOnly2; MoveOnly(const MoveOnly&); MoveOnly& operator=(const MoveOnly&); @@ -35,6 +34,8 @@ public: bool operator==(const MoveOnly& x) const {return data_ == x.data_;} bool operator< (const MoveOnly& x) const {return data_ < x.data_;} + MoveOnly operator+(const MoveOnly& x) const { return MoveOnly{data_ + x.data_}; } + MoveOnly operator*(const MoveOnly& x) const { return MoveOnly{data_ * x.data_}; } }; namespace std { |

