Skip to content

fix: use ctx.getAllInterfaceFields in class-dispatch for inherited interface fields#121

Merged
cs01 merged 1 commit intomainfrom
fix/dispatch-getAllInterfaceFields
Mar 8, 2026
Merged

fix: use ctx.getAllInterfaceFields in class-dispatch for inherited interface fields#121
cs01 merged 1 commit intomainfrom
fix/dispatch-getAllInterfaceFields

Conversation

@cs01
Copy link
Owner

@cs01 cs01 commented Mar 8, 2026

Summary

  • getInterfaceFromAST, and two field-search loops in class-dispatch.ts iterated interfaceDecl.fields directly, missing inherited fields from extends
  • Added getAllInterfaceFields(iface: InterfaceDeclaration): InterfaceField[] to MethodCallGeneratorContext interface (delegates to existing LLVMGenerator.getAllInterfaceFields which already works correctly)
  • All three sites now call ctx.getAllInterfaceFields() to include parent interface fields

Test plan

  • All 428 unit tests pass
  • Full 3-stage self-hosting passes (Stage 1 and Stage 2 both smoke-test clean)
  • No regressions: object-keys, interface dispatch, and method routing tests pass

🤖 Generated with Claude Code

@cs01 cs01 merged commit acd1d2e into main Mar 8, 2026
12 checks passed
@cs01 cs01 deleted the fix/dispatch-getAllInterfaceFields branch March 9, 2026 04:16
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.

1 participant