Repository navigation
ObjC++: out-of-line C++ member definitions (Cls::M, ctor, dtor) are units (Part of #5639) - #5691
Merged
Merged
Conversation
…nits (Part of #5639) Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Owner
Author
|
No description provided. |
squid-protocol
marked this pull request as ready for review
October 20, 2026 03:29
squid-protocol
enabled auto-merge (squash)
October 20, 2026 03:30
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #5639. Follow-up to #5689 (the issue stays open).
Cross-repo: none (no corpus or pin change).
What
gzdoom's remaining Objective-C call misses were not call-pattern bugs: in
.mmfiles an out-of-line C++ member definition (bool Cls::Method() {, constructorCls::Cls()with or without an initializer list, destructorCls::~Cls()) was not afunc_startmatch, so the previous unit's extent swallowed those bodies and their message sends were attributed to no unit (or the wrong one).func_start's C-style alternative now accepts aScope::qualifier (names the last component,~Clsfor a destructor) and a bare qualified ctor/dtor with no return type. A qualified call statement (Cls::Helper(1);) and a prototype still start no unit (the existing bodyless-;rejection).Changes (3 hand-written files)
languages/objectivec.py:func_startC-style alternative.test_objc_cxx_member_units_5639.py(new): six header shapes, attribution after a class body, call-statement/prototype negatives, ReDoS.Class table (unit-extent class: ObjC++ constructs the C-style rule could not see)
T Cls::M(),ns::Cls::M(), multi-line paramsCls::Cls(), ctor with init list, dtorCls::~Cls()Cls::f(x);statement,T Cls::f();prototypestatic CocoaWindow* GetWindow() {}insideclass)Evidence
doom-study oracle (
callcheck_all.pylogic, objective-c row) on this branch's scan of gzdoom's 10 Objective-C/++ files:Remaining miss:
I_InitGraphics -> UseHiDPI(SystemBaseFrameBuffer::UseHiDPI(qualified static call; the callee unit is a different shape). Engine-only edges are] initnested sends the oracle regex cannot see, and the destructor~Cls -> Cls(a destructor naming its own class; oracle strips it).Gates:
pr_gates --fast6/6;--ratchets8 pass / 0 fail / 0 skipped; tree-wide guards 184 passed. Golden masters (both legs,golden-lock.sh crucible_check.py --update --yes): no drift (the crucible corpus has no ObjC++ member definitions).Remaining slices
calls_outis in the non-qualified family;_call_qualifierwalks backward over./->/::, which does not fit[recv sel]. Needs a bracket-aware qualifier path indetector.pyplus a decision on how qualified edges resolve (a wrong qualifier could narrow resolved edges), measured on the doom ports. Files:detector.py,_shared_patterns.py/objc rule flag, tests.[f(x) a:1].Sibling gaps
- (void)m;followed by{(header ending in;) gives a 1-line unit: doom-iosUICustomSwitch.m setOn, eternityELTextFieldDelegate.m controlTextDidChange(extent mechanism; from ObjC: message sends recorded as calls by selector; @selector is not a call (Part of #5639) #5689).Cls::UseHiDPI(not recorded in gzdoomI_InitGraphics(callee/def shape unverified).🤖 Generated with Claude Code