Skip to content

Add support for 'interface' and 'unmanaged' generic constraints#437

Merged
cirras merged 2 commits into
integrated-application-development:masterfrom
Bazooper-blip:generic-constraints-interface-unmanaged
May 27, 2026
Merged

Add support for 'interface' and 'unmanaged' generic constraints#437
cirras merged 2 commits into
integrated-application-development:masterfrom
Bazooper-blip:generic-constraints-interface-unmanaged

Conversation

@Bazooper-blip
Copy link
Copy Markdown

Delphi 13 introduces two new generic constraint keywords:

  • 'interface': ensures type parameter implements an interface
  • 'unmanaged': ensures type parameter is a simple value type

Adds full constraint pipeline: API interfaces, AST nodes, constraint implementations with cross-constraint compatibility, grammar rules, visitor methods, and comprehensive tests.

Closes #413, closes #414

Copy link
Copy Markdown
Collaborator

@cirras cirras left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These changes look good on the surface but don't entirely match reality and can't be accepted without some changes.

You should test your assumptions against an actual Delphi 13 compiler.

Sammy Valtonen and others added 2 commits May 27, 2026 11:37
Delphi 13 introduces two new generic constraint keywords:
- 'interface': ensures type parameter is an interface type
- 'unmanaged': ensures type parameter is a simple value type

Closes integrated-application-development#413, closes integrated-application-development#414

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@cirras cirras force-pushed the generic-constraints-interface-unmanaged branch from a8f3562 to f09e099 Compare May 27, 2026 01:40
@cirras cirras merged commit 7f3002a into integrated-application-development:master May 27, 2026
2 checks passed
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.

Support unmanaged generic constraint Support interface generic constraint

2 participants