fix compile issues

main
Brett 2025-05-13 20:49:28 -04:00
parent 914ad4fc49
commit 2f62efbf12
3 changed files with 6 additions and 6 deletions

View File

@ -27,7 +27,7 @@ macro(compile_options target_name)
sanitizers(${target_name})
endmacro()
project(blt-gp VERSION 0.5.26)
project(blt-gp VERSION 0.5.27)
include(CTest)

@ -1 +1 @@
Subproject commit f0fe0c1ceed644513eb8fa787aac3001a906d209
Subproject commit 9a05c86b02c9c45c2b384c531007416148ec4b56

View File

@ -231,7 +231,7 @@ namespace blt::gp
return correct_types.contains(index) || p2_correct_types.contains(index);
}
void clear()
void clear(gp_program& program)
{
children_data_p1.clear();
children_data_p2.clear();
@ -249,7 +249,7 @@ namespace blt::gp
v.clear();
}
} resolver;
resolver.clear();
resolver.clear(program);
auto min_size = std::min(p1_info.argument_types.size(), p2_info.argument_types.size());
@ -347,9 +347,9 @@ namespace blt::gp
{
BLT_TRACE("(P1 IS UNDER!) Trying to swap P1 {} for P2 {} (Sizes: P1: {} P2: {})", p1_index, p2_index, p1_info.argument_types.size(), p2_info.argument_types.size());
BLT_TRACE("Inserting into P2 from P1!");
c1.copy_subtree(resolver.children_data_p1[p1_index], resolver.temp_tree);
c1.copy_subtree(resolver.children_data_p1[p1_index], resolver.temp_trees[0]);
c1.delete_subtree(resolver.children_data_p1[p1_index]);
c2_insert = c2.insert_subtree(tree_t::subtree_point_t{c1_insert}, resolver.temp_tree);
c2_insert = c2.insert_subtree(tree_t::subtree_point_t{c1_insert}, resolver.temp_trees[0]);
} else if (p2_index < p2_info.argument_types.size() && p1_index >= p1_info.argument_types.size())
{
BLT_TRACE("(P2 IS UNDER!) Trying to swap P1 {} for P2 {} (Sizes: P1: {} P2: {})", p1_index, p2_index, p1_info.argument_types.size(), p2_info.argument_types.size());