Skip to content

fix(ModelTopology): Fixed check on corner internal to a line#184

Open
MelchiorSchuh wants to merge 4 commits into
nextfrom
fix/line_internal_corner_check
Open

fix(ModelTopology): Fixed check on corner internal to a line#184
MelchiorSchuh wants to merge 4 commits into
nextfrom
fix/line_internal_corner_check

Conversation

@MelchiorSchuh

Copy link
Copy Markdown
Member

No description provided.

@MelchiorSchuh MelchiorSchuh requested a review from BotellaA June 23, 2026 08:49
@github-actions

github-actions Bot commented Jun 23, 2026

Copy link
Copy Markdown

Cpp-Linter Report ⚠️

Some files did not pass the configured checks!

clang-tidy (v20.1.8) reports: 10 concern(s)
  • src/geode/inspector/inspection/topology/brep_corners_topology.cpp:102:31: warning: [readability-function-cognitive-complexity]

    function 'brep_corner_topology_is_valid' has cognitive complexity of 14 (threshold 10)

      102 |     bool BRepCornersTopology::brep_corner_topology_is_valid(
          |                               ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:106:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      106 |         for( const auto& cmv :
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:109:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      109 |             if( cmv.component_id.type() != Corner3D::component_type_static()
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:110:17: note: +1
      110 |                 || !brep_.corner( cmv.component_id.id() ).is_active() )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:114:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      114 |             if( corner_found )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:120:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      120 |             if( brep_.nb_embeddings( corner_uuid ) == 0 )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:122:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      122 |                 if( brep_.nb_incidences( corner_uuid ) == 0 )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:127:18: note: +1, nesting level increased to 2
      127 |             else if( brep_.nb_incidences( corner_uuid ) > 1 )
          |                  ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:132:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      132 |         if( corner_is_multiply_embedded( unique_vertex_index ) )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:136:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      136 |         if( corner_is_part_of_line_but_not_boundary( unique_vertex_index ) )
          |         ^
  • src/geode/inspector/inspection/topology/brep_corners_topology.cpp:180:30: warning: [readability-function-cognitive-complexity]

    function 'corner_is_multiply_embedded' has cognitive complexity of 12 (threshold 10)

      180 |         BRepCornersTopology::corner_is_multiply_embedded(
          |                              ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:183:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      183 |         for( const auto& cmv :
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:186:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      186 |             if( cmv.component_id.type() == Corner3D::component_type_static()
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:188:17: note: +1
      188 |                 && brep_.nb_embeddings( cmv.component_id.id() ) > 1 )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:190:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      190 |                 for( const auto& embedding :
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:193:21: note: +4, including nesting penalty of 3, nesting level increased to 4
      193 |                     if( embedding.type() == Block3D::component_type_static()
          |                     ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:194:25: note: +1
      194 |                         && brep_.block( embedding.id() ).is_active() )
          |                         ^
  • src/geode/inspector/inspection/topology/brep_corners_topology.cpp:236:30: warning: [readability-function-cognitive-complexity]

    function 'corner_is_part_of_line_but_not_boundary' has cognitive complexity of 27 (threshold 10)

      236 |         BRepCornersTopology::corner_is_part_of_line_but_not_boundary(
          |                              ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:239:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      239 |         for( const auto& cmv :
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:242:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      242 |             if( cmv.component_id.type() != Corner3D::component_type_static()
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:243:17: note: +1
      243 |                 || !brep_.corner( cmv.component_id.id() ).is_active() )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:249:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      249 |             for( const auto& cmv_line :
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:253:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      253 |                 if( cmv_line.component_id.type()
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:255:21: note: +1
      255 |                     || !brep_.line( line_id ).is_active() )
          |                     ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:261:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      261 |             for( const auto& [line_id, nb_cmvs] : line_to_nb_cmvs )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:264:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      264 |                 if( brep_.is_boundary( corner, line ) )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:266:21: note: +4, including nesting penalty of 3, nesting level increased to 4
      266 |                     if( nb_cmvs != 1 && nb_cmvs != 2 )
          |                     ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:266:38: note: +1
      266 |                     if( nb_cmvs != 1 && nb_cmvs != 2 )
          |                                      ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:281:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      281 |                 if( brep_.is_internal( corner, line ) )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:283:21: note: +4, including nesting penalty of 3, nesting level increased to 4
      283 |                     if( nb_cmvs != 2 )
          |                     ^
  • src/geode/inspector/inspection/topology/brep_corners_topology.cpp:311:30: warning: [readability-function-cognitive-complexity]

    function 'inspect_corners_topology' has cognitive complexity of 14 (threshold 10)

      311 |         BRepCornersTopology::inspect_corners_topology() const
          |                              ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:314:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      314 |         for( const auto& corner : brep_.active_corners() )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:316:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      316 |             if( !corner_is_meshed( brep_.corner( corner.id() ) ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:327:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      327 |             if( corner_result.nb_issues() != 0 )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:336:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      336 |         for( const auto unique_vertex_id : Range{ brep_.nb_unique_vertices() } )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:338:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      338 |             if( const auto problem_message =
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:344:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      344 |             if( const auto problem_message =
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:350:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      350 |             if( const auto problem_message =
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_corners_topology.cpp:357:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      357 |             if( const auto problem_message =
          |             ^
  • src/geode/inspector/inspection/topology/brep_lines_topology.cpp:164:28: warning: [readability-function-cognitive-complexity]

    function 'vertex_is_part_of_invalid_embedded_line' has cognitive complexity of 17 (threshold 10)

      164 |         BRepLinesTopology::vertex_is_part_of_invalid_embedded_line(
          |                            ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:167:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      167 |         for( const auto& line_cmv :
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:170:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      170 |             if( line_cmv.component_id.type()
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:177:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      177 |             if( !line.is_active() )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:181:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      181 |             for( const auto& embedding : brep_.embeddings( line_id ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:183:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      183 |                 if( brep_.Relationships::is_boundary(
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:197:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      197 |                 if( embedding.type() == Block3D::component_type_static()
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:198:21: note: +1
      198 |                     && !internal::brep_blocks_are_meshed( brep_ ) )
          |                     ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:202:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      202 |                 if( !absl::c_any_of(
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:204:25: note: nesting level increased to 3
      204 |                         [&embedding]( const ComponentMeshVertex& cmv ) {
          |                         ^
  • src/geode/inspector/inspection/topology/brep_lines_topology.cpp:225:28: warning: [readability-function-cognitive-complexity]

    function 'vertex_is_part_of_invalid_single_line' has cognitive complexity of 23 (threshold 10)

      225 |         BRepLinesTopology::vertex_is_part_of_invalid_single_line(
          |                            ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:230:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      230 |         if( line_uuids.size() != 1 )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:236:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      236 |         if( !line.is_active() )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:244:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      244 |         if( brep_.nb_embedding_surfaces( line ) < 1
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:245:13: note: +1
      245 |             && brep_.nb_incidences( line_id ) < 1 )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:249:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      249 |         if( surface_uuids.size() == 1 )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:251:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      251 |             if( !brep_.Relationships::is_internal( line_id, surface_uuids[0] )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:252:17: note: +1
      252 |                 && !( brep_.Relationships::nb_embeddings( surface_uuids[0] ) > 0
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:253:23: note: +1
      253 |                       || brep_.Relationships::is_boundary(
          |                       ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:269:14: note: +1, nesting level increased to 1
      269 |         else if( surface_uuids.empty() )
          |              ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:271:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      271 |             if( !internal::brep_blocks_are_meshed( brep_ ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:275:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      275 |             if( block_uuids.size() != 1 )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:283:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      283 |             if( !brep_.Relationships::is_internal( line_id, block_uuids[0] ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:293:9: note: +1, nesting level increased to 1
      293 |         else
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:295:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      295 |             for( const auto& surface_id : surface_uuids )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:298:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      298 |                 if( !brep_.is_boundary( line, surface )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:299:21: note: +1
      299 |                     && !brep_.is_internal( line, surface ) )
          |                     ^
  • src/geode/inspector/inspection/topology/brep_lines_topology.cpp:252:20: warning: [readability-simplify-boolean-expr]

    boolean expression can be simplified by DeMorgan's theorem

      252 |                 && !( brep_.Relationships::nb_embeddings( surface_uuids[0] ) > 0
          |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          |                                                                              <=
      253 |                       || brep_.Relationships::is_boundary(
          |                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          |                       && !
      254 |                           line_id, surface_uuids[0] ) ) )
          |                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  • src/geode/inspector/inspection/topology/brep_lines_topology.cpp:316:9: warning: [readability-function-cognitive-complexity]

    function 'vertex_is_part_of_line_with_wrong_relationships_to_surface' has cognitive complexity of 38 (threshold 10)

      316 |         vertex_is_part_of_line_with_wrong_relationships_to_surface(
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:319:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      319 |         for( const auto& cmv :
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:322:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      322 |             if( cmv.component_id.type() != Line3D::component_type_static() )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:327:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      327 |             if( !line.is_active() || line.mesh().nb_edges() == 0 )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:327:35: note: +1
      327 |             if( !line.is_active() || line.mesh().nb_edges() == 0 )
          |                                   ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:332:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      332 |             for( const auto& incident_surface : brep_.incidences( line ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:334:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      334 |                 if( !incident_surface.is_active() )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:338:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      338 |                 if( !cme.surface_edges.contains( incident_surface.id() ) )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:349:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      349 |                 if( cme.surface_edges.at( incident_surface.id() ).size() != 1 )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:363:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      363 |             for( const auto& embedding_surface :
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:366:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      366 |                 if( !embedding_surface.is_active() )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:370:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      370 |                 if( !cme.surface_edges.contains( embedding_surface.id() ) )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:382:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      382 |                 if( cme.surface_edges.at( embedding_surface.id() ).size() <= 1 )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:396:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      396 |             if( brep_.nb_incidences( cmv.component_id.id() ) == 0
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:397:17: note: +1
      397 |                 && brep_.nb_embedding_surfaces( line ) == 0 )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:399:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      399 |                 for( const auto& [surface_id, _] : cme.surface_edges )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:401:21: note: +4, including nesting penalty of 3, nesting level increased to 4
      401 |                     if( brep_.surface( surface_id ).is_active() )
          |                     ^
  • src/geode/inspector/inspection/topology/brep_lines_topology.cpp:448:28: warning: [readability-function-cognitive-complexity]

    function 'line_edge_has_wrong_component_edges_around' has cognitive complexity of 36 (threshold 10)

      448 |         BRepLinesTopology::line_edge_has_wrong_component_edges_around(
          |                            ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:452:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      452 |         for( const auto& [surface_id, surface_edges] : cme.surface_edges )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:455:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      455 |             if( !surface.is_active() )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:459:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      459 |             if( brep_.is_boundary( line, surface ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:461:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      461 |                 if( surface_edges.size() != 1 )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:474:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      474 |             if( brep_.is_internal( line, surface ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:476:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      476 |                 if( surface_edges.size() != 2 )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:494:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      494 |         for( const auto& embedding_surface : brep_.embedding_surfaces( line ) )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:496:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      496 |             if( !embedding_surface.is_active() )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:500:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      500 |             if( !cme.surface_edges.contains( embedding_surface.id() ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:511:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      511 |         for( const auto& incident_surface : brep_.incidences( line ) )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:513:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      513 |             if( !incident_surface.is_active() )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:517:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      517 |             if( !cme.surface_edges.contains( incident_surface.id() ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:528:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      528 |         for( const auto& [block_id, block_edges] : cme.block_edges )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:531:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      531 |             if( block.is_active() && brep_.is_internal( line, block ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:531:35: note: +1
      531 |             if( block.is_active() && brep_.is_internal( line, block ) )
          |                                   ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:533:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      533 |                 if( block_edges.size() != 1 )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:545:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      545 |         for( const auto& embedding_block : brep_.embedding_blocks( line ) )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:547:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      547 |             if( !embedding_block.is_active()
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:548:17: note: +1
      548 |                 || embedding_block.mesh().nb_polyhedra() == 0 )
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:552:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      552 |             if( !cme.block_edges.contains( embedding_block.id() ) )
          |             ^
  • src/geode/inspector/inspection/topology/brep_lines_topology.cpp:567:28: warning: [readability-function-cognitive-complexity]

    function 'inspect_lines_topology' has cognitive complexity of 21 (threshold 10)

      567 |         BRepLinesTopology::inspect_lines_topology() const
          |                            ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:570:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      570 |         for( const auto& line : brep_.active_lines() )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:572:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      572 |             if( !line_is_meshed( brep_.line( line.id() ) ) )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:582:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      582 |             if( line_result.nb_issues() != 0 )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:596:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      596 |             for( const auto edge_id : Range{ line.mesh().nb_edges() } )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:598:17: note: +3, including nesting penalty of 2, nesting level increased to 3
      598 |                 if( const auto problem_message =
          |                 ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:606:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      606 |             if( line_edges_with_wrong_cme.nb_issues() != 0 )
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:613:9: note: +1, including nesting penalty of 0, nesting level increased to 1
      613 |         for( const auto unique_vertex_id : Range{ brep_.nb_unique_vertices() } )
          |         ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:615:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      615 |             if( const auto invalid_internal_topology =
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:623:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      623 |             if( const auto problem_message =
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:631:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      631 |             if( const auto problem_message =
          |             ^
    /__w/OpenGeode-Inspector/OpenGeode-Inspector/src/geode/inspector/inspection/topology/brep_lines_topology.cpp:637:13: note: +2, including nesting penalty of 1, nesting level increased to 2
      637 |             if( const auto lines_but_is_not_corner =
          |             ^

Have any feedback or feature suggestions? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants