summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorKjell Ahlstedt <kjellahlstedt@gmail.com>2020-07-11 12:03:16 +0200
committerKjell Ahlstedt <kjellahlstedt@gmail.com>2020-07-11 12:03:16 +0200
commit909b0f150aa52c83e56e379e9ee091c97995784b (patch)
tree47efe2c6cae81cf703e59d3375964604ca3d3355 /tools
parent4976714d10dd6cd32b04f358a390fdc38f8bcd2f (diff)
downloadglibmm-909b0f150aa52c83e56e379e9ee091c97995784b.tar.gz
gmmproc: _CLASS_BOXEDTYPE, _CLASS_OPAQUE_COPYABLE: Fix move assignment
Add a std::move() to avoid copying. Fixes #76
Diffstat (limited to 'tools')
-rw-r--r--tools/m4/class_boxedtype.m42
-rw-r--r--tools/m4/class_opaque_copyable.m42
2 files changed, 2 insertions, 2 deletions
diff --git a/tools/m4/class_boxedtype.m4 b/tools/m4/class_boxedtype.m4
index a31f1f0a..4c2092b9 100644
--- a/tools/m4/class_boxedtype.m4
+++ b/tools/m4/class_boxedtype.m4
@@ -146,7 +146,7 @@ __CPPNAME__::__CPPNAME__`'(__CPPNAME__&& other) noexcept
__CPPNAME__& __CPPNAME__::operator=(__CPPNAME__`'&& other) noexcept
{
- __CPPNAME__ temp (other);
+ __CPPNAME__ temp (std::move(other));
swap(temp);
return *this;
}
diff --git a/tools/m4/class_opaque_copyable.m4 b/tools/m4/class_opaque_copyable.m4
index c725a42a..323f10d5 100644
--- a/tools/m4/class_opaque_copyable.m4
+++ b/tools/m4/class_opaque_copyable.m4
@@ -155,7 +155,7 @@ __CPPNAME__::__CPPNAME__`'(__CPPNAME__&& other) noexcept
__CPPNAME__& __CPPNAME__::operator=(__CPPNAME__`'&& other) noexcept
{
- __CPPNAME__ temp (other);
+ __CPPNAME__ temp (std::move(other));
swap(temp);
return *this;
}