diff --git a/src/Targets/TargetDescription/Module.hpp b/src/Targets/TargetDescription/Module.hpp index 722d8ffc..e98298dd 100644 --- a/src/Targets/TargetDescription/Module.hpp +++ b/src/Targets/TargetDescription/Module.hpp @@ -44,7 +44,7 @@ namespace Targets::TargetDescription : std::nullopt; } - std::optional> getRegisterGroup(std::string_view keyStr) const { + const RegisterGroup& getRegisterGroup(std::string_view keyStr) const { const auto group = this->tryGetRegisterGroup(keyStr); if (!group.has_value()) { throw Exceptions::InvalidTargetDescriptionDataException(