Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGunnar Wagenknecht2016-10-15 06:53:56 +0000
committerLakshmi Shanmugam2018-07-28 15:50:23 +0000
commit4beccf210026aa7909983dcf7c5cf2a8a4fba46b (patch)
tree2e3e566a29a9e7f8eed1021982cade21d86c5f94 /bundles/org.eclipse.swt.tools
parentd33580ac593398ef9901b9779dd1f40ec86fe44b (diff)
downloadeclipse.platform.swt-4beccf210026aa7909983dcf7c5cf2a8a4fba46b.tar.gz
eclipse.platform.swt-4beccf210026aa7909983dcf7c5cf2a8a4fba46b.tar.xz
eclipse.platform.swt-4beccf210026aa7909983dcf7c5cf2a8a4fba46b.zip
Bug 514191 - [Cocoa] [10.11] Bridge support files should be updated to latest macOS supported version
Catch-all replace for common generic types Change-Id: I76df6b0cd570debb9bfb165c0f46b93f1464da80 Signed-off-by: Gunnar Wagenknecht <gunnar@wagenknecht.org>
Diffstat (limited to 'bundles/org.eclipse.swt.tools')
-rw-r--r--bundles/org.eclipse.swt.tools/Mac Generation/org/eclipse/swt/tools/internal/MacGenerator.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/bundles/org.eclipse.swt.tools/Mac Generation/org/eclipse/swt/tools/internal/MacGenerator.java b/bundles/org.eclipse.swt.tools/Mac Generation/org/eclipse/swt/tools/internal/MacGenerator.java
index 3df7c1ac0e..fe2b248e35 100644
--- a/bundles/org.eclipse.swt.tools/Mac Generation/org/eclipse/swt/tools/internal/MacGenerator.java
+++ b/bundles/org.eclipse.swt.tools/Mac Generation/org/eclipse/swt/tools/internal/MacGenerator.java
@@ -313,6 +313,10 @@ private String getDeclaredType(NamedNodeMap map, Node location) {
// also strip __kindof keyword
value = value.replace("__kindof", "");
+ // anther generics thing is "ObjectType", however, those names can be arbitrary
+ // let's to a catch-all for common names here and handle other cases individually via mapping in extras file
+ value = value.replace("ObjectType", "id").replace("KeyType", "id");
+
// also remove any white spaces
value = value.chars().filter((c)->!Character.isWhitespace(c)).mapToObj(c -> String.valueOf((char)c)).collect(Collectors.joining());

Back to the top