mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
PsiDiamondTypeUtil#removeRedundantTypeArguments: short-cut if there are no type arguments
This commit is contained in:
@@ -356,6 +356,7 @@ public class PsiDiamondTypeUtil {
|
||||
PsiElementFactory factory = JavaPsiFacade.getInstance(element.getProject()).getElementFactory();
|
||||
for(PsiMethodCallExpression call : PsiTreeUtil.collectElementsOfType(element, PsiMethodCallExpression.class)) {
|
||||
PsiType[] arguments = call.getTypeArguments();
|
||||
if (arguments.length == 0) continue;
|
||||
PsiMethod method = call.resolveMethod();
|
||||
if(method != null) {
|
||||
PsiTypeParameter[] parameters = method.getTypeParameters();
|
||||
|
||||
Reference in New Issue
Block a user