docs: harden Xtend-to-Java migration fidelity rules - #1473
Open
joaodinissf wants to merge 1 commit into
Open
Conversation
joaodinissf
force-pushed
the
docs/xtend-skill-operator-add-and-exceptions
branch
from
August 10, 2026 22:46
627637c to
0b8d690
Compare
joaodinissf
force-pushed
the
docs/xtend-skill-operator-add-and-exceptions
branch
from
August 26, 2026 09:39
0b8d690 to
5d5348d
Compare
joaodinissf
marked this pull request as ready for review
August 26, 2026 09:51
joaodinissf
enabled auto-merge (rebase)
August 26, 2026 09:52
rubenporras
reviewed
Aug 26, 2026
| - [ ] All comments and class/member Javadoc preserved exactly. | ||
| - [ ] Copyright header is the exact Avaloq banner — **replacing** any generated-stub or Javadoc-style header the source had (not preserved from source). | ||
| - [ ] Checked exceptions handled (`throws` clause or `try`/`catch` with specific types). | ||
| - [ ] Checked exceptions preserve the original signature and throwable identity using only narrow catches; `Exceptions.sneakyThrow` is used where required. |
Member
There was a problem hiding this comment.
I would not use Exceptions.sneakyThrow
joaodinissf
force-pushed
the
docs/xtend-skill-operator-add-and-exceptions
branch
from
August 26, 2026 12:03
5d5348d to
5f7da05
Compare
Encode the migration traps verified against Xtext 2.43.0 and current repository code. Preserve both JvmTypesBuilder.operator_add null-skipping overloads and document nullable builder results. Preserve IterableExtensions.toSet encounter order and observable Set aliasing. Define explicit checked-exception contracts without copying generated exception-handling scaffolding. Choose charsets from a verified data contract instead of guessing from source encoding. Align the quick reference, validation checklist, pitfalls, and worked example with those rules. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
joaodinissf
force-pushed
the
docs/xtend-skill-operator-add-and-exceptions
branch
from
August 26, 2026 13:51
5f7da05 to
802f769
Compare
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.
What
Hardens
.agents/skills/xtend-to-javawith migration-fidelity rules verified against Xtext 2.43.0, freshxtend-gen, and current repository migrations.Rules and fixes
JvmTypesBuilder.operator_addnull-skipping overloads at inferrerEList +=sites; nullable builders and helpers require guards orObjects::nonNull.IterableExtensions.toSetencounter order withLinkedHashSet, and check whether its return-existing-Setaliasing is observable.Exceptions.sneakyThrowwhen one must escape undeclared. Do not catchThrowable,Exception, orRuntimeExceptionmerely to imitatextend-gen; a broad catch is allowed only when the invoked API declares that type and no narrower form compiles.Why
The
operator_addrule prevents the regression fixed in #1474:FormatJvmModelInferrer.inferConstantsused a bareEList.addfor a nullable producer and threw where Xtend skipped null. The ordered-set rule protects generator output in the remaining Wave 4 scope/export migrations.Validation
git diff --checkmvn -f ./ddk-parent/pom.xml -pl :com.avaloq.tools.ddk.xtext.scope -am -DskipTests -T 1 compile --batch-mode—BUILD SUCCESSSkill-only Markdown change; no production or build-configuration changes.