[commands] CommandCompositionError: Include stacktrace of original composition (#5984)

This commit is contained in:
Starlight220
2023-12-09 19:45:02 +02:00
committed by GitHub
parent 54a55b8b53
commit a770110438
6 changed files with 57 additions and 23 deletions

View File

@@ -7,6 +7,7 @@
#include <concepts>
#include <functional>
#include <memory>
#include <optional>
#include <string>
#include <utility>
#include <vector>
@@ -35,7 +36,7 @@ class CommandPtr final {
: CommandPtr(
std::make_unique<std::decay_t<T>>(std::forward<T>(command))) {}
CommandPtr(CommandPtr&&) = default;
CommandPtr(CommandPtr&&);
CommandPtr& operator=(CommandPtr&&) = default;
explicit CommandPtr(std::nullptr_t) = delete;
@@ -327,6 +328,7 @@ class CommandPtr final {
private:
std::unique_ptr<Command> m_ptr;
std::string m_moveOutSite{""};
void AssertValid() const;
};