Wrong stubs created for two-dimensional arrays
----------------------------------------------
Key: MGROOVY-157
URL: http://jira.codehaus.org/browse/MGROOVY-157
Project: GMaven
Issue Type: Bug
Components: stub generation
Affects Versions: 1.0-rc-3
Reporter: Alexander Thiel
Assignee: Jason Dillon
Declarations like Object[][] are transformed into [[] by the stub generator and
the subsequent compilation of the stub then fails.
To reproduce this, apply the following patch to the SimpleTest script in the
gmaven-runtime-1.5 module
Index:
gmaven-runtime-1.5/src/test/resources/org/codehaus/groovy/maven/runtime/v15/stubgen/SimpleTest.groovy
===================================================================
---
gmaven-runtime-1.5/src/test/resources/org/codehaus/groovy/maven/runtime/v15/stubgen/SimpleTest.groovy
(revision 13056)
+++
gmaven-runtime-1.5/src/test/resources/org/codehaus/groovy/maven/runtime/v15/stubgen/SimpleTest.groovy
(working copy)
@@ -88,6 +88,9 @@
/** Object array. */
Object[] objectArray
+ /** 2D Object array. */
+ Object[][] matrix
+
/**
* Javadoc for constructor.
*/
and look at the output from stderr:
/**
* 2D Object array.
*/
private [[] matrix = null;
public [[] getMatrix() {
throw new InternalError("Stubbed method");
}
public void setMatrix([[] value) {
throw new InternalError("Stubbed method");
}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email