Commit 34a53d78 authored by T.J. Corona's avatar T.J. Corona Committed by Kitware Robot

Merge topic 'msvc2019-vous-renard-ruse'

a04e3a28 Explicitly delete copy ctor for move-only classes
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Merge-request: !2259
parents 01865660 a04e3a28
......@@ -62,6 +62,18 @@ public:
return smtk::shared_ptr<ItemDefinitionManager>(new ItemDefinitionManager(resourceManager));
}
// Our map of observer keys is move-only, so this class needs to be at least
// move-only as well. MSVC 2019 does not correctly intuit this fact when
// generating default constructors and assignment operators, so we explicitly
// remove them. We remove the move constructor and move assignment operator
// for good measure, since they are not needed anyway.
ItemDefinitionManager() = delete;
ItemDefinitionManager(const ItemDefinitionManager&) = delete;
ItemDefinitionManager(ItemDefinitionManager&&) = delete;
ItemDefinitionManager& operator=(const ItemDefinitionManager&) = delete;
ItemDefinitionManager& operator=(ItemDefinitionManager&&) = delete;
virtual ~ItemDefinitionManager();
/// Register <CustomItemDefinitionType> to all attribute resources.
......
......@@ -60,6 +60,18 @@ public:
return smtk::shared_ptr<Manager>(new Manager(resourceManager));
}
// Our map of observer keys is move-only, so this class needs to be at least
// move-only as well. MSVC 2019 does not correctly intuit this fact when
// generating default constructors and assignment operators, so we explicitly
// remove them. We remove the move constructor and move assignment operator
// for good measure, since they are not needed anyway.
Manager() = delete;
Manager(const Manager&) = delete;
Manager(Manager&&) = delete;
Manager& operator=(const Manager&) = delete;
Manager& operator=(Manager&&) = delete;
virtual ~Manager();
/// Register <QueryType> to all resources for which the input functor <fn>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment