style: drop Xtend-compiler boilerplate in migrated check.core files - #1491
Open
joaodinissf wants to merge 2 commits into
Open
style: drop Xtend-compiler boilerplate in migrated check.core files#1491joaodinissf wants to merge 2 commits into
joaodinissf wants to merge 2 commits into
Conversation
joaodinissf
force-pushed
the
migrate/xtend-to-java/check-core-step-2
branch
from
August 14, 2026 15:50
f2846d4 to
c68ec00
Compare
joaodinissf
marked this pull request as ready for review
August 14, 2026 15:50
joaodinissf
enabled auto-merge (rebase)
August 14, 2026 15:59
…ore files Extend the boilerplate cleanup from the dsldevkit#1452 review to the remaining migrated files: remove explicit generic type witnesses (57) and explicit lambda parameter types (109) that the Xtend compiler always emits, plus the five imports orphaned by the removals. Java's inference resolves every site to the same types; the compiler and the untouched gates are the proof. CheckFormatter, CheckJvmModelInferrer, CheckGenerator and CheckGeneratorExtensions; no semantic change. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
joaodinissf
force-pushed
the
migrate/xtend-to-java/check-core-step-2
branch
from
August 14, 2026 16:18
c68ec00 to
6c66a56
Compare
Replace the six-append assembly of the ImmutableMap builder head with a
single formatted() statement:
builder.append("ImmutableMap.<String, String>builderWithExpectedSize(%d)\n"
.formatted(sortedUniqueQualifiedIssueCodeNamesAndLabels.entrySet().size()));
All three simplifications are output-identical by construction:
- the getSimpleName() calls always produce "ImmutableMap"/"String"
(top-level classes; rename safety already lives in the field's
typeRef, which also supplies the generated file's import);
- the trailing newLineIfNotEmpty() provably always fired (the line ends
with a static ")"), so an unconditional newline is equivalent, and
StringConcatenation.append(String) normalizes the embedded \n to the
builder's own delimiter;
- the generation tests pin the emitted output either way.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
joaodinissf
force-pushed
the
migrate/xtend-to-java/check-core-step-2
branch
from
August 14, 2026 20:29
e109329 to
ecf695f
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.
Removes the boilerplate the Xtend compiler always emits from the remaining check.core files migrated in #1452, matching the cleanup applied to
CheckScopeProviderduring that PR's review:EcoreUtil2.<Context> getContainerOfType(…),Iterables.<Check>concat(…), …) — Java's inference resolves every site to the same type.(final JvmGenericType it) ->→it ->).Touches
CheckFormatter,CheckJvmModelInferrer,CheckGeneratorandCheckGeneratorExtensions. No semantic change: single-overload extension methods throughout, so inference cannot pick a different target; compile plus clean PMD/Checkstyle/SpotBugs gates verify it.🤖 Generated with Claude Code