diff options
author | Georgios Pinitas <georgios.pinitas@arm.com> | 2019-03-25 14:06:14 +0000 |
---|---|---|
committer | Georgios Pinitas <georgios.pinitas@arm.com> | 2019-03-27 15:49:14 +0000 |
commit | f52cd78acdedc9b4e2342daf2ca65578a6da28e1 (patch) | |
tree | 85850cc536a4360668a8a6185f691065fdb66c00 /arm_compute/core/Window.inl | |
parent | 8cf8c1123440c2002ee108d1949529bf21eac944 (diff) | |
download | ComputeLibrary-f52cd78acdedc9b4e2342daf2ca65578a6da28e1.tar.gz |
COMPMID-1995: Minor code fixes.
-Remove FIXMEs and link to tickets.
-Pass large object by const reference.
-Implement copy assignment operator for Window.
Change-Id: I975223ac42ec424f153569a8c963f29e6b86ad29
Signed-off-by: Georgios Pinitas <georgios.pinitas@arm.com>
Reviewed-on: https://review.mlplatform.org/c/899
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Michele Di Giorgio <michele.digiorgio@arm.com>
Diffstat (limited to 'arm_compute/core/Window.inl')
-rw-r--r-- | arm_compute/core/Window.inl | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/arm_compute/core/Window.inl b/arm_compute/core/Window.inl index c6fc8848aa..eeef3df7b0 100644 --- a/arm_compute/core/Window.inl +++ b/arm_compute/core/Window.inl @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016-2018 ARM Limited. + * Copyright (c) 2016-2019 ARM Limited. * * SPDX-License-Identifier: MIT * @@ -32,6 +32,13 @@ inline Window::Window(const Window &src) } } +inline Window &Window::operator=(const arm_compute::Window &rhs) +{ + Window tmp(rhs); + swap(*this, tmp); + return *this; +} + inline constexpr const Window::Dimension &Window::operator[](size_t dimension) const { // Precondition: dimension < Coordinates::num_max_dimensions @@ -267,4 +274,9 @@ inline size_t Window::num_iterations_total() const } return total; } + +inline void swap(Window &lhs, Window &rhs) +{ + lhs._dims.swap(rhs._dims); } +} // namespace arm_compute |