diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map.h b/Combinatorial_map/include/CGAL/Combinatorial_map.h index 5f9f3d96db0..2c95e5219d0 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map.h @@ -4360,8 +4360,8 @@ namespace CGAL { * @return a dart of the new edge, not incident to the vertex of adart1. */ Dart_handle insert_dangling_cell_1_in_cell_2( Dart_handle adart1, - typename Attribute_handle<0>::type - ah=null_handle, + typename Attribute_handle<0>:: + type ah=null_handle, bool update_attributes=true ) { size_type mark1 = get_new_mark(); @@ -4381,7 +4381,8 @@ namespace CGAL { size_type treated=get_new_mark(); - CMap_dart_iterator_basic_of_involution it1(*this, adart1, treated); + CMap_dart_iterator_basic_of_involution + it1(*this, adart1, treated); for ( ; it1.cont(); ++it1) { @@ -4423,7 +4424,8 @@ namespace CGAL { (beta(it1, dim, CGAL_BETAINV(s1), 2), d2, dim); } } - if (are_attributes_automatically_managed() && update_attributes && ah!=NULL) + if (are_attributes_automatically_managed() && + update_attributes && ah!=NULL) { internal::Set_i_attribute_of_dart_functor::run(this, d1, ah); } diff --git a/Combinatorial_map/include/CGAL/Combinatorial_map_dart.h b/Combinatorial_map/include/CGAL/Combinatorial_map_dart.h index 33b377357a3..f381e76d773 100644 --- a/Combinatorial_map/include/CGAL/Combinatorial_map_dart.h +++ b/Combinatorial_map/include/CGAL/Combinatorial_map_dart.h @@ -239,6 +239,11 @@ namespace CGAL { typename Helper::Attribute_handles mattribute_handles; }; + /// Old name, kept for backward compatibility + template + struct CGAL_DEPRECATED Dart : public Combinatorial_map_dart + {}; + } // namespace CGAL #endif // CGAL_COMBINATORIAL_MAP_DART_H // diff --git a/Combinatorial_map/test/Combinatorial_map/Combinatorial_map_3_test.h b/Combinatorial_map/test/Combinatorial_map/Combinatorial_map_3_test.h index 2cc3a456ec1..466b5fff591 100644 --- a/Combinatorial_map/test/Combinatorial_map/Combinatorial_map_3_test.h +++ b/Combinatorial_map/test/Combinatorial_map/Combinatorial_map_3_test.h @@ -1128,8 +1128,6 @@ bool test3D() d2 = map.make_combinatorial_hexahedron(); map.template sew<3>(d1,d2); d3 = map.beta(d1, 2); - d4 = map.beta(d1, 1,3,1,2); - assert(d4==map.beta(d1,1,3,1,2)); map.display_characteristics(cout) << ", valid=" << map.is_valid() << endl; cout << "remove facet4: " << flush; map.template remove_cell<2>(d1); map.display_characteristics(cout) << ", valid=" << map.is_valid() << endl; @@ -1137,6 +1135,18 @@ bool test3D() v.push_back(map.beta(v[1],1,2,1)); v.push_back(map.beta(v[2],1,2,1)); cout << "insert facet4: " << flush; map.insert_cell_2_in_cell_3(v.begin(),v.end()); map.display_characteristics(cout) << ", valid=" << map.is_valid() << endl; + + Map map2; + d1 = map2.make_combinatorial_hexahedron(); + d2 = map2.make_combinatorial_hexahedron(); + map2.template sew<3>(d1,d2); + if ( !map.is_isomorphic_to(map2) ) + { + std::cout<<"Error: map and map2 are not isomorphic (after insertion/removal).\n"; + assert(false); + return false; + } + map.clear(); v.clear(); cout << "***************************** TEST INSERT FACET 3D DONE."