Repository navigation
Conversation
Only class_declaration was registered as a PHP class type, so interface, enum, and trait declarations produced no node and their heritage edges (interface extends -> inherits, enum implements -> implements, trait use -> mixes_in) were dropped entirely. Add interface_declaration, enum_declaration, and trait_declaration to the PHP class_types. Enums wrap their members in an enum_declaration_list rather than a declaration_list, so also add it to body_fallback_child_types so enum methods/cases get walked. Adds a regression test covering interface extends, enum implements, trait use, and an enum-body method.
|
good job |
safishamsi
pushed a commit
that referenced
this pull request
Aug 30, 2026
…1791) Only class_declaration was treated as a class type, so PHP interfaces, enums, and traits produced no node and no heritage edges. Add them as class-like containers (and walk the enum body) so their extends/implements/use heritage is captured as inherits/implements/ mixes_in edges to the right targets.
safishamsi
added a commit
that referenced
this pull request
Aug 30, 2026
Ships two batches: the robot/defang/watch/semantic-guard set — Robot Framework extractor (#3192), generalized control-token defang (#3183), watch unresolved-link preservation (#3190), unverified-semantic-loss guard (#3203), hook-guard search detection (#3121), stale-SKILL.md backup (#3144), report/wiki count fixes (#3148/#3127); and a rescued batch of @Synvoya cross-language inheritance-edge corrections (JS #1790, PHP #1791, Scala #1792/#1794, Kotlin #1793, C# #1817, Go #1818) that had been buried in the backlog for ~7 weeks. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Member
|
Shipped in v0.9.53 via authorship-preserving cherry-pick so you keep contributor-graph credit. Thanks @Synvoya — this was verified still-live on the current tree and landed as part of a cross-language heritage-edge batch. Release: https://github.com/Graphify-Labs/graphify/releases/tag/v0.9.53 |
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.
Bug
PHP interfaces, enums, and traits produce no node and no heritage edges.
interface B extends A,enum E implements I, andtrait T { use U; }are all silently dropped.Root cause
_PHP_CONFIG.class_typesonly containedclass_declaration, so the generic extractor never treatedinterface_declaration,enum_declaration, ortrait_declarationnodes as class-like. They never became nodes, and the PHP heritage handler (which runs per class-like node) never fired for them.Minimal repro
Before: no
Nameable/Suit/Greetsnodes, noinherits/implements/mixes_inedges.Fix
interface_declaration,enum_declaration, andtrait_declarationto_PHP_CONFIG.class_types.enum_declaration_list(not adeclaration_list), so add it tobody_fallback_child_typesso enum methods/cases are walked.After the fix the repro yields:
Nameable --inherits--> IdentifiableSuit --implements--> NameableGreets --mixes_in--> NamedSuit --method--> label(enum body now walked)Testing
test_php_interface_enum_trait_heritagetotests/test_languages.py, mirroring the existingtest_php_splits_inherits_implements_mixes_inassertion style. Fails before, passes after.tests/test_languages.py: 315 passed, 13 skipped (was 314 + this new test).