Split detail into logical parts - #355
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## jbcoe-cleanup-mangling-tests #355 +/- ##
================================================================
- Coverage 73.05% 72.79% -0.27%
================================================================
Files 10 12 +2
Lines 835 838 +3
Branches 218 221 +3
================================================================
Hits 610 610
Misses 22 22
- Partials 203 206 +3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
6f6dfd7 to
ad20403
Compare
cda5eb4 to
53526aa
Compare
53526aa to
f78871d
Compare
philipcraig
left a comment
There was a problem hiding this comment.
Review of the whole stack (#336 → #355) as one diff against main, at f78871d. Inline comments are on this PR because it holds the final form of every file. Two points fall outside this PR's diff:
scripts/consteval_coverage.pyonly instrumentsprotocol.hh, which keeps 3 of its 21 consteval sites after the split. Theconsteval coveragejob now measures almost nothing, and Codecov reports a pass because it compares percentages. The script needs to iterate over the new headers.name_mangling.h:255encodes everyoperator*asde(unary dereference). A binaryoperator*isml. See the comment onconformance.hh:146.
f78871d to
824fe8c
Compare
consteval_coverage.py only instrumented protocol.hh, which after the detail.hh split keeps 3 of the ~21 original consteval sites; the rest moved to conformance.hh, vtable.hh, member_function_thunks.hh, operator_thunks.hh and protocol_wrappers.hh. The coverage job was reporting a percentage of almost nothing. Instrument all six headers, tagging each trap with a file index alongside the line number since line numbers collide across headers. Addresses philipcraig's review comment on the #336-#355 stack (out of diff): consteval_coverage.py only instruments protocol.hh.
consteval_coverage.py only instrumented protocol.hh, which after the detail.hh split keeps 3 of the ~21 original consteval sites; the rest moved to conformance.hh, vtable.hh, member_function_thunks.hh, operator_thunks.hh, protocol_wrappers.hh and name_mangling.h. The coverage job was reporting a percentage of almost nothing. Instrument all seven headers, tagging each trap with a file index alongside the line number since line numbers collide across headers. The disarmed sentinel is a single NO_PROBE_ARMED constant reused by both the generated C++ macro defaults and the Python call sites, rather than -1 hardcoded independently in three places. ProbePoint carries its file_index directly instead of recomputing it via INSTRUMENTED_HEADERS.index() in run_probe, and write_lcov groups probe_points by header once instead of re-filtering the full list per header. Addresses philipcraig's review comment on the #336-#355 stack (out of diff): consteval_coverage.py only instruments protocol.hh.
consteval_coverage.py only instrumented protocol.hh, which after the detail.hh split keeps 3 of the ~21 original consteval sites; the rest moved to conformance.hh, vtable.hh, member_function_thunks.hh, operator_thunks.hh, protocol_wrappers.hh and name_mangling.h. The coverage job was reporting a percentage of almost nothing. Instrument all seven headers, tagging each trap with a file index alongside the line number since line numbers collide across headers. The disarmed sentinel is a single NO_PROBE_ARMED constant reused by both the generated C++ macro defaults and the Python call sites, rather than -1 hardcoded independently in three places. ProbePoint carries its file_index directly instead of recomputing it via INSTRUMENTED_HEADERS.index() in run_probe, and write_lcov groups probe_points by header once instead of re-filtering the full list per header. Addresses philipcraig's review comment on the #336-#355 stack (out of diff): consteval_coverage.py only instruments protocol.hh.
|
Thanks for the detailed review. I've added some follow-up PRs to the stack and fixed other issues as they were introduced. I'll tackle the noexcept |
e6d30c2 (#347, "Make operator_thunk generic to simplify friendship") dropped the protected special members that stopped operator_overload_set being sliced off through a non-view pointer, while renaming call_operator_overload_set to the now-generic operator_overload_set. Restore them on all four operator specialisations, and add CallOperatorOverloadSetCannotBeDetached tests for protocol and protocol_view alongside the existing MemberThunksCannotBeDetached ones, covering the slicing repro from the review comment. Addresses philipcraig's review comment on operator_thunks.hh:243 in #355.
25a27f5 to
2d2558c
Compare
e6d30c2 (#347, "Make operator_thunk generic to simplify friendship") dropped the protected special members that stopped operator_overload_set being sliced off through a non-view pointer, while renaming call_operator_overload_set to the now-generic operator_overload_set. Restore them on all four operator specialisations, and add CallOperatorOverloadSetCannotBeDetached tests for protocol and protocol_view alongside the existing MemberThunksCannotBeDetached ones, covering the slicing repro from the review comment. Addresses philipcraig's review comment on operator_thunks.hh:243 in #355.
2d2558c to
34137bc
Compare
operator_thunk only specialised the nullary R(*)() form for op_star, so
an interface with a binary operator* (e.g. `Vec operator*(double) const`)
never matched a partial specialisation and fell through to the deleted
primary template, producing an opaque error deep inside
operator_overload_set instead of a clear diagnostic. Binary operator*
support is deferred; for now, reject it explicitly in
protocol_interface_function_infos, next to the ref-qualified check, so
the error surfaces at the interface.
The arity check excludes an explicit object parameter ("deducing this")
so a unary operator* declared that way isn't misclassified as binary.
Addresses philipcraig's review comment on conformance.hh:146 in #355.
e6d30c2 (#347, "Make operator_thunk generic to simplify friendship") dropped the protected special members that stopped operator_overload_set being sliced off through a non-view pointer, while renaming call_operator_overload_set to the now-generic operator_overload_set. Restore them on all four operator specialisations, and add CallOperatorOverloadSetCannotBeDetached tests for protocol and protocol_view alongside the existing MemberThunksCannotBeDetached ones, covering the slicing repro from the review comment. Addresses philipcraig's review comment on operator_thunks.hh:243 in #355.
34137bc to
dc098e1
Compare
e6d30c2 (#347, "Make operator_thunk generic to simplify friendship") dropped the protected special members that stopped operator_overload_set being sliced off through a non-view pointer, while renaming call_operator_overload_set to the now-generic operator_overload_set. Restore them on all four operator specialisations, and add CallOperatorOverloadSetCannotBeDetached tests for protocol and protocol_view alongside the existing MemberThunksCannotBeDetached ones, covering the slicing repro from the review comment. Addresses philipcraig's review comment on operator_thunks.hh:243 in #355.
dc098e1 to
b418417
Compare
e6d30c2 (#347, "Make operator_thunk generic to simplify friendship") dropped the protected special members that stopped operator_overload_set being sliced off through a non-view pointer, while renaming call_operator_overload_set to the now-generic operator_overload_set. Restore them on all four operator specialisations, and add CallOperatorOverloadSetCannotBeDetached tests for protocol and protocol_view alongside the existing MemberThunksCannotBeDetached ones, covering the slicing repro from the review comment. Addresses philipcraig's review comment on operator_thunks.hh:243 in #355.
b418417 to
a742aa1
Compare
e6d30c2 (#347, "Make operator_thunk generic to simplify friendship") dropped the protected special members that stopped operator_overload_set being sliced off through a non-view pointer, while renaming call_operator_overload_set to the now-generic operator_overload_set. Restore them on all four operator specialisations, and add CallOperatorOverloadSetCannotBeDetached tests for protocol and protocol_view alongside the existing MemberThunksCannotBeDetached ones, covering the slicing repro from the review comment. Addresses philipcraig's review comment on operator_thunks.hh:243 in #355.
a742aa1 to
480be76
Compare
e6d30c2 (#347, "Make operator_thunk generic to simplify friendship") dropped the protected special members that stopped operator_overload_set being sliced off through a non-view pointer, while renaming call_operator_overload_set to the now-generic operator_overload_set. Restore them on all four operator specialisations, and add CallOperatorOverloadSetCannotBeDetached tests for protocol and protocol_view alongside the existing MemberThunksCannotBeDetached ones, covering the slicing repro from the review comment. Addresses philipcraig's review comment on operator_thunks.hh:243 in #355.
480be76 to
6b00867
Compare
e6d30c2 (#347, "Make operator_thunk generic to simplify friendship") dropped the protected special members that stopped operator_overload_set being sliced off through a non-view pointer, while renaming call_operator_overload_set to the now-generic operator_overload_set. Restore them on all four operator specialisations, and add CallOperatorOverloadSetCannotBeDetached tests for protocol and protocol_view alongside the existing MemberThunksCannotBeDetached ones, covering the slicing repro from the review comment. Addresses philipcraig's review comment on operator_thunks.hh:243 in #355.
6b00867 to
1e378e2
Compare
No description provided.