topology.brep_p5 green
- Layer
- 47
- Upstream lines
- 2,193
- Functions
- 14
- Rust module
topology::brep::p5
Status history
- todo 2,193 lines
- partial 2,193 lines
- green 2,193 lines
Source: crates/solidcore/src/topology/brep/p5.rs
Upstream: source/SMLib/src/SmBrep.cpp
Port-plan notes
These notes preserve historical port measurements and limitations, not current CI results.
UNLINKED RECORDS (2026-10-24, wire/brep-p5-unlinked-records): the runner's deferral of results that leave a vertex use, edge use or shell unlinked in the arena is removed (stale: graph compares only the records reachable from the B-rep, as the native export walk emits only those), so the 2 isolated_op13 cases (CreateWireEdgeFromCurve; the unlinked record is the start vertex-shell's vertex use that MakeEdgeVertexTopology deletes) are compared. Difftest 797 cases: 797 pass, 0 deferred, max_rel_err=0e0 (--seeds 6000: 6285/6285, a regression check only). This supersedes 'certified: 0/12' below: op 13 compares a successful topology mutation. OPEN: SmBrep::GlueVertices of vertices of two B-reps stays UNPORTED(topology.brep_p5) in the boolean.topology_intersector_p1 runner (p5::glue_vertices takes one B-rep arena). UPDATE (PR #678, 2026-10-23): UpdateVertexEdgeIntervals wired to topology.brep_p1 and SqueezeFace wired to heal.stitch_p1 / heal.stitch_p2 Stitch manager; includes boolean.topology_intersector_p3 post-merge Walk harness update (PR #679). Difftest 797 cases: 795 pass, 0 fail, 2 deferred (blocked by topology.brep_p4 destructor/owning record erasure), max_rel_err=0e0. G10 (PR #637, 2026-10-23): face ChangeGeometry notification wired. difftest 797 cases, 787 pass, 0 failed, 10 deferred (topology.brep_p1 8, topology.brep_p4 2); the 2 former topology.face_p3 deferrals pass. PARTIAL (PR #194, functional source ecccb67b; official main 9a7c1ec0; Claude review fixes): all twelve owned editing control flows and pending-topology cleanup present; individual missing callees/types defer. Landed shell/region callees wired; stable shell, vertex and vertex-use record erasure remains the part 4 SmBrep destructor/storage integration gap. Native difftest: 797 cases (285 fixtures + 512 generated), 737 passed, 0 failed, 60 deferred (topology.brep_p1 10, topology.brep_p2 46, topology.brep_p4 2, topology.brep_p9 2), max_rel_err=0, no absolute floors. Meaningful successful topology-mutation paths certified: 0/12 operations (issue #210). Coverage is 409 point/tolerance-target-stage cases, 301 whole-operation refusals/empty/identity/alias no-ops, and 27 supporting notification scripts. Temporary-edge minimum-length threshold, successful topology mutation, nonidentity transforms, shared native geometry across distinct owning records and pending-reader integration remain uncertified. Sensitivity 737/737 detected; 4096 generated: 4375 cases, 4195 passed, 180 deferred, 0 failed. Formatting, both strict Clippy configurations, 1369 kernel tests, WASM, 3 native FFI tests and all twelve affected differential units pass; full green/partial sweep PASS: 205 units, 113 green, 92 partial, 0 failed. No open dependency PR bundled or other unit promoted. 14 fns; largest: SmBrep::RemoveTopologicalEdgesAndVertices, SmBrep::CombineCoincidentVertices, SmBrep::DeleteTopologicalVertex, SmBrep::GlueVertices; cycle back-edges (call into later units; stub or co-port): topology.brep_p3(8), topology.brep_p2(5), heal.stitch_p1(3), topology.brep_p9(3), heal.stitch_p2(2); unit-SCC #22 (220 units); hazards: ptr-iter; 200 upstream test entry points reach this unit Second review round (head e9df9346, merged official main with topology.brep_p1/p7 and heal.stitch_p1): isolated aliased CombineCoincidentVertices takes the native path (6 new fixtures, deferred at Notify; only the target stage refuses it, UB-191); Notify status ignored in combine as upstream; SqueezeFace unlock never hides its result; FFI guard refusals are rejected, not failed. Wired heal.stitch_p1 (GlueVertices, RemoveFaces, StitchAndOrient) and topology.brep_p7 (GlueVertices) into this unit. Calls into the now-partial topology.brep_p1 are still UNPORTED stubs pending a follow-up PR. Batch integration (batch/clean-2026-10-19): set_face_tolerance wired to topology::face::p3::set_tolerance (topology.face_p3). Re-run in PR #149 (review 5578349117 round, merged with main through fb58ea76; topology.brep_p2's UNPORTED stubs wired): 797 cases, 738 pass, 0 fail, 59 deferred (topology.brep_p1 38, topology.brep_p4 12, topology.brep_p3 7, topology.brep_p9 2); the 46 SmBrep::Notify deferrals: 1 pass, the rest relabel to brep_p1 GetVertices / UpdateVertexEdgeIntervals, brep_p4 DeleteVertex and brep_p3 TurnToNURBS. Re-run after wiring stale stubs (PR #285): 797 cases, 744 pass, 0 fail, 53 deferred, max_rel_err 0. UPDATE (PR #204, topology.brep_p3): the UNPORTED(topology.brep_p3) stubs SqueezeEdge, MakeWireEdgeVertex, DeleteFace, OrientTrimmedSurfaces and TurnToNURBS, and UNPORTED(topology.brep_p9) MakeShellVertex in create_wire_edge_from_curve, are wired to topology::brep::p3 / p9 through with_p3_notifications (the caller's environment, else a topology.brep_p2 ArenaNotifyState over the kernel context's callbacks lent with brep::p3::with_lent_context); make_manifold and stitch_and_orient take k: &mut Kernel. Case by case: no outcome change; the 7 TurnToNURBS deferrals relabel to topology.brep_p1 GetVertices (797 cases, 738 pass, 0 fail, 59 deferred: topology.brep_p1 45, topology.brep_p4 12, topology.brep_p9 2). UPDATE (PR #204, Codex review of 255d52b7): a plain entry point (no environment; the _with_notifications forms given None) runs its whole edit in one environment under the kernel's identities (plain_edit = topology::brep::p3::with_kernel_callbacks: the B-rep's serial in the kernel context's domain, so two B-reps' objects never share a key in one context; the callbacks lent to the edit; nested in another lent edit it is refused before anything changes). create_wire_edge_from_curve, make_manifold, remove_faces, stitch_and_orient and squeeze_face are plain_edit wrappers over _in bodies; with_p3_notifications no longer falls back to ArenaNotifyState. UPDATE (PR #204, Codex re-check of 6b04141d): plain_edit's environment carries a default record for every existing object from the start (brep::p3::kernel_named_edit), so the notifications sent before any p3 edit (e.g. notify_edge_merge) are delivered. UPDATE (PR #204, merge of main #339): op 13 (CreateWireEdgeFromCurve) runs now that GetInfiniteRegion is wired; its 2 fixture cases (isolated_op13_editing_) compared the vertex-shell vertex use MakeEdgeVertexTopology deletes upstream and the arena keeps unlinked; with graph() comparing reachable records only (boolean.merge_p1) they pass. API EXTENDED in sweep.topology_sweep (PR #222): make_edge_in_face_with_uv_curve preserves polymorphic UV curve kinds, including native SmBSplineCurve-derived lines; the existing B-spline-only Rust entry point delegates without changing behavior. UPDATE (PR #526): FindAndSetInfiniteRegion wired to topology.brep_p9 FindInfiniteRegion (through the caller's query::brep::BrepQuery) and topology.brep_p1 ResetInfiniteRegion; it takes the kernel and SetRegionVoidType. Re-run: 797 cases, 746 pass, 0 fail, 51 deferred (the 2 FindInfiniteRegion deferrals pass). UPDATE (wire/brep-p5-find-vertex-sector): MakeEdgeInFace wired to topology.face_p4 FindVertexSector and topology.brep_p9 MakeEdgeInFaceWithVU; make_edge_in_face(_with_uv_curve) take the kernel and an optional notification environment (None: plain edit). 797 cases, 746 pass, 51 deferred, 0 failed (unchanged). SweepStore transforms use owner-aware brep_p1 collections and brep_p3 NURBS conversion. Fixture import binds ownership metadata to its kernel without changing geometry values; unavailable face-p3 UV-trim construction remains deferred. UPDATE (PR #441): StitchAndOrient runs its two StitchFaces passes outside the edit lease (the stitch's glue/squeeze helpers notify through their own kernel-context edits, which the nested-edit guard refused, and the swallowed error left swept B-reps unstitched); the orientation pass keeps the caller's environment. The shell-vertex glue path still stops at remove_owned_vertex (plan/findings.md). UPDATE (oursland/solidcore#1): remove_owned_vertex is Brep::remove_from_vertex_list; the 36 heal.stitch_p2 differences it exposed were topology.brep_p7 GlueEdgesGeneral leaving the glued edge on the edge list (fixed); difftest 797 cases, 785 pass, 0 failed, 12 deferred. UPDATE (wire: SmBrep::Transform into blend.hcr and the boolean.merge_p1 runner, PR #679): CombineCoincidentVertices calls the ported topology.brep_p1 UpdateVertexEdgeIntervals under the caller's notification environment (the stub is gone). difftest 797 cases, 795 pass, 0 failed, 2 deferred (topology.brep_p4 2); the 8 UpdateVertexEdgeIntervals deferrals pass. Public solid scale phase two (2026-10-24): conversion receives the same proven producer/canonical geometry selection as the later transform, without owner rewriting. Native conversion now precedes both geometry passes for actual constructed/copied box/sphere scales. Ten real nonuniform/signed/reflected scale cases pass exactly; both reflection corrections independently detected by controlled omissions (3 failures each). Two Rust controls retain foreign/None owner filtering and verify a later transform moves converted geometry without rebinding.
Goldens
This is committed inventory, not a runtime result or a correctness proof. A golden records what solidcore produced when blessed. Current results require the canonical CI gate, not these counts.
- Golden records
- 797
- Stored error outcomes
- 0
- Stored deferrals
- 0
- Stored harness rejections
- 0
- Known-failure entries
- 0
Metadata counts describe fields in the stored records; they are not passes or live failures.
Source at f9704ee3b:
golden JSONL ·
known-failure list.
Dependencies
Depends on: curve.curve_p2 green geom.a_object green geom.extent1d green geom.extent3d green geom.object green geom.solution_array green geom.tol green geom.vector3d green nurbs.b_spline_curve_p1 green surface.surface_p2 partial topology.brep_p1 green topology.brep_p4 green topology.edge green topology.edgeuse_p1 green topology.face_p2 partial topology.face_p4 green topology.proto_topology_p1 green topology.shell green topology.topology green topology.vertex green topology.vertexuse green
Soft dependencies: curve.curve_p5 partial curve.curve_p6 green geom.axis2_placement green geom.context green geom.extent2d green nurbs.b_spline_curve_n_lib green nurbs.b_spline_curve_p2 green nurbs.b_spline_curve_p3 green nurbs.b_spline_surface_p1 green surface.surface_p1 green topology.edgeuse_p3 green topology.face_p3 green
Dependents: blend.feature_executive blocked blend.fillet_executive_p1 green blend.fillet_removal green heal.heal_data_p3 green heal.stitch_p1 green primitive.primitive_creation_p1 green primitive.primitive_creation_p2 green primitive.primitive_creation_p3 green sweep.topology_sweep green topology.api_files partial topology.brep_cutting partial topology.brep_local_operation partial topology.brep_mirror green
Soft dependents: blend.hcr green boolean.merge_p1 green boolean.merge_p2 green boolean.merge_p3 green boolean.merge_p4 green boolean.topology_intersector_p1 green boolean.topology_intersector_p2 green heal.heal_data_p1 green heal.stitch_p2 green offset.offset_executive_p1 partial offset.offset_executive_p2 partial primitive.api_primitives green topology.proto_topology_p2 green topology.proto_topology_p3 green
Upstream functions
| Upstream function | Defined at | Lines | Rust (from the file header) |
|---|---|---|---|
SmBrep::CombineCoincidentVertices | SmBrep.cpp:1266 | 344 | [coincident_vertex_target], [combine_coincident_vertices] |
SmBrep::CreateWireEdgeFromCurve | SmBrep.cpp:2264 | 30 | [create_wire_edge_from_curve] |
SmBrep::DeleteTopologicalVertex | SmBrep.cpp:7625 | 259 | [delete_topological_vertex] |
SmBrep::FindAndSetInfiniteRegion | SmBrep.cpp:8690 | 40 | [find_and_set_infinite_region] |
SmBrep::GlueVertices | SmBrep.cpp:9596 | 224 | [glue_vertices] |
SmBrep::MakeEdgeInFace | SmBrep.cpp:13770 | 129 | [make_edge_in_face], [make_edge_in_face_with_uv_curve], [make_edge_in_face_in] |
SmBrep::MakeManifold | SmBrep.cpp:18807 | 165 | [make_manifold] |
SmPendingTopologyDelete::SmPendingTopologyDelete | SmBrep.cpp:19519 | 4 | [PendingTopology] |
SmPendingTopologyDelete::~SmPendingTopologyDelete | SmBrep.cpp:19524 | 14 | |
SmBrep::RemoveTopologicalEdgesAndVertices | SmBrep.cpp:25931 | 501 | [remove_topological_edges_and_vertices] |
SmBrep::RemoveFaces | SmBrep.cpp:26445 | 60 | [remove_faces] |
SmBrep::StitchAndOrient | SmBrep.cpp:26934 | 66 | [stitch_and_orient] |
SmBrep::SqueezeFace | SmBrep.cpp:27585 | 158 | [squeeze_face] |
SmBrep::Transform | SmBrep.cpp:29050 | 199 | [transform] |
Module file-header table (15 rows)
| Rust | Upstream |
|---|---|
[coincident_vertex_target], [combine_coincident_vertices] | SmBrep::CombineCoincidentVertices |
[create_wire_edge_from_curve] | SmBrep::CreateWireEdgeFromCurve |
[delete_topological_vertex] | SmBrep::DeleteTopologicalVertex |
[find_and_set_infinite_region] | SmBrep::FindAndSetInfiniteRegion |
[glue_vertices] | SmBrep::GlueVertices |
[make_edge_in_face], [make_edge_in_face_with_uv_curve], [make_edge_in_face_in] | SmBrep::MakeEdgeInFace |
[make_manifold] | SmBrep::MakeManifold |
[remove_topological_edges_and_vertices] | SmBrep::RemoveTopologicalEdgesAndVertices |
[remove_faces] | SmBrep::RemoveFaces |
[remove_faces_notified] | SmBrep::RemoveFaces (caller's records) |
[stitch_and_orient] | SmBrep::StitchAndOrient |
[squeeze_face] | SmBrep::SqueezeFace |
[transform] | SmBrep::Transform(const SmAxis2Placement&, ...) (the 4x4 matrix overload is not owned by this unit) |
[turn_to_nurbs_plain] | SmBrep::TurnToNURBS() as a plain entry point (the edit is topology.brep_p3's) |
[PendingTopology] | SmPendingTopologyDelete constructor/destructor and Clear (co-port) |
Upstream tests reaching this unit
prog_test:my_test_tsurf_cyl_creation_2d, prog_test:my_test_tsurf_cyl_creation_3d, prog_test:my_test_tsurf_cyl_creation_fast, prog_test:my_test_tsurf_creation, SM_API_test:TestSmCreatePlanarCircle, SM_API_test:TestIntersectionOutputStatus