From be46b38c8738e1a6c764922ebb8cac2ad86935ce Mon Sep 17 00:00:00 2001 From: Rob Stryker Date: Mon, 8 Apr 2024 16:56:00 -0400 Subject: [PATCH] Type parameters for method calls were missing Signed-off-by: Rob Stryker --- .../src/org/eclipse/jdt/core/dom/JavacConverter.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/org.eclipse.jdt.core.javac/src/org/eclipse/jdt/core/dom/JavacConverter.java b/org.eclipse.jdt.core.javac/src/org/eclipse/jdt/core/dom/JavacConverter.java index 1b812cc464b..508f223569b 100644 --- a/org.eclipse.jdt.core.javac/src/org/eclipse/jdt/core/dom/JavacConverter.java +++ b/org.eclipse.jdt.core.javac/src/org/eclipse/jdt/core/dom/JavacConverter.java @@ -535,6 +535,15 @@ private MethodDeclaration convertMethodDecl(JCMethodDecl javac, ASTNode parent) } javac.getParameters().stream().map(this::convertVariableDeclaration).forEach(res.parameters()::add); + + if( javac.getTypeParameters() != null ) { + Iterator i = javac.getTypeParameters().iterator(); + while(i.hasNext()) { + JCTypeParameter next = i.next(); + res.typeParameters().add(convert(next)); + } + } + if (javac.getBody() != null) { Block b = convertBlock(javac.getBody()); res.setBody(b);