diff --git a/VirtualRobot/Nodes/RobotNodeHemisphere.cpp b/VirtualRobot/Nodes/RobotNodeHemisphere.cpp
index 2718662c6e4bf32cdeae793b12aa89c2066dfc22..ef49ea6008ef9715494400000ab9b31f5b87beeb 100644
--- a/VirtualRobot/Nodes/RobotNodeHemisphere.cpp
+++ b/VirtualRobot/Nodes/RobotNodeHemisphere.cpp
@@ -128,7 +128,7 @@ namespace VirtualRobot
             SceneObjectPtr parent,
             const std::vector<SceneObjectPtr>& children)
     {
-        VR_ASSERT_MESSAGE(first xor second, first.has_value() << " / " << second.has_value());
+        VR_ASSERT_MESSAGE(first.has_value() xor second.has_value(), std::stringstream() << first.has_value() << " / " << second.has_value());
 
         // The second node needs to store a reference to the first node.
         if (second)
@@ -177,7 +177,7 @@ namespace VirtualRobot
     void RobotNodeHemisphere::updateTransformationMatrices(
             const Eigen::Matrix4f& parentPose)
     {
-        VR_ASSERT_MESSAGE(first xor second, first.has_value() << " / " second.has_value());
+        VR_ASSERT_MESSAGE(first.has_value() xor second.has_value(), std::stringstream() << first.has_value() << " / " << second.has_value());
 
         if (first)
         {
@@ -219,7 +219,7 @@ namespace VirtualRobot
     void RobotNodeHemisphere::print(bool printChildren, bool printDecoration) const
     {
         ReadLockPtr lock = getRobot()->getReadLock();
-        VR_ASSERT_MESSAGE(first xor second, first.has_value() << " / " second.has_value());
+        VR_ASSERT_MESSAGE(first.has_value() xor second.has_value(), std::stringstream() << first.has_value() << " / " << second.has_value());
 
         if (printDecoration)
         {
@@ -307,7 +307,7 @@ namespace VirtualRobot
 
     std::string RobotNodeHemisphere::_toXML(const std::string& /*modelPath*/)
     {
-        VR_ASSERT_MESSAGE(first xor second, first.has_value() << " / " second.has_value());
+        VR_ASSERT_MESSAGE(first.has_value() xor second.has_value(), std::stringstream() << first.has_value() << " / " << second.has_value());
 
         if (first)
         {
diff --git a/VirtualRobot/Nodes/RobotNodeHemisphere.h b/VirtualRobot/Nodes/RobotNodeHemisphere.h
index 26ee4b7d72504f5415d12f840deb532dbae6ffdc..7a548e60075203990e86d891f6bad4e511e242e8 100644
--- a/VirtualRobot/Nodes/RobotNodeHemisphere.h
+++ b/VirtualRobot/Nodes/RobotNodeHemisphere.h
@@ -30,6 +30,7 @@
 
 #include <string>
 #include <vector>
+#include <optional>
 
 
 namespace VirtualRobot