refactor: migrate from org.eclipse.xtend to local type system#1277
Draft
joaodinissf wants to merge 6 commits intodsldevkit:masterfrom
Draft
refactor: migrate from org.eclipse.xtend to local type system#1277joaodinissf wants to merge 6 commits intodsldevkit:masterfrom
joaodinissf wants to merge 6 commits intodsldevkit:masterfrom
Conversation
4b8fb58 to
2923b20
Compare
Remove org.eclipse.xtend and org.eclipse.xtend.typesystem.emf dependencies from all MANIFEST.MF files (expression, export, scope, generator.test) and replace with local type system implementation. Changes: - Create local replacement types in expression.generator.type package: XtendType, XtendOperation, XtendVariable, XtendExtension, XtendExecutionContext, DefaultXtendExecutionContext, EClassXtendType, PrimitiveXtendType, EmfRegistryMetaModel, ExpressionAnalyzer - Update CompilationContext to use local types instead of old xtend - Update ExportGeneratorSupport and ScopingGeneratorUtil to extend DefaultXtendExecutionContext instead of old ExecutionContextImpl - Remove checkExtensions validation methods from ExportValidator and ScopeValidator (depended on old xtend ResourceManager) - Update CompilationContextTest and CodeGenerationXTest to use new types - Add type package to expression plugin Export-Package https://claude.ai/code/session_01F7hkXr9MCMGnAMhMDmTd3W
- Fix compilation error: replace EcoreFactory.createEObject() with new Object() for abstract/interface EClasses - Remove unused imports (EObject, EcoreFactory) from EClassXtendType - Add missing Javadoc on public constructors (checkstyle JavadocMethod) - Fix PMD MethodReturnsInternalArray in EmfRegistryMetaModel - Fix catch block: add final parameter, proper CHECKSTYLE suppression - Remove unused context parameter from ExpressionAnalyzer.analyzeString - Remove unused PrimitiveXtendType import from CompilationContextTest https://claude.ai/code/session_01F7hkXr9MCMGnAMhMDmTd3W
- ExpressionAnalyzer: extract string constants to fix MultipleStringLiterals, use Set for comparison operators to fix BooleanExpressionComplexity, collapse nested if to fix CollapsibleIfStatements - EClassXtendType/PrimitiveXtendType: simplify boolean returns in equals() - PrimitiveXtendType: remove unnecessary boxing (Integer.valueOf, Double.valueOf) - ExportGeneratorSupport: remove unnecessary super() call - CompilationContextTest: extract constant for duplicate "test" string https://claude.ai/code/session_01F7hkXr9MCMGnAMhMDmTd3W
…eturns) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…tring) The EmfRegistryMetaModel only handled 1-2 segment type names (e.g. "EObject" or "ecore::EObject"). Multi-segment Java type names like "java::lang::String" (3 segments) returned null, causing CodeGenerationXTest.testTypes to fail. Add resolveJavaType() fallback in DefaultXtendExecutionContext that converts :: delimiters to . and resolves via Class.forName(). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
63f8615 to
9a65942
Compare
The test project created by PluginTestProjectManager listed org.eclipse.xtend as a required bundle. After migrating away from the Xpand library, this bundle is no longer in the test runtime, causing PDE to produce an unresolved bundle error marker — the 5th marker that made CheckQuickfixTest.testBulkApplyingQuickfix fail consistently with expected:<4> but was:<5>. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
Summary
Remove
org.eclipse.xtendandorg.eclipse.xtend.typesystem.emfdependencies from all MANIFEST.MF files and replace with a local type system implementation.What's included
expression.generator.typepackage:XtendType,XtendOperation,XtendVariable,XtendExtension,XtendExecutionContext,DefaultXtendExecutionContext,EClassXtendType,PrimitiveXtendType,EmfRegistryMetaModel,ExpressionAnalyzerDefaultXtendExecutionContextinstead of oldExecutionContextImplExportValidatorandScopeValidator(depended on old xtendResourceManager)java::lang::String)Test plan
CheckQuickfixTest.testBulkApplyingQuickfixtimeout — unrelated, pre-existing)🤖 Generated with Claude Code