From 21cddeda44bd48862361da3c925fbff09f756313 Mon Sep 17 00:00:00 2001 From: Charles McGarvey Date: Thu, 23 Jun 2011 13:04:44 -0600 Subject: [PATCH] compressing types with multiple identifiers is bad for C++ Sadly, it doesn't look like constructor syntax can be used for multi-word types in C++, so "return long long();" from the template won't compile, but oh well. The return statement is meant to be replaced anyway. see #32 --- src/com/dogcows/Editor.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/com/dogcows/Editor.java b/src/com/dogcows/Editor.java index 40ccc82..ff38a0f 100644 --- a/src/com/dogcows/Editor.java +++ b/src/com/dogcows/Editor.java @@ -89,7 +89,7 @@ public class Editor // Set up the terms used for the template expansion. HashMap terms = new HashMap(); - terms.put("RETURNTYPE", component.getReturnType().getDescriptor(language).replaceAll("\\s+", "")); + terms.put("RETURNTYPE", component.getReturnType().getDescriptor(language)); terms.put("CLASSNAME", name); terms.put("METHODNAME", component.getMethodName()); terms.put("METHODPARAMS", getMethodParams(component.getParamTypes(), @@ -295,7 +295,7 @@ public class Editor String[] strings = new String[types.length]; for (int i = 0; i < types.length; ++i) { - strings[i] = types[i].getDescriptor(language).replaceAll("\\s+", ""); + strings[i] = types[i].getDescriptor(language); } return strings; } -- 2.45.2