From 5c9b6acb06d3a85666ca804b7f8853eab3ee2737 Mon Sep 17 00:00:00 2001 From: tsantalis Date: Thu, 12 Dec 2024 09:52:30 -0500 Subject: [PATCH] Improved type inference when matching a generic type T with actual type https://github.com/apache/commons-lang/commit/ab8caff3a352fcf10563db44b85f7e8fb154e3a1 --- .../gr/uom/java/xmi/decomposition/OperationInvocation.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/java/gr/uom/java/xmi/decomposition/OperationInvocation.java b/src/main/java/gr/uom/java/xmi/decomposition/OperationInvocation.java index 0704d63ba3..42a60e9a2a 100644 --- a/src/main/java/gr/uom/java/xmi/decomposition/OperationInvocation.java +++ b/src/main/java/gr/uom/java/xmi/decomposition/OperationInvocation.java @@ -377,6 +377,9 @@ else if((parentFieldDeclarationMap != null && parentFieldDeclarationMap.contains public static boolean compatibleTypes(UMLParameter parameter, UMLType type, UMLAbstractClassDiff classDiff, UMLModelDiff modelDiff) { String type1 = parameter.getType().toString(); String type2 = type.toString(); + if(parameter.getType().getClassType().length() == 1) { + return parameter.getType().getArrayDimension() == type.getArrayDimension(); + } if(collectionMatch(parameter.getType(), type)) return true; if(type1.equals("Throwable") && type2.endsWith("Exception"))