aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMarco Poletti <poletti.marco@gmail.com>2018-07-24 19:31:32 +0100
committerMarco Poletti <poletti.marco@gmail.com>2018-07-24 19:31:32 +0100
commited5ec821287f0b4cf0fe784f0b98e055a909bf1d (patch)
tree34a0632446d1b72530586d729abde64db475005c /include
parent74305893f69ba901b68d88c67c0d085d933233d9 (diff)
downloadgoogle-fruit-ed5ec821287f0b4cf0fe784f0b98e055a909bf1d.tar.gz
Make PartialComponent non-movable. This catches at compile-time some cases where PartialComponent is used for non-temporary values. See issue 67.
Diffstat (limited to 'include')
-rw-r--r--include/fruit/component.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/include/fruit/component.h b/include/fruit/component.h
index 5e2a4ec..5fbfdc6 100644
--- a/include/fruit/component.h
+++ b/include/fruit/component.h
@@ -143,8 +143,6 @@ PartialComponent<> createComponent();
template <typename... Bindings>
class PartialComponent {
public:
- PartialComponent(PartialComponent&&) = default;
-
PartialComponent& operator=(PartialComponent&&) = delete;
PartialComponent& operator=(const PartialComponent&) = delete;
@@ -1035,6 +1033,7 @@ private:
// Do not use. Only use PartialComponent for temporaries, and then convert it to a Component.
PartialComponent(const PartialComponent&) = delete;
+ PartialComponent(PartialComponent&&) = delete;
PartialComponent(fruit::impl::PartialComponentStorage<Bindings...> storage);