jextract: deduplicate protocol requirements before code generation #916
@ktoso Gentle ping on this one when you have a chance. The CI checks are green, and this addresses #891. Please let me know if you'd like any changes. Thanks!
This seems to be fixing the symptom and not the problem itself? We should insttead fix how requirements are collected maybe?
this isn't valid swift tbh, can't have the public here
This seems a bit hacky, like fixing the symptom rathe rthan maybe identify them differently to begin with?
fixed, sorry for this bug
Moved the deduplication upstream to uniqueProtocolRequirements, so both Swift thunks and Java bindings use the deduplicated protocol requirements.
I also added signature normalization and regression tests to cover cases like different parameter names, overloads, and a non-throwing default implementation satisfying a throwing requirement.
Update PR title and description for current implementation.
I think this PR is too big, close this one and rewrite in #934
ktoso
Hokila
Summary
Fixes #891
Testing
swift test --filter JNIProtocolTestsswift test --filter JExtractSwiftTestsxcrun swift-format lint --configuration .swift-formaton changed Swift files