Commit 0f56e0cc by Tom Tromey Committed by Tom Tromey

re PR libgcj/12058 (java.lang.reflect.Array.set(Object, int, Object) throws…

re PR libgcj/12058 (java.lang.reflect.Array.set(Object, int, Object) throws java.lang.IllegalArgumentException)

	PR java/12058:
	* java/lang/reflect/natArray.cc (set): Allow null as argument.

From-SVN: r70813
parent 288e517f
2003-08-26 Tom Tromey <tromey@redhat.com>
PR java/12058:
* java/lang/reflect/natArray.cc (set): Allow null as argument.
* java/lang/reflect/Proxy.java (ProxyData): `pack' now a String.
(ProxyData.getPackage): New method.
(ProxyData.getProxyData): Use package name, not Package.
......
......@@ -364,7 +364,7 @@ java::lang::reflect::Array::set (jobject array, jint index,
{
// We don't have to call getElementType here, or check INDEX,
// because it was already done in the Java wrapper.
if (! _Jv_IsInstanceOf (value, elType))
if (value != NULL && ! _Jv_IsInstanceOf (value, elType))
throw new java::lang::IllegalArgumentException;
elements ((jobjectArray) array) [index] = value;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment