From 03a2f77dfe0deb78f8640e8fc88c15352ab670a7 Mon Sep 17 00:00:00 2001
From: joanvallve <jvallve@iri.upc.edu>
Date: Sun, 14 Jun 2020 17:05:36 +0200
Subject: [PATCH] hotfix: added assertion in error case. Commented unused
 typedef

---
 include/core/state_block/has_state_blocks.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/include/core/state_block/has_state_blocks.h b/include/core/state_block/has_state_blocks.h
index b1af55f7b..a2d6e1e76 100644
--- a/include/core/state_block/has_state_blocks.h
+++ b/include/core/state_block/has_state_blocks.h
@@ -17,7 +17,7 @@ namespace wolf
 {
 
 /// State of nodes containing several state blocks
-typedef std::unordered_map<std::string, Eigen::VectorXd> State;
+//typedef std::unordered_map<std::string, Eigen::VectorXd> State;
 //typedef std::string StateStructure;
 
 
@@ -220,6 +220,7 @@ inline void HasStateBlocks::setState(const VectorComposite& _state, const bool _
         const auto& sb = getStateBlock(key);
         if (!sb)
             WOLF_ERROR("Stateblock key ", key, " not in the structure");
+        assert (sb && "Stateblock key not in the structure");
 
         sb->setState(vec, _notify);
     }
-- 
GitLab