diff options
author | hop311 <hop3114@gmail.com> | 2023-11-14 22:47:35 +0100 |
---|---|---|
committer | hop311 <hop3114@gmail.com> | 2023-11-16 20:38:34 +0100 |
commit | 886b8b8f396438fc2b7da7d2508f2064d14150a8 (patch) | |
tree | eeed419a7d97ecb58adf63a17eb9184db3e5ed7a /src/openvic-simulation/dataloader/NodeTools.cpp | |
parent | 8271b1519e095ee3e7245cde2f0b54561c3ec619 (diff) |
Misc changes
Diffstat (limited to 'src/openvic-simulation/dataloader/NodeTools.cpp')
-rw-r--r-- | src/openvic-simulation/dataloader/NodeTools.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/openvic-simulation/dataloader/NodeTools.cpp b/src/openvic-simulation/dataloader/NodeTools.cpp index c412f33..19f5dd7 100644 --- a/src/openvic-simulation/dataloader/NodeTools.cpp +++ b/src/openvic-simulation/dataloader/NodeTools.cpp @@ -206,7 +206,11 @@ node_callback_t NodeTools::expect_fvec2(callback_t<fvec2_t> callback) { node_callback_t NodeTools::expect_assign(key_value_callback_t callback) { return _expect_type<ast::AssignNode>([callback](ast::AssignNode const& assign_node) -> bool { - return callback(assign_node._name, assign_node._initializer.get()); + const bool ret = callback(assign_node._name, assign_node._initializer.get()); + if (!ret) { + Logger::error("Callback failed for assign node with key: ", assign_node._name); + } + return ret; }); } |