From 8256e26978ba5142bd7eea577b7f56b42bb904ab Mon Sep 17 00:00:00 2001 From: Korobeinikov Evgeny Date: Wed, 12 Feb 2025 17:46:04 +0300 Subject: [PATCH] Using interop-fatal instead of throw in tree.h --- arkoala/framework/native/src/tree.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/arkoala/framework/native/src/tree.h b/arkoala/framework/native/src/tree.h index 8a180b66a..42160f331 100644 --- a/arkoala/framework/native/src/tree.h +++ b/arkoala/framework/native/src/tree.h @@ -22,6 +22,8 @@ #include #include +#include "interop-types.h" + using std::string; const int UndefinedDimensionUnit = -1; @@ -160,7 +162,7 @@ struct TreeNode { auto it = std::find(_children.begin(), _children.end(), sibling); if (it == _children.end()) { fprintf(stderr, "insertChildAfter: sibling node %p not found among children\n", sibling); - throw "Error"; + INTEROP_FATAL("Error"); } auto next = std::next(it); _children.insert(next, node); @@ -183,7 +185,7 @@ struct TreeNode { auto it = std::find(_children.begin(), _children.end(), sibling); if (it == _children.end()) { fprintf(stderr, "insertChildBefore: sibling node %p not found among children\n", sibling); - throw "Error"; + INTEROP_FATAL("Error"); } _children.insert(it, node); node->setParent(this); -- Gitee