[Swift-commit] r2361 - trunk/src/org/griphyn/vdl/engine
noreply at svn.ci.uchicago.edu
noreply at svn.ci.uchicago.edu
Mon Dec 8 14:52:51 CST 2008
Author: hategan
Date: 2008-12-08 14:52:51 -0600 (Mon, 08 Dec 2008)
New Revision: 2361
Modified:
trunk/src/org/griphyn/vdl/engine/Karajan.java
Log:
initializing to null seems cleaner
Modified: trunk/src/org/griphyn/vdl/engine/Karajan.java
===================================================================
--- trunk/src/org/griphyn/vdl/engine/Karajan.java 2008-12-08 20:50:53 UTC (rev 2360)
+++ trunk/src/org/griphyn/vdl/engine/Karajan.java 2008-12-08 20:52:51 UTC (rev 2361)
@@ -992,7 +992,7 @@
newst.setAttribute("memberchild", sm.getMemberName());
String parentType = datatype(parentST);
- String actualType = "";
+ String actualType = null;
for (int i = 0; i < types.sizeOfTypeArray(); i++) {
if (types.getTypeArray(i).getTypename().equals(parentType)) {
TypeStructure ts = types.getTypeArray(i).getTypestructure();
@@ -1008,7 +1008,7 @@
break;
}
}
- if ("".equals(actualType)) {
+ if (actualType == null) {
throw new CompilationException("Type " + parentType + " is not defined.");
}
newst.setAttribute("datatype", actualType);
More information about the Swift-commit
mailing list